|
-
May 14th, 2004, 03:16 AM
#1
Thread Starter
Junior Member
Tool Bar question ? (Solved )
Hi,
I have tool bar with 4 buttons on it, the buttons are TOP, PRIOR, NEXT & BOTTOM to move the record set of the active form and to display the details.
how can i write the common function for these buttons to work with the active form. The functions are like this..
for Example.
Top - When i click, the record set will be moved to first and it
will be display the details in the active form.
How can i do this...
Last edited by muraliambt; May 14th, 2004 at 04:59 AM.
bye,
Mursand
-
May 14th, 2004, 03:35 AM
#2
Fanatic Member
use the index property of button clicked
Code:
Private Sub GetRecord(index as integer)
Select Case ind
Case 1
'bla bla bla (move forward)
Case 2
'gla gla gla (move backward)
Case 3
'ela ela ela (do whatever you want
End Select
End Sub
-
May 14th, 2004, 03:47 AM
#3
Thread Starter
Junior Member
Hi,
I want to put this as common function for all the FORMS in my application. every forms have different record set name. how can i find out which is the active form... etc...
-
May 14th, 2004, 03:51 AM
#4
Fanatic Member
Is your application a MDI and forms are all child forms or all forms are different forms?
if it is MDI then you can directly use ActiveForm.recset.
where recset is declared public RecordSet in that form
if it is not MDI use Screen.ActiveForm.recset etc..
Give more details otherwise
-
May 14th, 2004, 04:11 AM
#5
Thread Starter
Junior Member
yah, i am having MDI form and reset is the child forms.
1. without making the RS as public, can we do operations ( any other method ).
2. Can i have RS as public & common for all the Forms, because only one form will be displyed at a time.
3. if i have the RS as public and common for all the form, will it have any impact.
Thanks.
-
May 14th, 2004, 04:17 AM
#6
Fanatic Member
You can have one RS defined public in a module. However
1. Only one query could be executed at a time..
2. 2nd query could be executed only if firstly opned RS is closed and opened for second query.
3. Only one form has to show the results at a time
HTH
-
May 14th, 2004, 04:29 AM
#7
Thread Starter
Junior Member
Thanks, any other way of doing this.
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
|