Thanks Guys, I think I am explaining this a bit wrong though. What I am doing is binding a datagrid to a strongly typed collection. The collection holds a class to has [Bindable] on some of its props. What I would like though is for the grid to auto generate the columns in a certain order, like how a datatable, dataview, etc. is. I guess what I am saying is how does the datagrid auto generate the column orders(Ordinal)? And how can I change this?
Thanks again, Dave -----Original Message----- From: Moderated discussion of advanced .NET topics. [mailto:[EMAIL PROTECTED]] On Behalf Of Marsh, Drew Sent: Friday, January 03, 2003 12:34 PM To: [EMAIL PROTECTED] Subject: Re: [ADVANCED-DOTNET] [bindable] Attribute Dave Buckner [mailto:[EMAIL PROTECTED]] wrote: > Hopefully a quick question for someone. =3D) When using the [bindable] > attribute is there a way to specify the order in which they so up? > E.g. = If I bind my object to a datagrid, how do change the order of > how it = generated the columns? You don't. The order of the columns in the model (DataView) and the order of the columns in the view (your control) do not need to correlate at all. Behavior like that of the DataGrid control is probably the most desirable, which is: If there are no UI columns explicitly configured (design time or run time), the UI columns are auto-generated from the columns found in the bound DataView. HTH, Drew [ .NET MVP | weblog: http://radio.weblogs.com/0104813/ ] You can read messages from the Advanced DOTNET archive, unsubscribe from Advanced DOTNET, or subscribe to other DevelopMentor lists at http://discuss.develop.com. You can read messages from the Advanced DOTNET archive, unsubscribe from Advanced DOTNET, or subscribe to other DevelopMentor lists at http://discuss.develop.com.