193 Lotus blogs updated hourly. Who will post next? Home | Blogs | Search | About 
 
Latest 7 Posts
Questions from the DataTables Webinar
Tue, Oct 18th 2016 10
Upcoming Webinar: XPages and jQuery DataTables
Tue, Oct 4th 2016 9
Adding icon columns to DataTables with FontAwesome
Wed, Sep 14th 2016 13
Demo database from my MWLUG session
Thu, Sep 8th 2016 9
Slides (and thoughts) from MWLUG – XPages & jQuery DataTables
Wed, Aug 24th 2016 10
I’m speaking at MWLUG about…
Wed, Jun 29th 2016 12
XPage loading slow? Check your document datasource
Wed, Dec 16th 2015 10
Top 10
Adding icon columns to DataTables with FontAwesome
Wed, Sep 14th 2016 13
I’m speaking at MWLUG about…
Wed, Jun 29th 2016 12
XPage loading slow? Check your document datasource
Wed, Dec 16th 2015 10
Slides (and thoughts) from MWLUG – XPages & jQuery DataTables
Wed, Aug 24th 2016 10
Questions from the DataTables Webinar
Tue, Oct 18th 2016 10
Boot your alerts in the … with bootAlert
Tue, Feb 10th 2015 9
Demo database from my MWLUG session
Thu, Sep 8th 2016 9
Upcoming Webinar: XPages and jQuery DataTables
Tue, Oct 4th 2016 9
SSJS variables vs. scope variables
Mon, Jul 14th 2014 8
My first OpenNTF project – Dojo Name Picker
Fri, Jul 25th 2014 7


Copying Custom Controls
Twitter Google+ Facebook LinkedIn Addthis Email Gmail Flipboard Reddit Tumblr WhatsApp StumbleUpon Yammer Evernote Delicious
michaelgsmith    

This tip is pretty simple, and it might be common knowledge to most people, but I stumbled onto it pretty much by accident.

Copying a custom control from one XPage to another is fairly common, but when you do so and go to build your new page, you get the message:

The prefix “xc” for element “xc:ccTest” is not bound.

error_message

Previously, I never really bothered to look into this message any further.  I took the easy way out and simply dragged a new copy of the custom control onto the XPage, copied any custom properties (if any), and went on my way.  However, this can get annoying REAL fast if you have a lot of custom controls that need to be copied.

Luckily, there is a ridiculously easy way to quickly get rid of the above message.

When you create a new Xpage, the standard markup looks like this:

<?xml version="1.0" encoding="UTF-8"?> 
<xp:view xmlns:xp="http://www.ibm.com/xsp/core"> </xp:view>

Look what happens as soon as you drag a custom control on to your XPage:

<?xml version="1.0" encoding="UTF-8"?>
<xp:view xmlns:xp="http://www.ibm.com/xsp/core"
	xmlns:xc="http://www.ibm.com/xsp/custom">
	<xc:ccTest></xc:ccTest>
</xp:view>

Adding the bolded line above to the xp:view tag of your page will allow you to copy custom controls to your XPage without frustration.  At the end of the day is it really a big time saver?  No.  But at least you have a better understanding of the error message.

 




---------------------
http://xpage.me/2014/07/17/copying-custom-controls/
Jul 17, 2014
5 hits



Recent Blog Posts
10
Questions from the DataTables Webinar
Tue, Oct 18th 2016 11:58a   Michael Smith
A
9
Upcoming Webinar: XPages and jQuery DataTables
Tue, Oct 4th 2016 8:39a   Michael Smith
A
13
Adding icon columns to DataTables with FontAwesome
Wed, Sep 14th 2016 1:55a   Michael Smith
A
9
Demo database from my MWLUG session
Thu, Sep 8th 2016 7:11a   Michael Smith
A
10
Slides (and thoughts) from MWLUG – XPages & jQuery DataTables
Wed, Aug 24th 2016 9:49a   Michael Smith
A
12
I’m speaking at MWLUG about…
Wed, Jun 29th 2016 8:41a   Michael Smith
A




Created and Maintained by Yancy Lent - About - Planet Lotus Blog - Advertising - Mobile Edition