Features of GoToRecord

Raynx

Registered User.
Local time
Today, 06:39
Joined
Sep 30, 2008
Messages
15
Question from a friend:
"When using a macro, when using GoToRecord, there are different options, such as First, Last, Previous, but what does the GoTo do?"

Screenshot:
Untitled.jpg
 
GoToRecord... Goes To The Record specified!

GoToRecord Last navigates to the Last record in the current recordset
GoToRecord First navigates to the First record in the current recordset

and so forth.
 
Hey, Ryan's partner, for this project, again.

We understand that point, but what about he option that is simply, Go To?
I understand Last,First,Next,Previous, ect. But what about "Go To" in the GoTo box?

And once again, I think the screen shot didn't go through... :(
 
I'll try to explain the problem a little more, hopefully it will guide any answers.

I have it set so that when you click a check box, it opens another form.
In this form, it asks you to enter a name, which I would like stored in the table that the check box is from.
What I did, was create a form from the wizard, so the appropriate field comes up, but the wrong record number.
No matter what record's check box I press, he first record comes up in the new form.
I would like it to goto the selected record.
 
Why not have the name text control set to invisible on the same form as the checkbox?

Then, when you click the checkbox, the name text control becomes visible? Then you don't have to worry about pop-ups and trying to get the name where it needs to go.

-dK
 
The problem would be that it is in a sub form, that shows as a table.
It is for a package tracking database, and we need to show the packages for a selected PO Box all at the same time.
When a package is picked up, they click the check box, and a form pops up.
They then must enter the box number, that is then checked against the selected Box number to prevent user error.
And they want to keep track of who picks up each package. and we would prefer that the users did not physically change it in the table, in fear of ID10Ts and what not.
But other wise, I do like that idea
 
Okay .. how about an input box?

On the subform, use the following on the After Update event of the checkbox.

Code:
    If Me.chkCheckBoxName = True Then
         Me.Parent!txtControlName = InputBox("Input something here.", "Input Something")
    Else
        Me.Parent!txtControlName = ""
    End If

Change chkCheckBoxName to the name of the checkbox and txtControlName to whatever the control name is that you want the text to appear on the main form.
I am just offering an alternative instead of creating a whole new form or what not.

-dK

EDIT: If you want to keep your pop up form, then that is fine - just use the reference Forms!frmMainFormName!txtControlName = txtControlNameThatIsOnPopUp
 
Last edited:
We understand that point, but what about he option that is simply, Go To?
I understand Last,First,Next,Previous, ect. But what about "Go To" in the GoTo box?
Taken from Access help...

Access Help said:
When the Record argument is Go To, Access moves to the record with the number equal to the Offset argument. The record number is shown in the record number box at the bottom of the window.

I'll try to explain the problem a little more, hopefully it will guide any answers.

I have it set so that when you click a check box, it opens another form.
In this form, it asks you to enter a name, which I would like stored in the table that the check box is from.
What I did, was create a form from the wizard, so the appropriate field comes up, but the wrong record number.
No matter what record's check box I press, he first record comes up in the new form.
I would like it to goto the selected record.
So you are trying to open the same record but on a different form? If I understood that correctly?
 
Code:
If Me.chkCheckBoxName = True Then
Me.Parent!txtControlName = InputBox("Input something here.", "Input Something")
Else
Me.Parent!txtControlName = ""
End If
I'd rather not use VB if possible. I would rather use the features of Access, I just don't fully understand all the features yet.

So you are trying to open the same record but on a different form? If I understood that correctly?

Exactly. And your post from the Access help was perfect, for some reason, I could not find that, probably just an ID10T Error on my part.

So could I use a variable name as the offset argument?
 
I don't know what you are after, I am confused since you have posted to two different responses mixing whatever.

The input box method I posted does not require you to open the same record. It's already open and I was proposing a method that uses a an input box to place the data in a box that is already bound on a subform.

Not sure what you are talking about needing a variable or an offset argument for now because that would cause the need for VB. I am not sure how you would get around this without VB without doing some extraordinary thing when 5 lines of VB do it.

-dK
 
Sorry about any confusion on replies.

The top part with the code is reference to the VB response
The Bottom is in reference to the poster of the quote
 
Oh, okay. If you are exploring GoToRecord, how is that not VBA? Just confused over that point.

Sorry couldn't help you - perhaps Singh will respond back with some 'au natural' method that will resolve your issue.

-dK
 

Users who are viewing this thread

Back
Top Bottom