Questions tagged [web-controls]

Web controls are classes that allow you to create Web server controls on a Web page

Web controls are classes that allow you to create Web server controls on a Web page. Web server controls run on the server and include form controls such as buttons and text boxes. They also include special-purpose controls such as a calendar. Because Web server controls run on the server, you can programmatically control these elements. Although Web server controls are rendered as HTML, their object model does not necessarily reflect HTML syntax.

586 questions
3
votes
1 answer

By default, does ASP.NET Login Control use the ReturnURL to redirect?

If I drop a System.Web.UI.WebControls.Login onto a page, should it redirect to the ReturnURL by default? Or do I have to set some config settings or write some code to make this work?
Larsenal
  • 49,878
  • 43
  • 152
  • 220
3
votes
3 answers

Setting MyLabel.Text in Repeater's HeaderTemplate

Every sample I've found of doing this consists of writing a function outside of my page's OnLoad in order to do this, but I'm curious if there's a more concise way to go about it. I have a Label inside of a HeaderTemplate, and I just want to set the…
Christopher Garcia
  • 2,536
  • 7
  • 30
  • 40
3
votes
1 answer

Adding attributes to SharePoint Web Control

I'm trying to add an attribute to a SharePoint web control: Microsoft.SharePoint.WebControls.BooleanField which basically renders as an html input checkbox control. How do I add an attribute to this? such as an event? Normally for an asp.net web…
LB.
  • 13,730
  • 24
  • 67
  • 102
3
votes
1 answer

Working with frames in webbrowser Control

I am using .Document.Window.Frames to get frames. My having 2 frames.My only problem is ,I seem one at index 0, but not 1. Any help? HtmlWindow wf = wb.Document.Window.Frames[1]; string s = wf.Document.Body.OuterHtml; and…
user989888
  • 61
  • 1
  • 1
  • 5
3
votes
1 answer

Where can Sitecore webcontrol examples be found?

I've been looking over the Sitecore documentation for HtmlControls and WebControls, but none of the items have any meaningful descriptions or example code to show how they're used or what they produce. I understand how to use simple controls like…
zzzzBov
  • 174,988
  • 54
  • 320
  • 367
3
votes
1 answer

What is the right way to use the AttributeCollection.Render method?

I've created a web control and I want to pass the element attributes through during the render phase. I would prefer use writer.RenderBeginTag() and RenderEndTag() but this is the only way I can seem to integrate the attributes successfully: public…
BC.
  • 24,298
  • 12
  • 47
  • 62
3
votes
7 answers

ASP.NET TextBox Control - Get the default text value in code behind?

I have been spying the MSDN and can't see a property/method for TextBox that allows you to get the default text value that was set on a field; I want to be able to compare the current txtMyTextBox.Text to the default value (like this psuedo code…
peteski
  • 1,455
  • 3
  • 18
  • 40
3
votes
2 answers

limit selections in a listbox in vb.net

I am creating a web control in vb.net that contains a list box. I know that I am able to choose a selection mode of Single or Multiple, but I am interested in limiting a Multiple selection to a predetermined size. For example preventing a user from…
chillysapien
  • 2,256
  • 1
  • 26
  • 42
3
votes
1 answer

How To: Manupilate SharePoint:AspMenu control (Style-wise)

What I want to do is to split-up the globalnavigation bar on the sharepoint 2010 so I can control what menu-items should be floated to the left or right of the bar. Is there a way to do this without a complete customized version of it, so I only…
user557419
3
votes
3 answers

Is good or bad to write everything in c# rather than using web controls?

I'm confused with choosing between several ways of getting result in ASP.NET. For example, Web form control SqlDataSource, you retrieve data from database and show results in other controls such as DataGridView, BulletedList etc. However all those…
user610961
  • 181
  • 1
  • 10
3
votes
2 answers

How to force a IE version in a Winform WebControl?

I was trying to find out the problem in one web design I had and remembered to use a simple javascript to get the browser version as I had completly 2 different behaviors so I add this: