473,396 Members | 1,886 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,396 software developers and data experts.

DataGridView with blank cells?

Max

Hello,

I have a datagridview object on my form along with some other controls. When the application runs, the datagridview is populated
with data from a database. Although the right number of records is displayed, all the cells in each record are blank. Any idea why?

Thanks,
Max.

Jun 12 '07 #1
3 2900
On 12 Jun, 15:16, "Max" <maxy_...@yahoo.comwrote:
Hello,

I have a datagridview object on my form along with some other controls. When the application runs, the datagridview is populated
with data from a database. Although the right number of records is displayed, all the cells in each record are blank. Any idea why?

Thanks,
Max.
Hello,

I take it you have checked the database and there is actually data
there?

Cheers,
Gary
http://www.garyshort.org

Jun 12 '07 #2
Max
Yes, there is data, and I fixed the problem. What I did was, I created columns in the dgv object and when I set the datasource to a
table the table columns appended to the ones in the dgv even though they had the same name. Obviously I couldn't see these extra
columns in my workspace area but once I enlarged the dgv I realized what was wrong. Removed the extra columns and now everything is
fine.

Thanks,
Max.

<ga**@garyshort.orgwrote in message news:11**********************@r19g2000prf.googlegr oups.com...
On 12 Jun, 15:16, "Max" <maxy_...@yahoo.comwrote:
>Hello,

I have a datagridview object on my form along with some other controls. When the application runs, the datagridview is
populated
with data from a database. Although the right number of records is displayed, all the cells in each record are blank. Any idea
why?

Thanks,
Max.

Hello,

I take it you have checked the database and there is actually data
there?

Cheers,
Gary
http://www.garyshort.org
Jun 12 '07 #3
Hi,

How do you populate your dataGridView? Sp or select statement?
Does your Query returns any results? Otherwise you get an empty view.

David

"Max" <ma******@yahoo.comwrote in message
news:e1**************@TK2MSFTNGP06.phx.gbl...
>
Hello,

I have a datagridview object on my form along with some other controls.
When the application runs, the datagridview is populated with data from a
database. Although the right number of records is displayed, all the cells
in each record are blank. Any idea why?

Thanks,
Max.
Jun 12 '07 #4

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

Similar topics

3
by: tshad | last post by:
How do I get blank cells to show in my dataGrid? I am databinding to my datagrid, but any cells that are blank, don't show. Normally, you would put an &nbsp in the cell to make IE display the...
7
by: Rainer Queck | last post by:
Hi NG, Why is it, that in my DataGridView all columns which are not bound to a "DataProperty" loos thier content in a couple of occasions? This happens if: - Underlaying...
6
by: RigasMinho | last post by:
I have a table that is made in XSL that grabs the information from an XML sheet. However any cell that is blank in XML the border doesnt show up when you view it. Is there a work around for...
1
by: Kevin S Gallagher | last post by:
I am looking for advice/code to assist in determining which cells are visible on a DGV. The code below works but wanted to see if there are better methods or perhaps the code below has issues I...
0
by: forgedascendant | last post by:
Can someone tell me how to find and then select a blank cell from a list of data? Thanks, Aaron
1
by: jkozik | last post by:
I am trying to write a iif statement that returns "0" if the cell is blank, otherwise a "1". For some reason this filter returns only 1's regardless of whether the cell is field is blank or not. ...
2
by: JP Romano | last post by:
Hello - have gotten some great advice from your site, so I figured I'd join and see how much more I can learn. Not a programmer, but am working on a project which requires me to do some VBA...
5
by: liadmz | last post by:
Hi All, I'm looking for a way to merge cells by their content in DataGridView. For Ex' 2257 How can I implement this table using DataGridView ?
0
by: Davide Menini | last post by:
Hi, this is my question: I've a stored procedure in a sql server. I can display the rows in a datagridview passing through a datatable that load the corresponding datareader. All I need is to...
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: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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: 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
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
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
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.