|
-
Jul 27th, 1999, 12:19 PM
#1
Thread Starter
New Member
I AM A VB5 BEGINNER AND I TRIED EXTRACTING FROM TRANSACTIONS TABLE USING DIFFERENT VARIABLE NAME ON TWO DIFFERENT FORMS USING DATA CONTROL AND GRIDS TO DISPLAY THE TRANSACTIONS OF EACH EMPLOYEE (FORM 1 FOR VIEWING TRANSACTIONS USING MSFlexGrid AND FORM2 FOR POSTING AND MODIFYING TRANSACTIONS USING DBGrid) BUT GOT THE FOLLOWING MESSAGE:
Compile error:
Member already exist in a object module from which this object module is derives.
MY CODING IS AS SIMPLE AS THIS;
FORM 1
Dim dataTbrowse As Recordset
Dim dataTview As Recordset
Dim tmaster As Database
Private Sub fraTransact_DragDrop(Source As Control, X As Single, Y As Single)
End Sub
Private Sub cmdTranclose_Click()
Unload Me
End Sub
Private Sub dbcTrannum_Click(Area As Integer)
Set dataTranbrowse.Recordset = tmaster.OpenRecordset("select * from transactions where employeeid = '" & dbcTrannum.BoundText & "'")
End Sub
Private Sub dbcTrannum_DblClick(Area As Integer)
Set dataTranbrowse.Recordset = tmaster.OpenRecordset("select * from transactions where employeeid = '" & dbcTrannum.BoundText & "'")
dataTranbrowse.Recordset.Bookmark = dbcTrannum.SelectedItem
lblTranname = dataTranbrowse.Recordset!LASTNAME
End Sub
Private Sub Form_Load()
Set tmaster = OpenDatabase("c:\adah\testmaster.mdb")
End Sub
THE ABOVE FORM 1 RAN SUCCESSFULY BUT FORM 2 GAVE THE ERROR
FORM 2
Dim datJustposting As Recordset
Dim MMASTER As Database
Private Sub cmdPostransact_Click()
Unload Me
End Sub
Private Sub dbcPostransact_Click(Area As Integer)
Set datJustposting = MMASTER.OpenRecordset("select * from transactions where employeeid = '" & dbcPostransact.BoundText & "'")
End Sub
Private Sub dbcPostransact_DblClick(Area As Integer)
Set datJustposting.Recordset = Recordset = MMASTER.OpenRecordset("select * from transactions where employeeid = '" & dbcPostransact.BoundText & "'")
End Sub
Private Sub Form_Load()
Set MMASTER = OpenDatabase("c:\adah\testmaster.mdb")
End Sub
THE ERROR COMES WHEN TRYING TO RUN FORM 2.
PLEASE, CAN SOMEONE HELP ME. I HAVE A TARGET I INTEND TO MEET, THANK YOU.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|