Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Databinding and hierarchical controls

Reply
Thread Tools

Databinding and hierarchical controls

 
 
boomhauer@gmail.com
Guest
Posts: n/a
 
      09-12-2006
I cant seem to find info online about this so thought id ask..

I have an asp.net 2.0 page that has:

1. an infragistics calendar control
2. a DDL that has an ODS with a param pulled from the calendar
3. a gridview with ODS that binds a param from the DDL key

the problem im having is, on chanigng the infragistics calendar, the
page seems to databind the gridview first, and then the DDL... but
obviously this leads to problems since the grid is depending on the DDL
for an input param.

I can make it work by calling a DataBind() on the controls in quest,
but this seems to cause multiple binds to be performed... works, but
definately not efficient.

Is there a way i can force this to perform automatic binding in the
correct sequence?

Thanks

 
Reply With Quote
 
 
 
 
S. Justin Gengo
Guest
Posts: n/a
 
      09-12-2006
Boomhauer,

While I think that the automatic databinding features of .NET are pretty
neat and I use them on occasion, when you get down to needing logic like you
are utilizing I think it's better to do the databinding yourself in the code
behind.

I would suggest that the most efficient way for you to do this will be to
specifically databind each control based on events fired by the previous
controls. This way you'll be certain to have the most efficient code
possible.

Or, in other words, no, I don't know of a way to use the auto-binding and
set which control is bound first...


Regards,

--
S. Justin Gengo
Web Developer / Programmer

Free code library:
http://www.aboutfortunate.com

"Out of chaos comes order."
Nietzsche


<(E-Mail Removed)> wrote in message
news:(E-Mail Removed) oups.com...
>I cant seem to find info online about this so thought id ask..
>
> I have an asp.net 2.0 page that has:
>
> 1. an infragistics calendar control
> 2. a DDL that has an ODS with a param pulled from the calendar
> 3. a gridview with ODS that binds a param from the DDL key
>
> the problem im having is, on chanigng the infragistics calendar, the
> page seems to databind the gridview first, and then the DDL... but
> obviously this leads to problems since the grid is depending on the DDL
> for an input param.
>
> I can make it work by calling a DataBind() on the controls in quest,
> but this seems to cause multiple binds to be performed... works, but
> definately not efficient.
>
> Is there a way i can force this to perform automatic binding in the
> correct sequence?
>
> Thanks
>



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Databinding expressions are only supported on objects that have a DataBinding event jobs ASP .Net 0 09-25-2007 11:54 PM
Gridview encoding, or how to run commands before gridview's default databinding, or, how do I disable default databinding at all? Sergei Shelukhin ASP .Net 1 11-12-2006 01:43 PM
Re: Dynamically create controls with non-hierarchical IDs John Saunders ASP .Net 0 07-15-2004 05:35 PM
DataGrid Custom Column Error when DataBinding "does not contain a definition for 'DataBinding'" Earl Teigrob ASP .Net Datagrid Control 1 03-01-2004 04:52 AM
Template controls and hierarchical data bclegg ASP .Net Datagrid Control 2 02-07-2004 01:23 PM



Advertisments