Click here to Skip to main content
15,897,187 members
Home / Discussions / C#
   

C#

 
GeneralRe: How do you format your code? [edit] fixed a bit [/edit] Pin
leppie18-May-04 9:28
leppie18-May-04 9:28 
AnswerRe: How do you format your code? [edit] fixed a bit [/edit] Pin
Heath Stewart18-May-04 9:27
protectorHeath Stewart18-May-04 9:27 
GeneralRe: How do you format your code? [edit] fixed a bit [/edit] Pin
Adam °Wimsatt18-May-04 9:31
Adam °Wimsatt18-May-04 9:31 
GeneralDatagrid quation Pin
Ashki18-May-04 6:18
Ashki18-May-04 6:18 
GeneralRe: Datagrid quation Pin
Heath Stewart18-May-04 6:31
protectorHeath Stewart18-May-04 6:31 
GeneralDeserialization Pin
cristina_tudor18-May-04 5:54
cristina_tudor18-May-04 5:54 
GeneralRe: Deserialization Pin
Heath Stewart18-May-04 6:27
protectorHeath Stewart18-May-04 6:27 
GeneralTrying to understand DataSet and XML Pin
Adam °Wimsatt18-May-04 5:13
Adam °Wimsatt18-May-04 5:13 
Check this code out:
string path = MapPath("faq.xml");
DataSet ds = new DataSet();
ds.ReadXml(path);
XMLGrid.DataSource = ds;
XMLGrid.DataBind();
faq.xml looks like:
<faq>
  <sub>
    <q>stuff here</q>
    <i>stuff here</i>
    <a>stuff here</a>
  </sub>
  <sub>
    <q>stuff here too</q>
    <i>stuff here too</i>
    <i>note this is I</i>
    <a>stuff here too</a>
  </sub>
</faq>
Note that there are two <i> tags in the second sub and only 1 in the first. The code for reading this xml file is a autogenerate columns datagrid and what I get is: Submission_ID and numbers in the column for i instead of two i columns.... I'm guessing there is a way to use the Submission_ID to get at that data, but I'm not sure how to do it programatically. I haven't been successful in googling yet... Any ideas? The following code prints the same Submission_id thing as the datagrid does:
foreach (DataRow dr in ds.Tables[0].Rows)
{
  for ( int i = 0; i < dr.ItemArray.Length; i++ )
  {
    PrintString(dr[i] + "<br>");
  }
  PrintString ("<br>"); 
}


side note: How do you use a < in <code> tags without having to type in the html code for it each time?
GeneralRe: Trying to understand DataSet and XML Pin
Heath Stewart18-May-04 5:23
protectorHeath Stewart18-May-04 5:23 
GeneralRe: Trying to understand DataSet and XML Pin
Adam °Wimsatt18-May-04 5:29
Adam °Wimsatt18-May-04 5:29 
GeneralRe: Trying to understand DataSet and XML Pin
Heath Stewart18-May-04 5:31
protectorHeath Stewart18-May-04 5:31 
GeneralRe: Trying to understand DataSet and XML Pin
Adam °Wimsatt18-May-04 5:37
Adam °Wimsatt18-May-04 5:37 
GeneralAutoPostBack Pin
gmhanna18-May-04 4:41
gmhanna18-May-04 4:41 
GeneralRe: AutoPostBack Pin
Heath Stewart18-May-04 5:18
protectorHeath Stewart18-May-04 5:18 
Questiondo i use crystal reports or sql2000 reporting services? Pin
robmays18-May-04 4:04
robmays18-May-04 4:04 
AnswerRe: do i use crystal reports or sql2000 reporting services? Pin
Heath Stewart18-May-04 4:35
protectorHeath Stewart18-May-04 4:35 
GeneralRe: do i use crystal reports or sql2000 reporting services? Pin
Guillermo Rivero18-May-04 5:55
Guillermo Rivero18-May-04 5:55 
GeneralC# and file access permission failures on Windows 2000 Pin
Parrish18-May-04 1:55
Parrish18-May-04 1:55 
GeneralRe: C# and file access permission failures on Windows 2000 Pin
Dave Kreskowiak18-May-04 2:51
mveDave Kreskowiak18-May-04 2:51 
GeneralRe: C# and file access permission failures on Windows 2000 Pin
Parrish18-May-04 4:12
Parrish18-May-04 4:12 
GeneralRe: C# and file access permission failures on Windows 2000 Pin
Heath Stewart18-May-04 3:59
protectorHeath Stewart18-May-04 3:59 
GeneralRe: C# and file access permission failures on Windows 2000 Pin
Parrish18-May-04 4:17
Parrish18-May-04 4:17 
GeneralPocket PC 2002 and C# Pin
RobMenegon18-May-04 1:44
professionalRobMenegon18-May-04 1:44 
GeneralRe: Pocket PC 2002 and C# Pin
Heath Stewart18-May-04 4:02
protectorHeath Stewart18-May-04 4:02 
GeneralRe: Pocket PC 2002 and C# Pin
RobMenegon18-May-04 11:46
professionalRobMenegon18-May-04 11:46 

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.