User controls are custom, reusable controls, and they use the same techniques that are employed by HTML and Web server controls. They offer an easy way to partition and reuse common user interfaces across ASP.NET Web applications.

learn more… | top users | synonyms

1
vote
0answers
13 views

People picker icons and auto-completion

I am having this problem across different site collections, applications and even farms. When I have a field of the "User" type in a custom list, the default forms that are created by SharePoint ...
0
votes
0answers
14 views

user control onkeydown from SP 2007 to 2013

I m upgrading a search box from SP 2007 to SP 2013, when I add the "onkeydown" in the following line : <INPUT class='form' Type=TEXT id='idDirectorySearchString' size=25 ...
0
votes
0answers
5 views

Invalid file name when Asset dialog opens from AssetUrlSelector

I'm getting the an exception when I put an AssetUrlSelector in a web part and then try to select an asset from it. The exception occurs immediately upon opening the Asset Select Dialog window. ...
2
votes
3answers
30 views

Deleting user permissions from document library instead of site level

I wanted to delete a user permission from ONE of the various document libraries in a SharePoint site. But when i deleted the permission, it seemed to have deleted the user permission at a much higher ...
1
vote
1answer
54 views
0
votes
1answer
25 views

The resource cannot be found - User Control in a MasterPage

I wanted to add a user control to a MasterPage. I added the control to a VS Solution and deployed it. Then I opened the MasterPage via SharePoint Designer and added the following code: <%@ ...
4
votes
2answers
471 views

Opening a document in read-only mode using an external control

I have a .Net application that (amongst other things) provides a front end to a sharepoint document library. Users are able to open documents, and I use the Open Documents Control to do so ...
1
vote
1answer
521 views

ASP.Net Label control's Text property not updating text under button click event

I have developed a small application in SharePoint. I am using custom application page and load .ascx Control over that page under Page_Load() method. In .ascx Control, I have created a small form ...
0
votes
2answers
30 views

Custom WebParts that depend on custom lists

I have a web scoped feature that creates List instances based on list-Definitions and i want these lists to be created in a sub-site. I'm running into the issue that the custom web-parts that use ...
3
votes
1answer
377 views

SharePoint List items, UserControls and cookies

I have another task at hand. I need to use cookies to read a title of an item from a custom list in SharePoint. This task is for SharePoint 2010. I have a container set up that will display the ...
0
votes
1answer
26 views

How to access div id (with runat=“server”) on MasterPage via User Control?

We have masterpage with DIV id="new-div". We have deployed a user control on this masterpage. I would like to know how can we access the new-div via the user control? We need to add some css based on ...
1
vote
4answers
46 views

Register user controls (ascx) in web.config?

Since ASP.NET 2.0 I usually register reusable user controls in web.config, rather then register it in every page with <%@ Register %> directives. Is there any "Sharepoint way" to do it for ...
1
vote
1answer
34 views

How to prefill user field in custom aspx form?

I have a task to create SP2010 inventory request system based on VS2010. The idea is the requestor creates a request, which contains inventory information and approvers. Approvers is the user field ...
0
votes
0answers
20 views

Store and Refresh DB data in a Session

There's a user control added to the left navigation of a SharePoint 2013 site. The User Control code makes DB calls on each page load. As this is bad, I'm planning to get data from DB and store in ...
2
votes
1answer
91 views

How to upgrade a SharePoint 2010 Project to SharePoint 2013 (WebParts, MasterPage, App Page, User Controls) in Visual Studio 2012?

We have a SharePoint 2010 project solution which we are trying to uprgade to SharePoint 2013. This includes webparts, application pages, user controls, masterpage, etc. Foll. is the procedure we ...
1
vote
3answers
229 views

Add user control or web part to every page in a site

I want to have a feature which causes the following to happen everytime any page in a site loads. I need to have a web part or user control which adds information about the current user to the page. ...
1
vote
1answer
23 views

Converting an ASP.NET application into a SharePoint application, need assistance on doubts and good practice [closed]

we have a ASP.NET simple application with custom functionality that performs certain calculations based on data entered in text box and shows output in a label. We would now like to use it in ...
0
votes
4answers
359 views

Javascript error on sharepoint page with search webpart and User Control containing UpdatePanel

I've been trying to find a cause for this error for some time to no avail... We have a SharePoint 2007 site heavily customized in terms of look and feel. In the master page a user control has been ...
1
vote
2answers
3k views

Dynamically add controls to webpart without Postback?

Is it possible to dynamically add controls to a webpart without having a postback for example with AJAX/Java Script/jQuery/Partial Postback within SharePoint? I'm searching for some kind of ...
0
votes
1answer
15 views

Controls has a different layout

I develop a small web part and I noticed that SharePoint display some of my controls differently or more exactly with different font settings. My class is deriving from WebPart and use for example a ...
4
votes
1answer
512 views

How to make a UserControl Minimal Download Strategy Compliant

I have a feature which specifies a custom user control to be added to the AdditionalPageHead delegate control as such: <?xml version="1.0" encoding="utf-8"?> <Elements ...
7
votes
3answers
927 views

Visual Studio 2012. Visual webpart's ascx.g.cs file empty after registering any control

I've discovered a problem when a Visual webpart's g.cs appears to be empty. I'm using Visual Studio 2012 Update 3 and a project for SharePoint 2010. The steps to reproduce the problem: in Visual ...
1
vote
1answer
118 views

How can I do a check if current user is following current site?

I have a usercontrol and inside its ascx.cs file I would like to do a check(if) if current user is following the current site. How can I accomplish that? So far I have done something like this: ...
4
votes
1answer
2k views

adding link to suite bar in sharepoint 2013

I have followed the following liks to add custom links to sharepoint 2013 suite bar. http://blogs.msdn.com/b/findnavish/archive/2013/02/07/sharepoint-2013-customizing-suite-bar.aspx ...
0
votes
1answer
75 views

SharePoint 2010 Visual Web Part development @_parser.AddParsedSubObject LiteralControl WebPartPageUserException

I am using SharePoint 2010 Foundation on a vmware virtual machine. I am using Visual Studio 2012 update 3. I am working on a visual web part project. I have so far in this project only used asp.net ...
0
votes
0answers
62 views

SPCalendarView does not show correct Data

I am creating Web Part & add control of Sp Calendar view. I am showing events from Calendar List.It shows data only for today & previous Date. it does not show data after current date. Also,it ...
1
vote
1answer
74 views

Extract NewsFeed and use in a custom user control

Is it possible to use the news feed control in a custom user control page (ascx) ? I need only the message sender part of the newsFeed, which is displayed in following picture. So that I could send ...
2
votes
2answers
31 views

User Control is is not rendering in pagelayout in MOSS2007

Hi I registerd user control in pagelayout and trying use that but it seem like it not rendering any thoughts %@ Register TagPrefix="sd" TagName="adbanner" ...
0
votes
1answer
93 views

last visited pages of a site

I have a requirement in which I have to show two previously visited pages in breadcrumb. Is there any property from which I can fetch this information?
0
votes
0answers
99 views

An object reference is required for the non-static field, method, or property 'System.Web.UI.Control.Controls.get'

I have created a farm solution inside Visual studio 2012, and i added the following code inside my user control :- namespace CustomSuiteLinksDelegate.ControlTemplates.CustomSuiteLinksDelegate { ...
0
votes
1answer
95 views

Control View based on Current User Role

I am trying to limit visibility to buttons and ability on a user control based on Role on a SharePoint 2010 Site. I get the user from the following code line SPContext.Current.Web.CurrentUser ...
0
votes
3answers
291 views

Putting User Control in Web Part

I'm pretty new to SharePoint but am trying to get the hang of it. What I have been doing is creating ASP.NET web application pages and then deploying those to the SharePoint site. This works and is ...
1
vote
0answers
138 views

Exception when deleting webpart Microsoft.SharePoint.WebPartPages.WebPartPageUserException

I have been looking for any leads on this direction on the web and most of the issues I have found is when they try to add a webpart but I am running across the issue where I am getting an exception ...
0
votes
2answers
49 views

There is an Out of the Box SP ListBox that allows the user to select options and display them on another ListBox?

Basically those are two DropDownLists, but I'm wondering if there's an OOB webpart. Example: Update: I have found a lot of insight in this page, that is a translation of this blog post.
1
vote
2answers
1k views

How to check if current user is member of the current site or above member group, site owner group etc

How can I do a check that looks if current user is a member group or above member group on current site? Above member group I mean site owner group etc.. So far I have done: var currentSite = ...
0
votes
1answer
29 views

“The name 'InitializeControl' does not exist in the current context” in Web Part with custom control

I have a custom GridView control that has pagination built in it. I've used this component many times on Sharepoint 2010 without a problem. Now i'm trying to use it on a Sharepoint 2013 Web Part ...
1
vote
0answers
38 views

SP2013 Community Site - adding custom content to home page

I'm probably missing something basic, but I'm trying to add new user control based content to the Community Home.aspx page within a Community Site. How is that done? I've tried editing the page in my ...
1
vote
2answers
3k views

Can a user control be added to a Visual Web Part?

Can i add a user control to a Visual Web Part (in visual studio) in sharepoint 2010? I have a user control which has content that i want placed on most of my visual web parts. Has anyone got any ...
1
vote
0answers
38 views

Issue between user control and Visual webpart

I have user control in my master page (countrycontrol.ascx) on clicking the user control It will show links, user is allowed to select the country based on the selected country the visual webpart need ...
0
votes
1answer
318 views

Adding user control to 2013 master page causes a 404 error

I have a problem when adding a user control to my SharePoint 2013 master page: my site shows a 404 error. At this point I have a brand new, empty user control (i.e. created in VS2012 but nothing ...
0
votes
2answers
195 views

SharePoint 2010 Cannot access Properties or Events of my Custom UserControl in my Application Page

I have created a UserControl (Farm) in my SharePoint Project using VS2012 (for SharePoint 2010). I want to embed/host this in an application page. I have added properties and events to the ...
2
votes
1answer
89 views

Rich Text Control on a Layouts Page

I want to create and deploy a layouts page in a SharePoint 2013 environment. It is basically a form where you can store values. Is it possible to use the Rich Text Control which is utilizing the ...
1
vote
1answer
60 views

Loading a UserControl within another UserControl code

Can someone tell me how I can load a user control from within another user control. I'm using MOSS 2007
1
vote
1answer
293 views

Ajax Calendar Extender Position is not working in SharePoint Webpart

I am using Ajax Calendar Extender, but it is not pop up next to textbox, it is appearing int the middle of the page. Here is the code: <asp:TextBox ID="dtEnginerring" runat="server" ...
1
vote
0answers
140 views

Cannot save field values from ListFieldIterator to list item

I have the following issue. I created rendering template for list. This template is shown in New\Display\Edit forms. Then i've created two user controls: "mainCard" and "mainCard_Info". First control ...
1
vote
3answers
4k views

SP2013: Adding a custom usercontrol to masterpage using Design Manager

I created a custom masterpage using the SP2013 Design Manager. I also created a SharePoint solution in Visual studio 2012 with a custom usercontrol (ascx) and custom webparts. The masterpage works ...
0
votes
1answer
172 views

How to reference/write the file path in Elements.xml for UserControl in Sandbox Solution?

I have 1 solution (which is deploying as SandBox Solution). I have added JavaScript files, Images, Application Page & UserControl in one Module under project folder. I have one Element.xml file ...
0
votes
1answer
573 views

Custom link button - image dissapearing after updatePanel reload

I created a custom link button control so it can display also an image. Code below: namespace SharepointTools.Controls { [ToolboxData("<{0}:CustomImageButton ...
0
votes
2answers
2k views

When should we call EnsureChildControls()

According to Microsoft,The EnsureChildControls() method is called in order to make sure that child controls have been created. I see many developers call EnsureChildControls() in ...
1
vote
3answers
917 views

user control losing new values when saving

I have a user control in a web part that pulls data from a SP list and displays it in standard ASP.Net controls. When I save the data, the old values seem to get saved even if I had changed them. I ...