Value transfer between forms

  • Thread starter Thread starter Vsn
  • Start date Start date
V

Vsn

Hello all,

If I have a Form open which hase record 100 selected (fID=100), could I open
another Form which hase a combo box on it with the combo box focuses on
record 100 (fID=100), and still have the hole record set loaded. I have been
trying to use the docmd.OPENFORM with the filter, but this restricts the
data of the form which opens to the filter.

The form I want to open is normaly used to lookup data with the use of the
combo box (switch beteen all records) now I want to launch this form with
the focus on a specific record and still have the hole record set loaded.

I have tried the Where Condition but I do not managed to get this working.
[http://msdn.microsoft.com/library/d...-us/vbaac11/html/acactOpenForm_HV01122149.asp].

Thx,
Ludovic
 
Hi,


Forms!SomeForm.Form.Recordset.FindFirst "key=3"



will move the record displayed in form SomeForm to the first record
satisfying the criteria. You can run the statement from anywhere, from VBA
code in a module, or another form, even from the Immediate Debug Window, as
long as the mentioned form is open, that is. It does NOT filter the data in
the mentioned form.


Hoping it may help,
Vanderghast, Access MVP
 
Michel,

Thx, for your response, it was not exactly what I was looking for, but it
surly gave me the idea (method) to get to my requirment.

Ludovic

Michel Walsh said:
Hi,


Forms!SomeForm.Form.Recordset.FindFirst "key=3"



will move the record displayed in form SomeForm to the first record
satisfying the criteria. You can run the statement from anywhere, from VBA
code in a module, or another form, even from the Immediate Debug Window,
as long as the mentioned form is open, that is. It does NOT filter the
data in the mentioned form.


Hoping it may help,
Vanderghast, Access MVP




Vsn said:
Hello all,

If I have a Form open which hase record 100 selected (fID=100), could I
open another Form which hase a combo box on it with the combo box focuses
on record 100 (fID=100), and still have the hole record set loaded. I
have been trying to use the docmd.OPENFORM with the filter, but this
restricts the data of the form which opens to the filter.

The form I want to open is normaly used to lookup data with the use of
the combo box (switch beteen all records) now I want to launch this form
with the focus on a specific record and still have the hole record set
loaded.

I have tried the Where Condition but I do not managed to get this
working.
[http://msdn.microsoft.com/library/d...-us/vbaac11/html/acactOpenForm_HV01122149.asp].

Thx,
Ludovic
 
Back
Top