i use a Dialog to input the contact details
i have 7 dialog's and 7 Label's
Name + Textbox for giving contact details , ...
then i click the button and i thougt to use this code
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
'I have set it to false so they have to use the dialog to make the contacts but i dont think its the best way'
Form2.DataGridView1.AllowUserToAddRows = True
'Simpel Check For checking phone number and Name has values(user must give the value)'
If TextBox1.Text = "" And TextBox6.Text = "" Then
'if not a msgbox shows up with the text your forgotten the name and phone number of the contact plz fill these in'
MsgBox("U bent vergeten de voornaam en telefoon nummer in te vullen , Vul die Aub in !", MsgBoxStyle.Information, "Oei u bent precies iets vergeten")
'Title U have forgotten somthing'
End If
now this what i tried
'then i got the error :Object reference not set to an instance of an object.'
Form2.DataGridView1.CurrentRow.Cells(0).Value = TextBox1.Text
'Then i get the error: Value of type 'String' cannot be converted to System.Windows.Forms.DataGridViewTextBoxColumn.' Form2.VoornaamDataGridViewTextBoxColumn = TextBox1.Text
But now i dont now what else i can do any sugestions ????
Thx
Arno(Cornetto456)
This post has been edited by cornetto456: 03 January 2011 - 08:14 AM

New Topic/Question
Reply



MultiQuote




|