Windows Develop Bookmark and Share   
 index > Windows Forms Data Controls and Databinding > Why didn't DataView.Sort support Expression like Parent.Price ?
 

Why didn't DataView.Sort support Expression like Parent.Price ?

Why didn't DataView.Sort support DataColumn.Expression like Parent.Price ? :(
Explain me pls. 

Subject.
MigrationUser 1  Friday, January 31, 2003 4:58 AM
a DataView just sorts on a View (that's why it's called that) of data, so there are no parent tables or anything like that.  If you want to sort by Parent.Price, be sure that that field exists in your DataView so you can do something like .Sort = "ParentPrice > 0" (where ParentPrice would be the name of the field)
MigrationUser 1  Sunday, February 02, 2003 3:24 PM
(And you can add that column to your table using an expression, like
   MyDataSet.Tables["childTableName"].Columns.Add("newColumnName", typeof(string), "Parent.parentColumnName");

)
MigrationUser 1  Friday, March 21, 2003 6:47 PM

You can use google to search for other answers

Custom Search

More Threads

• items in the combobox must come from a "Statically" defined list of value
• How to add a new row as header?
• Trouble Setting Data Source in Drag & Drop Controls
• Refresh DataGridView in one usercontrol from an action in another usercontrol on win form?
• row filter in data grid view
• Problem with DataGridView ComboBox implementation
• TextBox in UserCtrl bound to calculated property
• get data from database
• Bound DataGridViews Freezing Visual Studio?
• AutoComplete for DataGridViewTextboxCell