Click here to Skip to main content
11,925,851 members (64,304 online)
Rate this:
Please Sign up or sign in to vote.
this is my application link[^]

i had 2 different user controls in one .aspx page.

first user control was dropdownlist binded with database. second user control was gridview.

if i select a company int the dropdownlist products of that company should be displayed in the second user control.

my problem was, when i am selecting the companies in the dropdownlist gridview user control is loading first and 2nd dropdownlist selected event is firing..

please help me...
Posted 16-May-12 3:41am
Edited 16-May-12 10:45am
Ed Nutting 16-May-12 8:47am
Hi there, your question is a bit unclear, what were you actually trying to do? Do you want the SelectionChange event to occur before the GridView is updated?
varaprasadreddy 25-May-12 6:56am
Hi friend sorry for the delay. what is mentioned is correct.
before the gridview is binding dropdownlist event has to be fired.
ryanb31 16-May-12 9:56am
Unless something has changes in recent versions of .Net, you cannot control the order that controls are loaded, unless you do it through code. But if they are on your aspx page .Net will load them in whatever order it wants. You may want to look into using a client side change event and JavaScript to kick off a webservice so that you are more in control. Or, look into delegates and raising events.
leena206 21-May-12 7:44am
actually your problem is not that much clear .. please elaborate
Rate this: bad
Please Sign up or sign in to vote.

Solution 1

this problem may occur due to rendering.. while rendering put your 2nd usercontrol 1st ..
UC1 & UC2 //two user controls
at the loadtime keep order :
Rate this: bad
Please Sign up or sign in to vote.

Solution 2

I cleared my problem. thanks for helping me.

this is the link[^]

[edit] clickable link [/edit]

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

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy | Mobile
Web03 | 2.8.151126.1 | Last Updated 25 May 2012
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100