T
trint
How can I retrieve all of the data from a datagridview?
Any help is appreciated.
Thanks,
Trint
Any help is appreciated.
Thanks,
Trint
Trint,
What do you mean by all of the data? You can always get the DataSource
and use the DataMember properties to get the actual data.
Are you setting the source of the data, or can it be anything? By that,
I mean, are you always using a data set to show the data, or is it possible
that other data objects are used?
--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)
How can I retrieve all of the data from a datagridview?
Any help is appreciated.
Thanks,
Trint- Hide quoted text -
- Show quoted text -
trint said:Trint,
What do you mean by all of the data? You can always get the
DataSource
and use the DataMember properties to get the actual data.
Are you setting the source of the data, or can it be anything? By
that,
I mean, are you always using a data set to show the data, or is it
possible
that other data objects are used?
--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)
How can I retrieve all of the data from a datagridview?
Any help is appreciated.
Thanks,
Trint- Hide quoted text -
- Show quoted text -
My datagridview contains products information
code/name/price/salePrice/cost/overSize/stock/change(button)/
delete(button)
I want to know how to just retrieve the information displayed in the
datagridview so I can check
for changes or if something is deleted to send back to my sql server
tables.
Thanks,
Trint
Trint,
Right, but the grid has to be bound to something, like a dataset, a
collection, or something of that nature. It doesn't just magically get the
information. You should find out what the grid is bound to, and work with
that.
--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)
Trint,
What do you mean by all of the data? You can always get the
DataSource
and use the DataMember properties to get the actual data.
Are you setting the source of the data, or can it be anything? By
that,
I mean, are you always using a data set to show the data, or is it
possible
that other data objects are used?
--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)
How can I retrieve all of the data from a datagridview?
Any help is appreciated.
Thanks,
Trint- Hide quoted text -
- Show quoted text -My datagridview contains products information
I want to know how to just retrieve the information displayed in the
datagridview so I can check
for changes or if something is deleted to send back to my sql server
tables.
Thanks,
Trint- Hide quoted text -
- Show quoted text -
Trint,Right, but the grid has to be bound to something, like a dataset, a
collection, or something of that nature. It doesn't just magically get the
information. You should find out what the grid is bound to, and work with
that.news:[email protected]...On Jun 11, 11:00 am, "Nicholas Paldino [.NET/C# MVP]"
Trint,
What do you mean by all of the data? You can always get the
DataSource
and use the DataMember properties to get the actual data.
Are you setting the source of the data, or can it be anything? By
that,
I mean, are you always using a data set to show the data, or is it
possible
that other data objects are used?
--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)
How can I retrieve all of the data from a datagridview?
Any help is appreciated.
Thanks,
Trint- Hide quoted text -
- Show quoted text -
My datagridview contains products information
code/name/price/salePrice/cost/overSize/stock/change(button)/
delete(button)
I want to know how to just retrieve the information displayed in the
datagridview so I can check
for changes or if something is deleted to send back to my sql server
tables.
Thanks,
Trint- Hide quoted text -- Show quoted text -
Here is how I am binding to a datasource:
table0.Locale = System.Globalization.CultureInfo.InvariantCulture;
dataAdapter0.Fill(table0);
bindingSource7.DataSource = table0;
dataGridView7.DataSource = bindingSource7;
this.dataGridView7.Columns[0].Width = 75;
this.dataGridView7.Columns[1].Width = 75;
this.dataGridView7.Columns[2].Width = 75;
this.dataGridView7.Columns[3].Width = 75;
this.dataGridView7.Columns[4].Width = 75;
this.dataGridView7.Columns[5].Width = 75;
this.dataGridView7.Columns[6].Width = 75;
this.dataGridView7.Columns[7].Width = 75;
this.dataGridView7.Columns[8].Width = 75;
this.dataGridView7.Columns["Column3"].Width = 75;
this.dataGridView7.Columns["Column5"].Width = 75;
But this is just to display the data.
Thanks,Trint- Hide quoted text -
- Show quoted text -
trint said:Trint,Right, but the grid has to be bound to something, like a dataset, a
collection, or something of that nature. It doesn't just magically get
the
information. You should find out what the grid is bound to, and work
with
that.What do you mean by all of the data? You can always get the
DataSource
and use the DataMember properties to get the actual data.Are you setting the source of the data, or can it be anything?
By
that,
I mean, are you always using a data set to show the data, or is it
possible
that other data objects are used?How can I retrieve all of the data from a datagridview?
Any help is appreciated.
Thanks,
Trint- Hide quoted text -- Show quoted text -My datagridview contains products information
I want to know how to just retrieve the information displayed in the
datagridview so I can check
for changes or if something is deleted to send back to my sql server
tables.
Thanks,
Trint- Hide quoted text -- Show quoted text -
Here is how I am binding to a datasource:
table0.Locale = System.Globalization.CultureInfo.InvariantCulture;
dataAdapter0.Fill(table0);
bindingSource7.DataSource = table0;
dataGridView7.DataSource = bindingSource7;
this.dataGridView7.Columns[0].Width = 75;
this.dataGridView7.Columns[1].Width = 75;
this.dataGridView7.Columns[2].Width = 75;
this.dataGridView7.Columns[3].Width = 75;
this.dataGridView7.Columns[4].Width = 75;
this.dataGridView7.Columns[5].Width = 75;
this.dataGridView7.Columns[6].Width = 75;
this.dataGridView7.Columns[7].Width = 75;
this.dataGridView7.Columns[8].Width = 75;
this.dataGridView7.Columns["Column3"].Width = 75;
this.dataGridView7.Columns["Column5"].Width = 75;
But this is just to display the data.
Thanks,Trint- Hide quoted text -
- Show quoted text -
Here is what I want to do, but it doesn't allow it:
string selectedRows = string.Empty;
dataGridView7.SelectAll();
//dataGridView7.SelectedRows.ToString();
selectedRows = dataGridView7.SelectedRows.ToString();
Any help is appreciated.
Thanks,
Trint
Trint,
Why not just work with table0?
--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)
On Jun 11, 11:40 am, "Nicholas Paldino [.NET/C# MVP]"
Trint,
Right, but the grid has to be bound to something, like a dataset, a
collection, or something of that nature. It doesn't just magically get
the
information. You should find out what the grid is bound to, and work
with
that.
--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)
On Jun 11, 11:00 am, "Nicholas Paldino [.NET/C# MVP]"
Trint,
What do you mean by all of the data? You can always get the
DataSource
and use the DataMember properties to get the actual data.
Are you setting the source of the data, or can it be anything?
By
that,
I mean, are you always using a data set to show the data, or is it
possible
that other data objects are used?
--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)
How can I retrieve all of the data from a datagridview?
Any help is appreciated.
Thanks,
Trint- Hide quoted text -
- Show quoted text -
My datagridview contains products information
code/name/price/salePrice/cost/overSize/stock/change(button)/
delete(button)
I want to know how to just retrieve the information displayed in the
datagridview so I can check
for changes or if something is deleted to send back to my sql server
tables.
Thanks,
Trint- Hide quoted text -
- Show quoted text -
Here is how I am binding to a datasource:
table0.Locale = System.Globalization.CultureInfo.InvariantCulture;
dataAdapter0.Fill(table0);
bindingSource7.DataSource = table0;
dataGridView7.DataSource = bindingSource7;
this.dataGridView7.Columns[0].Width = 75;
this.dataGridView7.Columns[1].Width = 75;
this.dataGridView7.Columns[2].Width = 75;
this.dataGridView7.Columns[3].Width = 75;
this.dataGridView7.Columns[4].Width = 75;
this.dataGridView7.Columns[5].Width = 75;
this.dataGridView7.Columns[6].Width = 75;
this.dataGridView7.Columns[7].Width = 75;
this.dataGridView7.Columns[8].Width = 75;
this.dataGridView7.Columns["Column3"].Width = 75;
this.dataGridView7.Columns["Column5"].Width = 75;
But this is just to display the data.
Thanks,Trint- Hide quoted text -
- Show quoted text -Here is what I want to do, but it doesn't allow it:string selectedRows = string.Empty;
dataGridView7.SelectAll();
//dataGridView7.SelectedRows.ToString();
selectedRows = dataGridView7.SelectedRows.ToString();Any help is appreciated.
Thanks,
Trint- Hide quoted text -
- Show quoted text -
trint said:Trint,
Why not just work with table0?
--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)
On Jun 11, 11:40 am, "Nicholas Paldino [.NET/C# MVP]"Trint,Right, but the grid has to be bound to something, like a
dataset, a
collection, or something of that nature. It doesn't just magically
get
the
information. You should find out what the grid is bound to, and
work
with
that.What do you mean by all of the data? You can always get the
DataSource
and use the DataMember properties to get the actual data.Are you setting the source of the data, or can it be
anything?
By
that,
I mean, are you always using a data set to show the data, or is
it
possible
that other data objects are used?How can I retrieve all of the data from a datagridview?
Any help is appreciated.
Thanks,
Trint- Hide quoted text -- Show quoted text -My datagridview contains products information
I want to know how to just retrieve the information displayed in
the
datagridview so I can check
for changes or if something is deleted to send back to my sql
server
tables.
Thanks,
Trint- Hide quoted text -- Show quoted text -Here is how I am binding to a datasource:table0.Locale = System.Globalization.CultureInfo.InvariantCulture;
dataAdapter0.Fill(table0);
bindingSource7.DataSource = table0;
dataGridView7.DataSource = bindingSource7;this.dataGridView7.Columns[0].Width = 75;
this.dataGridView7.Columns[1].Width = 75;
this.dataGridView7.Columns[2].Width = 75;
this.dataGridView7.Columns[3].Width = 75;
this.dataGridView7.Columns[4].Width = 75;
this.dataGridView7.Columns[5].Width = 75;
this.dataGridView7.Columns[6].Width = 75;
this.dataGridView7.Columns[7].Width = 75;
this.dataGridView7.Columns[8].Width = 75;
this.dataGridView7.Columns["Column3"].Width = 75;
this.dataGridView7.Columns["Column5"].Width = 75;But this is just to display the data.
Thanks,Trint- Hide quoted text -- Show quoted text -Here is what I want to do, but it doesn't allow it:string selectedRows = string.Empty;
dataGridView7.SelectAll();
//dataGridView7.SelectedRows.ToString();
selectedRows = dataGridView7.SelectedRows.ToString();Any help is appreciated.
Thanks,
Trint- Hide quoted text -
- Show quoted text -
I'm not sure I understand what you mean...Don't I first have to know
what has changed
and how to get it from the grid? I will work with the table after I
know what I have in the datagridview.
What am I missing?
Thanks,
Trint
Trint,
If you have set the data source of the grid to the table, then when you
make changes in the grid, the DataTable (table0) will be updated
accordingly.
--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)
Trint,
Why not just work with table0?
--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)
On Jun 11, 11:40 am, "Nicholas Paldino [.NET/C# MVP]"
Trint,
Right, but the grid has to be bound to something, like a
dataset, a
collection, or something of that nature. It doesn't just magically
get
the
information. You should find out what the grid is bound to, and
work
with
that.
--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)
On Jun 11, 11:00 am, "Nicholas Paldino [.NET/C# MVP]"
Trint,
What do you mean by all of the data? You can always get the
DataSource
and use the DataMember properties to get the actual data.
Are you setting the source of the data, or can it be
anything?
By
that,
I mean, are you always using a data set to show the data, or is
it
possible
that other data objects are used?
--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)
How can I retrieve all of the data from a datagridview?
Any help is appreciated.
Thanks,
Trint- Hide quoted text -
- Show quoted text -
My datagridview contains products information
code/name/price/salePrice/cost/overSize/stock/change(button)/
delete(button)
I want to know how to just retrieve the information displayed in
the
datagridview so I can check
for changes or if something is deleted to send back to my sql
server
tables.
Thanks,
Trint- Hide quoted text -
- Show quoted text -
Here is how I am binding to a datasource:
table0.Locale = System.Globalization.CultureInfo.InvariantCulture;
dataAdapter0.Fill(table0);
bindingSource7.DataSource = table0;
dataGridView7.DataSource = bindingSource7;
this.dataGridView7.Columns[0].Width = 75;
this.dataGridView7.Columns[1].Width = 75;
this.dataGridView7.Columns[2].Width = 75;
this.dataGridView7.Columns[3].Width = 75;
this.dataGridView7.Columns[4].Width = 75;
this.dataGridView7.Columns[5].Width = 75;
this.dataGridView7.Columns[6].Width = 75;
this.dataGridView7.Columns[7].Width = 75;
this.dataGridView7.Columns[8].Width = 75;
this.dataGridView7.Columns["Column3"].Width = 75;
this.dataGridView7.Columns["Column5"].Width = 75;
But this is just to display the data.
Thanks,Trint- Hide quoted text -
- Show quoted text -
Here is what I want to do, but it doesn't allow it:
string selectedRows = string.Empty;
dataGridView7.SelectAll();
//dataGridView7.SelectedRows.ToString();
selectedRows = dataGridView7.SelectedRows.ToString();
Any help is appreciated.
Thanks,
Trint- Hide quoted text -
- Show quoted text -I'm not sure I understand what you mean...Don't I first have to know
what has changed
and how to get it from the grid? I will work with the table after I
know what I have in the datagridview.
What am I missing?
Thanks,
Trint- Hide quoted text -
- Show quoted text -