DotConnect for oracle, column name.

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for Oracle
Post Reply
Gregg
Posts: 2
Joined: Wed 07 Oct 2009 05:57

DotConnect for oracle, column name.

Post by Gregg » Wed 07 Oct 2009 09:16

Hello, lately I straggle with such situation. I retrieve data from database (from one of views) and I bind this List of elements to gridcontrol (devExpress). Next, I want to hide one of the columns and here is the problem...I cannot hide the column without the knowledge about the column name...The column name is different than property name....(ex. TD_Table is changed to TdTable). Is there any possibility that the generated property name is the same as in database? or Can I obtain the list of columns names (I need this list in design time)?

Pleas help,
Greg

Shalex
Devart Team
Posts: 8086
Joined: Thu 14 Aug 2008 12:44

Post by Shalex » Fri 09 Oct 2009 12:44

I have tried dotConnect for Oracle 5.25.44 and DevExpress 9.2.6:
1) created a WinForms project;
2) generated typed Devart DataSet via DataSet Wizard (Tools | Oracle | DataSet Wizard);
3) placed DevExpress.XtraGrid.GridControl to Form Designer, assigned its DataSource property to the table from my DataSet;
4) GridControl's context menu -> Run Designer | selected the Columns section from the Main window and deleted the unnecessary column from the Columns list.

It works. This column is not displayed on GridControl anymore. Is that what you mean?

Gregg
Posts: 2
Joined: Wed 07 Oct 2009 05:57

Post by Gregg » Mon 19 Oct 2009 09:35

I don't want to use designer...better choice is execute this in code ex.

Code: Select all

(gridView.MainView as GridView).Columns["columnName"].Visible=False;
Here I need a column name...In .net controls(for MSSQL) columnName is always the column name from database and in your product TD_Table is changed to TdTable...Is there any possibility to obtain the columnName for particular Property?
Greg

Shalex
Devart Team
Posts: 8086
Joined: Thu 14 Aug 2008 12:44

Post by Shalex » Mon 19 Oct 2009 11:09

Your code works fine with actual column names in my environment with DevExpress.XtraGrid.GridControl 9.2.6.0. Anyway, this is the DevExpress control. Please contact DevExpress support team.

Post Reply