Click here to Skip to main content
15,888,205 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: Email in Asp.Net 2.0 Pin
Michael Sync11-Nov-07 0:05
Michael Sync11-Nov-07 0:05 
AnswerRe: Email in Asp.Net 2.0 Pin
Vasudevan Deepak Kumar9-Nov-07 0:45
Vasudevan Deepak Kumar9-Nov-07 0:45 
QuestionUncheck ASP.Net TreeView Checkboxes Pin
khuzwayom8-Nov-07 23:30
khuzwayom8-Nov-07 23:30 
AnswerRe: Uncheck ASP.Net TreeView Checkboxes Pin
Vasudevan Deepak Kumar9-Nov-07 0:43
Vasudevan Deepak Kumar9-Nov-07 0:43 
QuestionHttpHandler - dynamic images Pin
Chris_Green8-Nov-07 23:26
Chris_Green8-Nov-07 23:26 
AnswerRe: HttpHandler - dynamic images Pin
Vasudevan Deepak Kumar9-Nov-07 0:42
Vasudevan Deepak Kumar9-Nov-07 0:42 
GeneralRe: HttpHandler - dynamic images Pin
Chris_Green9-Nov-07 0:44
Chris_Green9-Nov-07 0:44 
QuestionDisable controls and validators client-side Pin
dabs8-Nov-07 23:03
dabs8-Nov-07 23:03 
Hi,

I have a page that is pretty complex, i.e. it has a table with lots of controls, everything generated from data in a database. Each row contains among others a DropDownList, and when certain items are selected in that dropdownlist, the rest of that row should be disabled. The rest of that row contains text boxes, drop down lists, and a few validators. The number of controls is dynamic.

What would be the best way to accomplish this? What I've got so far is:

- a onChange attribute for the dropdownlist,
- a javascript function which gets called in the onChange event handler
- this function correctly determines if I should enable or disable the rest of the row
- ... and then calls getElementsByName to get an array of elements that should be enabled/disabled.

But this is where I stop, since getElementsByName doesn't return anything. If I specify a name attribute for the controls that should be enabled/disabled, it won't render to the page since ASP.NET will override my setting with the id of the control. I could probably create a subclass of TextBox and DropDownList, and modify their RenderAttributes( ) function, I just haven't gotten to it yet. Is there an easier way?

Even if I succeed with that, I still have the problem of disabling the validators for the controls that should be disabled. Is there some easy way to accomplish that? I found http://www.codeproject.com/useritems/ASPNET_Validation_Tamed.asp[^] which talks about similar solution, but am I missing something completely obvious? I'm aware of the fact that I could set the AutoPostBack property of the DropDownLists to true, and handle the change events server side, but I would rather do it client side just to minimize server load. But then again, if I must use server side I probably will.

So anyway, any help or hints whatsoever would be highly appreciated.

Regards,
Daníel



Wenn ist das Nunstück git und Slotermeyer? Ja! Beierhund das oder die Flipperwaldt gersput!

Questionstream video from Youtube To ASPX Page Help Needed Pin
bijeshputhalath8-Nov-07 19:13
bijeshputhalath8-Nov-07 19:13 
AnswerRe: stream video from Youtube To ASPX Page Help Needed Pin
Michael Sync8-Nov-07 19:38
Michael Sync8-Nov-07 19:38 
GeneralRe: stream video from Youtube To ASPX Page Help Needed Pin
bijeshputhalath8-Nov-07 21:40
bijeshputhalath8-Nov-07 21:40 
GeneralRe: stream video from Youtube To ASPX Page Help Needed Pin
Michael Sync8-Nov-07 22:29
Michael Sync8-Nov-07 22:29 
GeneralRe: stream video from Youtube To ASPX Page Help Needed Pin
bijeshputhalath9-Nov-07 0:11
bijeshputhalath9-Nov-07 0:11 
QuestionHow to change the navigateurl dynamically for hyperlink column? Pin
Sri_34648-Nov-07 19:04
Sri_34648-Nov-07 19:04 
AnswerRe: How to change the navigateurl dynamically for hyperlink column? Pin
Michael Sync8-Nov-07 19:45
Michael Sync8-Nov-07 19:45 
GeneralRe: How to change the navigateurl dynamically for hyperlink column? Pin
Sri_34648-Nov-07 21:03
Sri_34648-Nov-07 21:03 
QuestionDatagrid to Excel Pin
rameshdontagani8-Nov-07 18:15
rameshdontagani8-Nov-07 18:15 
AnswerRe: Datagrid to Excel Pin
Vasudevan Deepak Kumar8-Nov-07 21:13
Vasudevan Deepak Kumar8-Nov-07 21:13 
QuestionSlickUpload Conflicting With HttpPostedFile Pin
wanlim08178-Nov-07 15:34
wanlim08178-Nov-07 15:34 
Questionnamespace not found --Microsoft.Office.Interop.Excel.ApplicationClass Pin
G.K.M.8-Nov-07 15:18
G.K.M.8-Nov-07 15:18 
AnswerRe: namespace not found --Microsoft.Office.Interop.Excel.ApplicationClass Pin
Sri_34648-Nov-07 19:06
Sri_34648-Nov-07 19:06 
Questioncreating and saving excel work sheet at runtime Pin
G.K.M.8-Nov-07 15:03
G.K.M.8-Nov-07 15:03 
AnswerRe: creating and saving excel work sheet at runtime Pin
Michael Sync8-Nov-07 19:47
Michael Sync8-Nov-07 19:47 
QuestionASP .NET 2.0 Pin
kenexcelon8-Nov-07 9:54
kenexcelon8-Nov-07 9:54 
AnswerRe: ASP .NET 2.0 Pin
Fred_Smith8-Nov-07 12:40
Fred_Smith8-Nov-07 12:40 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.