TableLayoutPanel + databind + xml

  • Thread starter Thread starter erik
  • Start date Start date
E

erik

Hi!
Does anyone know if I can bind a XML file directly to the
tableLayoutPanel control to decide how many rows and colums the table
shoul contain. And how should the XML in that case look like?
Regards Erik
 
I think it will be very easy if you set the rowcount and columncount in
the app.cofig(also a xml file).
eg: the code snippet in the app.config
<appSettings>
<!--TableLayoutPanel.ColumnCount-->
<add key="ColumnCount" value="4"/>
<!--TableLayoutPanel.RowCount-->
<add key="RowCount" value="3"/>
</appSettings>
Then you can read them out using the code like this:
String
rowCount=System.Configuration.ConfigurationSettings.AppSettings["RowCount"];
int rowCountValue=int.Parse(rowCount);
 
OK, I'll will try that. I'm looking for more examples. Do you know
where I might find some?
 
Back
Top