?
Solved

edit button

Posted on 2006-04-26
1
Medium Priority
?
219 Views
Last Modified: 2010-04-23
hello,
im trying to fix my edit button this is what I have

      Private Sub cmdEdit_Click(ByVal eventSender As System.Object, ByVal eventArgs As System.EventArgs) Handles cmdEdit.Click
            On Error Resume Next
            Enabled = False
        Load(frmAccountDetails)
            frmAccountDetails.Populate((lstAccounts.SelectedIndex))
            frmAccountDetails.Show()
      End Sub

but I get an error in Load(frmAccountDetails)
how can I fix it ?
0
Comment
Question by:aplelois
1 Comment
 
LVL 43

Accepted Solution

by:
TimCottee earned 2000 total points
ID: 16542502
Hi aplelois,

VB.Net syntax is different to VB6:

     Private Sub cmdEdit_Click(ByVal eventSender As System.Object, ByVal eventArgs As System.EventArgs) Handles cmdEdit.Click
        Dim frmAD As frmAccountDetails
        frmAD = New frmAccountDetails
          frmAD.Populate((lstAccounts.SelectedIndex))
          frmAD.ShowDialog() ' This makes the new form modal so you don't need to disable the current form.
     End Sub

Tim Cottee
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

I think the Typed DataTable and Typed DataSet are very good options when working with data, but I don't like auto-generated code. First, I create an Abstract Class for my DataTables Common Code.  This class Inherits from DataTable. Also, it can …
1.0 - Introduction Converting Visual Basic 6.0 (VB6) to Visual Basic 2008+ (VB.NET). If ever there was a subject full of murkiness and bad decisions, it is this one!   The first problem seems to be that people considering this task of converting…
This video shows how to quickly and easily deploy an email signature for all users in Office 365 and prevent it from being added to replies and forwards. (the resulting signature is applied on the server level in Exchange Online) The email signat…
With just a little bit of  SQL and VBA, many doors open to cool things like synchronize a list box to display data relevant to other information on a form.  If you have never written code or looked at an SQL statement before, no problem! ...  give i…
Suggested Courses

850 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