Home > Sharepoint > Create custom Picker and Selector control in Sharepoint

Create custom Picker and Selector control in Sharepoint

We mostly familiar with these picker and selector control in Sharepoint :

image

What we mostly don’t know is that we can reuse these controls. This link http://sharepointsolutions.com/sharepoint-help/blog/2009/10/create-a-custom-picker-in-sharepoint-2010/ giving all we need to do that. It also provides us with sample codes and detail explanation (Thanks for jeremyluerkens who wrote that).

I’ve successfully created my own based on that. One thing to remember is we have to register the webcontrols  as <safecontrol> in web.config, using editor manifest in package like below:

image

But, when I applied at Visual Webpart, the border isn’t even visible :

image

The fast trick for this is using JQuery :

    jQuery(document).ready(function ($) {
        $("div[title='Object Picker']").css({ 'border-width': '1px', 'border-style': 'solid' });
    });

so it becomes:

image

Categories: Sharepoint Tags:

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: