We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Identifying column index from selected column?

Thread ID:

Created:

Updated:

Platform:

Replies:

3937 Apr 19,2003 11:47 AM UTC Apr 19,2003 01:05 PM UTC WinForms 1
loading
Tags: GridControl
Jeremy Holt
Asked On April 19, 2003 11:47 AM UTC

How do I identify the underlying column index from a selected column? I want to be able to determine the mapping name of the selected column (one column only). Using ... Dim colIndex as integer = Me.GridDataBoundGrid1.Selections.Ranges.Item(0).Left Dim FieldIndex as integer = Me.GridDataBoundGrid1.Binder.ColIndexToField(colIndex) dv.table.columns(FieldIndex) does not work - colIndex is not pointing to the right column. On another note - I have been messing around with the suite for a few days. While it is very elegant, and far outshines anything else on the market, I think the documentation is very poor. The samples only go so far, the white paper gives a broad overview, but the help files are crying out for examples. I appreciate that this forum is quite unique - I've never seen a product so well supported by the developers, but I confess to feeling rather guilty asking my "stupid?" questions in public - I would be happier being able to find my answers in the help files .... Thanks Jeremy

Administrator [Syncfusion]
Replied On April 19, 2003 01:05 PM UTC

There is no correspondance of fieldNum to datatable column as not all columns in a datatable have to be columns in the grid. If you want to access a particular column in the DataTable, then you should use the MappingName property of the GridBoundColumnt to access it.
Dim colIndex as integer = Me.GridDataBoundGrid1.Selections.Ranges.Item(0).Left 

Dim FieldIndex as integer = Me.GridDataBoundGrid1.Binder.ColIndexToField(colIndex) 

Dim colName as String = Me.GridDataBoundGrid1.Binder.InternalColumns(FieldIndex).MappingName

''  dv.table.columns(colName)

You actually get better support through our Direct Trac support system which also offers a nonpublic support venue. You don't not have to post questions in this forum unless you want to do so. We are working to improve the reference material made available with the product.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;