Solved

Adding New Rows from Empty Template -> DataGridView

Posted on 2010-08-23
4
410 Views
Last Modified: 2013-11-27

In VB.Net / VS 2005 - Windows App.

Adding New Rows from Empty Template -> DataGridView

Using Insert Template Option
0
Comment
Question by:chokka
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
4 Comments
 
LVL 18

Expert Comment

by:John (Yiannis) Toutountzoglou
ID: 33506158
hi..
you can use subroutine Add
like
Dim n As Integer = DataGridView1.Rows.Add()
        DataGridView1.Rows.Item(n).Cells(0).Value = "something"
        DataGridView1.Rows.Item(n).Cells(1).Value = "something else"
    End Sub

If your datagridview is databound then we are talking aboutadd rows to a datatable
0
 
LVL 18

Accepted Solution

by:
John (Yiannis) Toutountzoglou earned 500 total points
ID: 33506260
0
 

Author Comment

by:chokka
ID: 33506652
Its a complicated DataGridView..

It has 5 Columns ..!

In the 5th Column we need to have a ComboBox which is already populated from Database.


Column1,Column2,Column3,Column4 have to entered from the application

0
 
LVL 18

Expert Comment

by:John (Yiannis) Toutountzoglou
ID: 33508197
you have already the datagridview and you want to pass values in a row ?
0

Featured Post

Why You Need a DevOps Toolchain

IT needs to deliver services with more agility and velocity. IT must roll out application features and innovations faster to keep up with customer demands, which is where a DevOps toolchain steps in. View the infographic to see why you need a DevOps toolchain.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

In my previous article (http://www.experts-exchange.com/Programming/Languages/.NET/.NET_Framework_3.x/A_4362-Serialization-in-NET-1.html) we saw the basics of serialization and how types/objects can be serialized to Binary format. In this blog we wi…
This document covers how to connect to SQL Server and browse its contents.  It is meant for those new to Visual Studio and/or working with Microsoft SQL Server.  It is not a guide to building SQL Server database connections in your code.  This is mo…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question