By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,466 Members | 1,537 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,466 IT Pros & Developers. It's quick & easy.

variable question

P: n/a
How do I get a number in a field from one form to another?
Form1 has a record with a Long Integer field (call it TagNum). I need
to get the number from TagNum saved into memory somehow, as a variable I
am guessing. The record is copied to another table with an append
query, and then the record is then deleted from the first table. A new
form is opened and I want to be able to open the record that was just
copied into Form2. I am trying to get the TagNum to be used as a filter
in the 2nd form so it only shows that one record in the form.

I hope I havn't confused everyone, but I would appreciate any and all
help with this.
Thanks,
Ray
Nov 13 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Basically what I am asking is how to make a variable based on a control
static instead of dynamic, and not lose the value in the variable when
the control is reset or cleared.
Thanks.

Ray Holtz wrote:
How do I get a number in a field from one form to another?
Form1 has a record with a Long Integer field (call it TagNum). I need
to get the number from TagNum saved into memory somehow, as a variable I
am guessing. The record is copied to another table with an append
query, and then the record is then deleted from the first table. A new
form is opened and I want to be able to open the record that was just
copied into Form2. I am trying to get the TagNum to be used as a filter
in the 2nd form so it only shows that one record in the form.

I hope I havn't confused everyone, but I would appreciate any and all
help with this.
Thanks,
Ray

Nov 13 '05 #2

P: n/a

"Ray Holtz" <ra*@rayholtz.com> wrote in message
news:d4**********@schooner.siu.edu...
How do I get a number in a field from one form to another?
Form1 has a record with a Long Integer field (call it TagNum). I need to
get the number from TagNum saved into memory somehow, as a variable I am
guessing. The record is copied to another table with an append query, and
then the record is then deleted from the first table. A new form is
opened and I want to be able to open the record that was just copied into
Form2. I am trying to get the TagNum to be used as a filter in the 2nd
form so it only shows that one record in the form.

I hope I havn't confused everyone, but I would appreciate any and all help
with this.
Thanks,
Ray

Create a procedure in Form1 that:
1. Writes TagNum to an Long-type variable (MyVariable)
2. Runs the append query
3. Runs the delete query
4. Opens Form2 using the OpenForm Method and the optional WhereCondition
(TagNum = MyVariable)
5. Closes Form1


Nov 13 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.