Solved

Compiler Error

Posted on 1998-08-01
3
167 Views
Last Modified: 2010-05-03
Why does the compiler stop here.  The Data1 control is defined in the property box for itself so DBList can operate.  See the ">" for the location of compiler error.

Private Sub A()
    Dim Fake As Integer
End Sub

Private Sub DBList1_Click()
    DBList1.Recordset.Bookmark = DBList1.SelectedItem
End Sub
>>>>>>>Private Sub cmdFirst_Click()
    Data1.Recordset.MoveFirst
    Data1.BoundText = Data1.Recordset.Fields("Name").Value
End Sub
Private Sub cmdNext_Click()
    If Not Data1.Recordset.EOF Then
        Data1.Recordset.MoveNext
        If Data1.Recordset.EOF Then
            Data1.Recordset.MovePrevious
        End If
        Data1.BoundText = Data1.Recordset.Fields("Name").Value
    End If
End Sub
Private Sub cmdPrev_Click()
    If Not Data1.Recordset.BOF Then
        Data1.Recordset.MovePrevious
        If Data1.Recordset.BOF Then
            Data1.Recordset.MoveNext
        End If
        Data1.BoundText = Data1.Recordset.Fields("Name").Value
    End If
End Sub
Private Sub cmdLast_Click()
    Data1.Recordset.MoveLast
    Data1.BoundText = Data1.Recordset.Fields("Name").Value
End Sub



0
Comment
Question by:optical
3 Comments
 

Author Comment

by:optical
ID: 1467433
Thank you.
0
 
LVL 2

Expert Comment

by:percosolator
ID: 1467434
what error message are you getting?  the compiler should give you a reason why it stopped.
0
 
LVL 2

Accepted Solution

by:
swilt earned 50 total points
ID: 1467435
If the error is 'Procedure declaration does not match description of event or procedure having same name' then select the button cmdFirst at design time and change the 'index' is the properties to nothing i.e. deleted anything that is there, the index property denotes that the button is in a control array
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

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

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

810 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