Click here to Skip to main content
15,900,724 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello Experts,

Firstly for all those you have been helping developers. Congratulations on being so good this year and I Thank each one of you. Wish you all a Happy New Year.

Now, I have web page where it generates dynamic rows for a Grid, and Grid has Dropdown. On dropdown selected index changed="File" Then I am showing a Pop using Scriptmanager.RegisterClientScriptBlock. When they Click "OK" There should be an alert asking user to upload a file. I am fighting at this point, I do not know how to proceed further.

On alert click "OK" should pop up for file upload.

Please help me out in this.

Gridview.ddl.selectedvalue="File" Then pop up a message "Submit a file" Ok Cancel

If (Ok)
Upload File pop up
else if (Cancel)
DDL set to default in Grid
Posted
Updated 31-Dec-14 4:01am
v2

1 solution

As far as I can guess, the problems is happening because the buttons ok and cancel are not initially present on the markup, but they are created when popup is opened.

If I am right, then you can do one thing. Declare a panel in markup with the controls you are showing along with the ok and cancel buttons. Make them server buttons and define their server side click events as well. Make the visibility of the panel to false. Now, when DropDownList is selected, you can show the panel from server side, which is hid initially and show it is a popup too. Search for examples, you will get it.

Now, you have ok and cancel button clicks server side events. So, inside those events, again show one panel with the file upload control (which is already declared on aspx page).

It can be a difficult task, but you can do it.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900