Click here to Skip to main content
15,889,281 members
Home / Discussions / C#
   

C#

 
AnswerRe: HOW TO SPREAD TEXT OVER COLUMNS IN A LISTVIEW IN C# Pin
Alvaro Mendez17-Sep-03 5:58
Alvaro Mendez17-Sep-03 5:58 
GeneralWait Cursor Pin
Joel Matthias16-Sep-03 9:52
Joel Matthias16-Sep-03 9:52 
GeneralSelected Checkbox... Pin
.gonad16-Sep-03 9:28
.gonad16-Sep-03 9:28 
GeneralRe: Selected Checkbox... Pin
Tomas Petricek16-Sep-03 9:44
Tomas Petricek16-Sep-03 9:44 
GeneralRe: Selected Checkbox... Pin
.gonad16-Sep-03 10:46
.gonad16-Sep-03 10:46 
GeneralRe: Selected Checkbox... Pin
Tomas Petricek16-Sep-03 10:56
Tomas Petricek16-Sep-03 10:56 
GeneralCollection Pin
yyf16-Sep-03 8:59
yyf16-Sep-03 8:59 
GeneralNeed help with winforms treeview control Pin
Ramesh11046616-Sep-03 6:26
Ramesh11046616-Sep-03 6:26 
I want to populate a winforms treeview control from a relational table without xml in c#.net. I am new to c#, so please bear with me. I set up the oracle connection, dataadapter, fill etc. The code is given below.
My problem is that I have put messagebox and see that
this.treeView1.Nodes.Add(nodeAuthor); seems to add the nodes, but when the program completes and displays the form, I do not see the group_desc populated at all. I did not add anything manually in the Nodes property in Treeview. Please help!!!

this.treeView1 = new System.Windows.Forms.TreeView();
this.oracleConnection1 = new System.Data.OracleClient.OracleConnection();
this.oracleDataAdapter1 = new System.Data.OracleClient.OracleDataAdapter();

this.oracleConnection1.ConnectionString = "the connection strings"; string strSQLAuthors = "SELECT GROUP_MASTER.GROUP_DESC " +
" FROM " +
"GROUP_MASTER ORDER BY GROUP_MASTER.GROUP_DESC ";

TreeNode nodeAuthor;
DataSet ds;

//Create the Connection and the DataSet object, and then open the connection.

ds = new DataSet();
oracleConnection1.Open();

oracleDataAdapter1 = new OracleDataAdapter(strSQLAuthors, oracleConnection1);
oracleDataAdapter1.Fill(ds, "GROUP_MASTER");


//Populate the TreeView from the DataSet.
foreach (DataRow rowAuthor in ds.Tables["GROUP_MASTER"].Rows)
{
nodeAuthor = new TreeNode();
nodeAuthor.Text = rowAuthor["GROUP_DESC"].ToString();
this.treeView1.Nodes.Add(nodeAuthor);
}

//Clean up.
ds.Dispose();
oracleDataAdapter1.Dispose(); oracleConnection1.Close();
oracleConnection1.Dispose();



ram
GeneralWindows Forms, Formating Edit Box Pin
Braulio Dez16-Sep-03 4:26
Braulio Dez16-Sep-03 4:26 
GeneralRe: Windows Forms, Formating Edit Box Pin
Alvaro Mendez16-Sep-03 5:09
Alvaro Mendez16-Sep-03 5:09 
GeneralRe: Windows Forms, Formating Edit Box Pin
Braulio Dez16-Sep-03 5:41
Braulio Dez16-Sep-03 5:41 
GeneralRe: Windows Forms, Formating Edit Box Pin
Alvaro Mendez16-Sep-03 6:16
Alvaro Mendez16-Sep-03 6:16 
GeneralRe: Windows Forms, Formating Edit Box Pin
Braulio Dez16-Sep-03 5:47
Braulio Dez16-Sep-03 5:47 
GeneralPort Number in Web Services Pin
cman719716-Sep-03 3:51
cman719716-Sep-03 3:51 
Generalsending packets over TCP Pin
WildFuse16-Sep-03 2:19
WildFuse16-Sep-03 2:19 
GeneralRe: sending packets over TCP Pin
Smitha Nishant16-Sep-03 3:54
protectorSmitha Nishant16-Sep-03 3:54 
GeneralRe: sending packets over TCP Pin
WildFuse16-Sep-03 21:17
WildFuse16-Sep-03 21:17 
GeneralC# coding Pin
ASGill16-Sep-03 0:41
ASGill16-Sep-03 0:41 
GeneralRe: C# coding Pin
Frank Olorin Rizzi16-Sep-03 1:30
Frank Olorin Rizzi16-Sep-03 1:30 
GeneralDeserialization problem.. Pin
morefire15-Sep-03 22:20
morefire15-Sep-03 22:20 
GeneralRe: Deserialization problem.. Pin
MeisterBiber17-Sep-03 4:25
MeisterBiber17-Sep-03 4:25 
GeneralRe: Deserialization problem.. Pin
morefire17-Sep-03 4:51
morefire17-Sep-03 4:51 
GeneralPInvoke and classes Pin
Rheikon15-Sep-03 21:26
Rheikon15-Sep-03 21:26 
GeneralRe: PInvoke and classes Pin
Daniel Turini16-Sep-03 1:01
Daniel Turini16-Sep-03 1:01 
GeneralRe: PInvoke and classes Pin
Anonymous16-Sep-03 1:54
Anonymous16-Sep-03 1:54 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.