Click here to Skip to main content
15,889,281 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Missmach type Pin
Vimalsoft(Pty) Ltd16-May-07 19:50
professionalVimalsoft(Pty) Ltd16-May-07 19:50 
AnswerRe: Missmach type Pin
nlarson1116-May-07 7:59
nlarson1116-May-07 7:59 
GeneralRe: Missmach type Pin
Dave Kreskowiak16-May-07 8:21
mveDave Kreskowiak16-May-07 8:21 
GeneralRe: Missmach type Pin
nlarson1116-May-07 8:24
nlarson1116-May-07 8:24 
GeneralRe: Missmach type Pin
Vimalsoft(Pty) Ltd16-May-07 20:24
professionalVimalsoft(Pty) Ltd16-May-07 20:24 
GeneralRe: Missmach type Pin
Dave Kreskowiak17-May-07 2:44
mveDave Kreskowiak17-May-07 2:44 
Questioncopy object attributes Pin
Marc Soleda16-May-07 6:05
Marc Soleda16-May-07 6:05 
AnswerRe: copy object attributes [modified] Pin
Dave Kreskowiak16-May-07 6:24
mveDave Kreskowiak16-May-07 6:24 
I've never had the need to do this, so a litte research is in order...

There's no way to copy a DGV in one line of code, no.

The most correct way to do this would be to put the code that setups up your grid properties into a shared method, then just pass the datagrid object you want setup by refrence. Done. No need to copy the object.

Other than that, you'd have to create a method that takes a DGV ByRef as a parameter, then code it to create a new DGV object, copy all the properties you want from the supplied DGV to the new one, then return the new object as a return value.


[EDIT]
You could probably do this with Reflection though.



-- modified at 12:32 Wednesday 16th May, 2007

A guide to posting questions on CodeProject[^]

Dave Kreskowiak
Microsoft MVP
Visual Developer - Visual Basic
     2006, 2007


QuestionDevelop Audio Video Conferencing System Pin
Rupesh Kumar Swami16-May-07 5:46
Rupesh Kumar Swami16-May-07 5:46 
AnswerRe: Develop Audio Video Conferencing System Pin
Dave Kreskowiak16-May-07 6:14
mveDave Kreskowiak16-May-07 6:14 
Questioncount number of rows in table Pin
peteyshrew16-May-07 3:40
peteyshrew16-May-07 3:40 
AnswerRe: count number of rows in table Pin
kubben16-May-07 4:01
kubben16-May-07 4:01 
GeneralRe: count number of rows in table Pin
peteyshrew16-May-07 4:19
peteyshrew16-May-07 4:19 
GeneralRe: count number of rows in table Pin
peteyshrew16-May-07 4:34
peteyshrew16-May-07 4:34 
GeneralRe: count number of rows in table Pin
Dave Kreskowiak16-May-07 4:39
mveDave Kreskowiak16-May-07 4:39 
Questionsyntax error Pin
peteyshrew16-May-07 3:05
peteyshrew16-May-07 3:05 
AnswerRe: syntax error Pin
andyharman16-May-07 3:53
professionalandyharman16-May-07 3:53 
GeneralRe: syntax error Pin
peteyshrew16-May-07 4:19
peteyshrew16-May-07 4:19 
QuestionInsert Stored Procedure taking values from vb Help Pin
Vimalsoft(Pty) Ltd16-May-07 3:00
professionalVimalsoft(Pty) Ltd16-May-07 3:00 
AnswerRe: Insert Stored Procedure taking values from vb Help Pin
Dave Kreskowiak16-May-07 4:11
mveDave Kreskowiak16-May-07 4:11 
GeneralRe: Insert Stored Procedure taking values from vb Help Pin
Vimalsoft(Pty) Ltd16-May-07 4:19
professionalVimalsoft(Pty) Ltd16-May-07 4:19 
GeneralRe: Insert Stored Procedure taking values from vb Help [modified] Pin
Vimalsoft(Pty) Ltd16-May-07 4:19
professionalVimalsoft(Pty) Ltd16-May-07 4:19 
GeneralRe: Insert Stored Procedure taking values from vb Help Pin
Dave Kreskowiak16-May-07 4:31
mveDave Kreskowiak16-May-07 4:31 
Questionhow do i edit a selected row or record in sql database through datagrid during runtime? Pin
sathyan_829416-May-07 2:51
sathyan_829416-May-07 2:51 
AnswerRe: how do i edit a selected row or record in sql database through datagrid during runtime? Pin
Dave Kreskowiak16-May-07 4:29
mveDave Kreskowiak16-May-07 4:29 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.