473,394 Members | 1,658 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

how can one empty-out DataGridView1 object?

Joe
does anyone have any clue??

Mar 20 '07 #1
5 1183
"Joe" <jo*****@tlen.plwrote in news:1174422087.617334.162720
@b75g2000hsg.googlegroups.com:
does anyone have any clue??

You can set the DataSource to nothing. I believe that clears the grid.

Mar 20 '07 #2
Joe
On Mar 20, 3:43 pm, Spam Catcher <spamhoney...@rogers.comwrote:
"Joe" <joe1...@tlen.plwrote in news:1174422087.617334.162720
@b75g2000hsg.googlegroups.com:
does anyone have any clue??

You can set the DataSource to nothing. I believe that clears the grid.
unfortunately, it did not :(

Mar 23 '07 #3

"Joe" <jo*****@tlen.plwrote in message
news:11**********************@e65g2000hsc.googlegr oups.com...
On Mar 20, 3:43 pm, Spam Catcher <spamhoney...@rogers.comwrote:
>"Joe" <joe1...@tlen.plwrote in news:1174422087.617334.162720
@b75g2000hsg.googlegroups.com:
does anyone have any clue??

You can set the DataSource to nothing. I believe that clears the grid.

unfortunately, it did not :(
Is your DataGridView bound to a data source? or are you filling it
manually?

Robin S.
Mar 23 '07 #4
Joe
On Mar 23, 5:04 pm, "RobinS" <Rob...@NoSpam.yah.nonewrote:
"Joe" <joe1...@tlen.plwrote in message

news:11**********************@e65g2000hsc.googlegr oups.com...
On Mar 20, 3:43 pm, Spam Catcher <spamhoney...@rogers.comwrote:
"Joe" <joe1...@tlen.plwrote in news:1174422087.617334.162720
@b75g2000hsg.googlegroups.com:
does anyone have any clue??
You can set the DataSource to nothing. I believe that clears the grid.
unfortunately, it did not :(

Is your DataGridView bound to a data source? or are you filling it
manually?

Robin S.
data source!! I never use it "manually". I just (after all day) want
to clear this window out...

Mar 24 '07 #5

"Joe" <jo*****@tlen.plwrote in message
news:11**********************@y80g2000hsf.googlegr oups.com...
On Mar 23, 5:04 pm, "RobinS" <Rob...@NoSpam.yah.nonewrote:
>"Joe" <joe1...@tlen.plwrote in message

news:11**********************@e65g2000hsc.googleg roups.com...
On Mar 20, 3:43 pm, Spam Catcher <spamhoney...@rogers.comwrote:
"Joe" <joe1...@tlen.plwrote in news:1174422087.617334.162720
@b75g2000hsg.googlegroups.com:
does anyone have any clue??
>You can set the DataSource to nothing. I believe that clears the
grid.
unfortunately, it did not :(

Is your DataGridView bound to a data source? or are you filling it
manually?

Robin S.

data source!! I never use it "manually". I just (after all day) want
to clear this window out...
Assuming you're using .Net 2.0, try using a Binding Source.

Dim myBindingSource as BindingSource = New BindingSource()

myBindingSource.DataSource = myDataSet.Tables(0)
myDataGridView.DataSource = myBindingSource

Then see what happens when you clear your dataset (set it to nothing). The
BindingSource handles the link between the data and the display, it's kind
of like lubrication between gears. It responds immediately to changes in
the data source.

Robin S.
Mar 24 '07 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

13
by: Mikko Ohtamaa | last post by:
From XML specification: The representation of an empty element is either a start-tag immediately followed by an end-tag, or an empty-element tag. (This means that <foo></foo> is equal to...
13
by: vega | last post by:
How do I detect empty tags if I have the DOM document? For example: <br /> and <br></br> I tried org.w3c.dom.Node.getFirstChild(), it returns null for both <br /> and <br></br> I also tried...
12
by: Stefan Weiss | last post by:
Hi. (this is somewhat similar to yesterday's thread about empty links) I noticed that Tidy issues warnings whenever it encounters empty tags, and strips those tags if cleanup was requested....
1
by: tMan | last post by:
whats the xpath to get all the empty nodes in a document. in the xml below i want to get the nodes <empty> and <t> all other nodes either have a child node or text in them <root> <test> <se>...
19
by: Dennis | last post by:
I have a public variable in a class of type color declared as follows: public mycolor as color = color.Empty I want to check to see if the user has specified a color like; if mycolor =...
2
by: Bob Stearns | last post by:
I thought that the given expression was always TRUE if "not_there" wasn't among the keys (or subscripts if you will) of $_SESSION. Below find a dump of $_SESSION, a small snippet of code and the...
14
by: cj | last post by:
What is string.empty used for? I can't say: if string.empty then I have to use: if string = "" then which is ok, I just want to know what .empty is for.
35
by: Smithers | last post by:
I have been told that it is a good idea to *always* declare string variables with a default value of string.Empty - for cases where an initial value is not known... like this: string myString =...
5
by: Per Juul Larsen | last post by:
Hi. My application creates empty libraries. How do I ensure that the user copies at least one or more picture files (.jpg) in each of the empty folders ? Result , no empty folders! regards pjl
21
by: Sami | last post by:
string = "" or string = string.Empty? should is the proper way? Sami
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.