.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Web page with custom control elements

Posted By:      Posted Date: April 10, 2011    Points: 0   Category :ASP.Net


I would like to create web page/form with several subforms - means edit for records, e.g.: first page, no problem, data list in gridview with checkbox there I do select two records and press one Edit button, that should open Edit form with two subforms and one Save button - the thing is that I would like to have that subform fully as form designed previously (not just add elements).

In genaral I need to be sure how to make UI controls as class and use them in my actual pages.


Thank you.


View Complete Post

More Related Resource Links

Adding a custom control to the SharePoint 2010 Team Site Wiki Page Template ( wkpstd.aspx ) programm

Topic This is maybe my last post about the Team Site Wiki Page customization with the aim of exceeding its limitations. This time we are going to customize the unique template ( wkpstd.aspx) by replacing the control that renders the editable content by a custom one. In this post example, we will take advantage of the use of this custom control to render not editable additional contents, for instance, a header and a footer that could be the same for a specific Wiki Page Library. Of course, we are not going to really customize the template, but we are going to use a delegate control to replace the control at runtime. Here are the screen shots of the result: We can see a non editable Header and Footer on the Team Site Wiki Page In edit mode these additional contents are not rendered, but we can add new content as usual And of course, after having saved the page, the new content is rendered wtih the non editable Header and Footer. Steps required   If you look at the Team Site Wiki Page template, wkpstd.aspx, you can see the control that is rendering the editable content/ <SharePoint:EmbeddedFormField ID="WikiField" FieldName="WikiField" ControlMode="Display" runat="server" /> We are first going to create a custom EmbeddedFormField control Then, we are going to use a delegate control to replace the native EmbeddedFor

Is there a way in VB.Net to embed a custom user control to a web page based on Word or Excel

Hi Everyone.  I'm looking to create a web page that would be used on a local intranet that would use a custom control based on Word and Excel.  I've used code previously to embed it in a Windows application but wasn't sure if anyone knew of any examples out there on how to embed a custom control into a ASP.Net page.

How to set default Image to RichFieldImage control in custom Publishing Page layout in Site defini




How to set  default Image to RichFieldImage control  in custom Publishing Page layout in Site definition?


Page Life Cycle and custom composite server control life cycle



We are creating a composite server control. It will have few other controls. I am confused where exactly to write the code ie in which event. Is page life cycle and control life cycle follow the same event order?

Could any one please suggest or post articles on this.

Thank You

Register a control from a custom application page.



I have an application page with a form on it to generate custom controls that need to be added to the page head. For example scripts or styles.
Is there a way to register them to the master page?

I know there is a control called "CustomJavaScriptFileUrl" that could be used to register a jScript file, but you could only register one file.



How to use a custom server control that is defined in inline code in the same page?




I have to use inline code for an aspx page and I need to use a custom server control that is defined in the same aspx page but the control does not get processed as a server control. it gets  returned as is as static html tag.


does anyone know how to do that?





How can I create a custom control that adds other controls visible to the page hosting my custom con


I want to create a custom control where I define several specifically named DIV sections.  The code-behind logic of the custom control will perform operations on these named DIV sections.  The page where the custom control is hosted needs to be able to add named controls to the DIV sections and perform operations on these named controls added to the DIV sections.

Let me explain a little further.  In the custom control, I want to have code behind logic that fires the following Page Event and uses a condition to make one or another specifically named DIV section visible or not:

    < _
    ToolboxData("<{0}:BaseDetails runat=""server""></{0}:BaseDetails>") _
    > _
    Public Class BaseDetails
        Inherits UserControl

        Protected Sub Page_PreRender(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.PreRender
            DetailsNameDiv1.Visible = False
            DetailsNameDiv2.Visible = False

How to handle login control events when using a custom FBA login page?


Thanks to Kirk Evans' blog post that is liberally referenced all over the place, I have managed to get a custom login page working on my SP2010 site and it is pretty great.  The problem that I am having is that there doesn't seem to be anyway to respond to the events that are raised by asp.net login control that is in my page.

The page is inherited from Microsoft.SharePoint.IdentityModel.Pages.FormsSignInPage and as a result will error out when I attempt to reference a code-behind .cs file.  My question is, how do I respond to the events being raised by the login control that is in the page so that I can do things like logging successful user sign-ins?

Joseph Ackerman, MCSD, MCP.Net

Can I use a single DynamicFilter control in a custom page?


Is it possible to use a single DynamicFilter control in a custom page, similar to the way that I can use a single DynamicControl field in a custom page?  

For example I can do this (I have customized the Edit page to be a wizard with fields like this in different steps) ...

<asp:DynamicControl ID="DynamicObservationDate" runat="server" DataField="ObservationDate" />

But when I do this, nothing shows up on the page.

        Observation Date: <asp:DynamicFilter runat="server" ID="ObservationDateFilter" DataField="ObservationDate" />

Do I need to "initialize" the DynamicFilter somehow for this to work?  

Thank you!

How to use Navigation Hierarchy control with ListView Webpart on a custom web page?



Here is what i am trying to do with managed metadata and lists.

List name: MyList, it will have 2 managed metadata columns 'Business process' and 'Management model'. I have enabled metadata navigation settings for this list on mentioned columns

I will have a data view webpart mapped with MyList on one of the custom pages. I want to add Navigation Hierachy Control Or equivalent on this custom page which will be based on managed metadata columns 'Business process' and 'Management model'. On the selection of a node from this hierarchy, i would like to filter the ListView on the page.

Is there a way to directly use Navigation Hierarchy that we get on AllItems.aspx page corresponding to List? or any other out of the box method to achieve this WITHOUT custom code?

Thanks and regards,


load custom control after page render



i have few custom controls that take some time to load,how can i make the page render all is buttons and in background the controls will do there job?

create custom application page with a ribbon and user control webpart


i am in stress how to start this what should be the first step

i want to create custom application page with a ribbon and some user
control web part to show document item properties.

Please help me regarding this


thanks in advance 



wasikhan junior software ENG

Building Re-Usable ASP.NET User Control and Page Libraries with VS 2008


I am having problems with a user control. I want my solution to have a separate project for holding my user controls.

The main project can get a reference to this user control project and can import this user control dll into my main project. 

Thanks in advance,

Dheeraj Mittal


Content page control passes as argument to javascript function


Here is the content page:


<%@ Page Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="JavaDynamicCopyValue.aspx.cs" Inherits="JavaDynamicCopyValue" Title="Untitled Page" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
 <script type="text/javascript" >
 function copyValue(input, output )
   ouput.value = input.value;
   return true;
 <asp:TextBox ID="txt1" runat="server" onchange="copyValue(this,document.getElementById('<%=txt2.ClientID%>'))"></asp:TextBox>
    <br />
    <br />
    <asp:TextBox ID="txt2" runat="server"></asp:TextBox>


I got a javascript run time error says output is undefined. if I view source of the page, the txt1 markup became:

<input name="ctl00$ContentPlaceHol

Custom Control Design-Time SiteMap Provider Error


Greetings - I was referred here by MSDN forums hope this is the right place -  

I have a custom control (:WebControl) that renders web.sitemap in a specific way. While it runs error free and produces the expected result, at Design-Time it complains

Error Creating Control - MyControl  The provider 'AspNetXmlSiteMapProvider' specified for the defaultProvider does not exist in the providers collection.

I have discovered that the error is cause by this line of code:

string div = string.Format("<div class='{0}' id='{1}'>{2}</div>", this.CssClass, this.ID.ToString(), EnumerateNodesRecursive(SiteMap.RootNode, level));

or more specifically, by the reference to SiteMap.RootNode - I am not clear what is missing thoough because I have configured the SiteMapProvider in web.config as this:

        <add name="AspNetXmlSiteMapProvider" 
             type="System.Web.XmlSiteMapProvider, System.Web, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" 

video tutorial link for composite and rendered custom server control


hii all

i am new to technology so go easy on this post

according to what i read from web there are 3 type of custom server controls

1 superclass

2 composite

3 rendered

i found video tutorial for superclass custom server control but couldnt find video tutials for other 2.

please forward me link for composite and rendered custom server controls video tutorial  

image inside custom server control



I want to use an image inside a Custom Web server control ! 

Do I need to use Web.resources ? if so , how to do ?

ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend