Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / Compact Framework / January 2006

Tip: Looking for answers? Try searching our database.

ArgumentNullException

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Scott Toney - 31 Jan 2006 15:56 GMT
I am calling showdialog to show a form using the following code:

Private sub miAdd_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles miAdd.Click
   Cursor.Current = Cursors.WaitCursor
   AddEditForm = New frmAddEdit
   AddEditForm.NewPatient = True
   AddEditForm.Searching = False
   AddEditForm.ShowDialog()
   MessageBox.Show("A")
   LoadList()
   Cursor.Current = Cursors.Default
End Sub

On my AddEditForm, in my Return Menu Item I have:

Private Sub miReturn_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles miReturn.Click
   If (NewEntry) And (Not Save1) Then
       InsertData(sender, e)
   End If
   Try
       MessageBox.Show("1")
       frmAddEdit_Save(sender, e)
   Catch ex As Exception
       MessageBox.Show(ex.ToString)
   End Try
   MessageBox.Show("C")
   Me.Close()
End Sub

I get the messagebox.show for 1 and C, but get an argumentnullexception
after the messagebox.show("C") and do not get the Messagebox.show("A").
Being new to this, I'm sure that it is a programming error but have run out
of places to look. Any ideas would be greatly appreciated.

TIA
Scott
Scott Toney - 31 Jan 2006 17:18 GMT
I was binding controls to a dataset that didn't have data.

>I am calling showdialog to show a form using the following code:
>
[quoted text clipped - 34 lines]
> TIA
> Scott

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.