Firstly, Northwinds Categories form is bound to the table Categories so you
are working apple to oranges if you truly have an unbound form. If you want
to view/add/edit data via a form it is easier to have that form bound to the
table, or query of a table, in which the data resides.
How did you code your current form? Import the Northwinds form into your db
and apply the same working code to the objects in the new form.
>Hi - I have a unbound form / subform - works fine - but do not like the
>appearance of it.
[quoted text clipped - 4 lines]
>
>Al
al9315 - 26 Jun 2006 19:05 GMT
I very much appreciate the help - thank you.
I would have tried that, but, my second (sub - although not !) form - I have
set as 'continuous forms' and the data to be put in the text boxes on form2
is read from a query - approx 6 tables
I wish to 'Select ....From ... where ' the room name in the query = the room
name on the main form and enter the data e.g. the details of 1 - 20...
machines on the continuous form - giving me much more control over layout,
fontsize etc.
I can get the data from the query - I am stuck with how to " if the query
room name = the room name on the main form then put the following details in
the form2 text boxes - txtMake = the make - when I try that from the
disconnected recordset does not work e.g. frm2.txtMake = rsMachines!Make if
txtMake.Text - then error - must have the focus ?!
I hope this makes sense - I am pushing the boat out a bit !!!? - but
stubborn - where theres a will nd all that !!!
I must say a HUGE thank you to all the people who help on here - you are
amazing - I would NEVER have got so far without you all
Al
jahoobob - 26 Jun 2006 21:41 GMT
Since you say sub-although not! I'm thinking that you have two separate forms
open at once and you want to pass data from one to the other.
To pass data from one form to another you need to use the "full path" name.
If your main form is frmMain and the second form is frmForm2 then to place
data in a text box (txtMain) that is on frmMain into a text box (txtForm2) on
frmForm2 you would place Me!txtForm2=Forms!frmMain.txtMain in the On Open
event of frmForm2. frmMain has to be open when you open frmForm2 though.
>I very much appreciate the help - thank you.
>I would have tried that, but, my second (sub - although not !) form - I have
[quoted text clipped - 14 lines]
>amazing - I would NEVER have got so far without you all
>Al
al9315 - 30 Jun 2006 19:15 GMT
Again - thanks very much for your trouble. I have nearly got it working !!
Do Until rsMachines.EOF
'execute the Select command against database
cmdCommand.Execute
If CurrentRoomSelected = rsMachines!RoomName Then
frmMachineDetails!txtRoomName = rsMachines!RoomName
frmMachineDetails!txtMake = rsMachines!Make
frmMachineDetails!txtSerialNumber =
rsMachines!SerialNumber
End If
rsMachines.MoveNext
Loop
This works and puts the text in the text boxes I wish in the 2nd Form (i.e.
frmMachineDetails) - but !
I have set Form2 as 'continuous forms' - how can I get Loop ....... to
put the first set of data in the text boxes and put the 2nd set of data in
the text boxes as in 'Northwind Categories' ? Mine obviously just replaces 1
with 2 with 3 etc until .EOF
I hope this is clear - any help very welcome as always
Thanks
Al
eos - 27 Jun 2006 14:52 GMT
AUTO-REPLY From George Levitt
Please allow this to confirm a system receipt of your e-mail.
I am out of the office until Wednesday morning (1/12/05) and will not be
reviewing or responding to email or voicemail until that time.
I look forward to replying to your message on Wednesday.
Thanks and warmest regards, George
eos - 27 Jun 2006 14:52 GMT
AUTO-REPLY From George Levitt
Please allow this to confirm a system receipt of your e-mail.
I am out of the office until Wednesday morning (1/12/05) and will not be
reviewing or responding to email or voicemail until that time.
I look forward to replying to your message on Wednesday.
Thanks and warmest regards, George
AUTO-REPLY From George Levitt
Please allow this to confirm a system receipt of your e-mail.
I am out of the office until Wednesday morning (1/12/05) and will not be
reviewing or responding to email or voicemail until that time.
I look forward to replying to your message on Wednesday.
Thanks and warmest regards, George