DataGrid

M

Maxim

Hi, everybody!

I've got a couple of questions.

I have a DataSet containing several Tables. DataSet is populating from XML
file, which is being prepared by desktop app.
First of all, I have problems when trying to read schema & data from XML. So
I read xsd-file with no problems. Then I get exception when trying to read
data. There are no problems when I read XML data file alone. So I need to
manually modify XML data file to insert empty tables and empty elements,
because empty tables are not put into XML. The same is with null elements.
What is wrong here?

Second question is about DataGrid. I'd like to display some of the Tables in
DataSet in a DataGrid. That's OK. But when I show a Table in Grid all the
columns are diaplayed. But I need only a small number of culumns to be
displayed. How do I do that?
Also is there a possibility to display ComboBox & CheckBox in Grid cells?

Sorry for my probably stupid questions, but I'm new to .NET and I couldn't
find answers in MSDN. And thanks in advance.

PS. Using .NET CF 2.0.
 
S

Steven Nagy

RE: XML
Not sure why your XSD would require empty tables and fields?
This is probably the issue, not the fact that your XML is missing these
empty fields.
Check your XSD.

RE: Datagrid columns
You need to check out DataGridTableStyle and DataGridTextboxColumn
 
M

michael.nebinger

Look up DataView. Link just the columns you want to the DataView, then
use the dataview as the data source for your grid.
 
M

michael.nebinger

Look up DataView. Link just the columns you want to the DataView, then
use the dataview as the data source for your grid.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top