Advertisement

01.14.2006 at 03:53AM PST, ID: 21696463
[x]
Attachment Details

DataGridView: Add row/read cells/

Asked by codemaster3 in Microsoft Visual Basic.Net

Tags: datagridview, add, row

Ok so, I wanted to make a pretty table for my program as the user would need to specify a string and a long, but they'd need to go together... Instead of using parallel listboxes, textboxes or else, I just went with the DataGridView, which does exactly what I want it to do... However, now I have a few problems:
1. I've managed to add a new row with a string in the first column, but how do I specify what to be put on the second column?
2. I need to know how to make a loop to read every row and return all the data in each column seperately (get an array for the first column, get another array for the second).
3. How do I delete the row in which the user has a cell selected? For example:

Name  | Year
Wilbur | 1984
[John] | 1975

John is selected (the cell is blue), how do I delete that row? I can't find any way to detect the currently selected cell... Much less the row in which the cell resides.

150 points each one of those above... Thanks for the help =D.Start Free Trial
[+][-]01.14.2006 at 07:08PM PST, ID: 15703257

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]01.14.2006 at 07:10PM PST, ID: 15703263

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]01.14.2006 at 09:02PM PST, ID: 15703468

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]01.15.2006 at 07:31PM PST, ID: 15707953

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zone: Microsoft Visual Basic.Net
Tags: datagridview, add, row
Sign Up Now!
Solution Provided By: MattFenner
Participating Experts: 1
Solution Grade: A
 
 
[+][-]01.16.2006 at 03:45AM PST, ID: 15709513

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]01.16.2006 at 04:13AM PST, ID: 15709651

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]01.16.2006 at 04:16AM PST, ID: 15709662

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]01.18.2006 at 10:26PM PST, ID: 15736613

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32