I'm having another one of *those* days today. I have a form which can have
many data sources which are chosen from an option group. This all works
fine except that the subform doesn't refresh even though I'm calling the
main form's open event from the option group's update event. Any clues?
Thanks.
Keith. 7 1246
Hi Keith,
Are you trying to (re)set the sourceobject for the sub ??
Something like
Me!SubForm.SourceObject = "YourSourceObject" should work
Arno R
"Keith Wilby" <he**@there.com> schreef in bericht news:43**********@glkas0286.greenlnk.net... I'm having another one of *those* days today. I have a form which can have many data sources which are chosen from an option group. This all works fine except that the subform doesn't refresh even though I'm calling the main form's open event from the option group's update event. Any clues? Thanks. Keith.
"Arno R" <ar***********@tiscali.nl> wrote in message
news:43**********************@text.nova.planet.nl. ..
Hi Keith,
Are you trying to (re)set the sourceobject for the sub ??
Something like
Me!SubForm.SourceObject = "YourSourceObject" should work
Arno R
Hi Arno, thanks for the response. In my subform's open event I have VBA SQL
code which defines its record source. It's this that isn't refreshing when
the main form's open even fires. I'm using global variables as containers
for project names, the contents of which change depending on which option is
selected from the option group on the main form. The contents of the GVs
are then used in the SQL code.
It's a bit difficult for me to explain but I hope you get the gist.
Regards,
Keith.
"Keith Wilby" <he**@there.com> schreef in bericht news:43**********@glkas0286.greenlnk.net... "Arno R" <ar***********@tiscali.nl> wrote in message news:43**********************@text.nova.planet.nl. .. Hi Keith, Are you trying to (re)set the sourceobject for the sub ?? Something like Me!SubForm.SourceObject = "YourSourceObject" should work Arno R Hi Arno, thanks for the response. In my subform's open event I have VBA SQL code which defines its record source. It's this that isn't refreshing when the main form's open even fires. I'm using global variables as containers for project names, the contents of which change depending on which option is selected from the option group on the main form. The contents of the GVs are then used in the SQL code. It's a bit difficult for me to explain but I hope you get the gist. Regards, Keith.
I guess your sub's open event will *not* fire when you call the mainform's open event.
I guess you need to call the sub's open event explicitly in this case.
(Or just close and reopen the main form?)
HTH
Arno R
"Arno R" <ar***********@tiscali.nl> wrote in message
news:43**********************@text.nova.planet.nl. ..
"Keith Wilby" <he**@there.com> schreef in bericht
news:43**********@glkas0286.greenlnk.net... "Arno R" <ar***********@tiscali.nl> wrote in message news:43**********************@text.nova.planet.nl. .. Hi Keith, Are you trying to (re)set the sourceobject for the sub ??
Something like Me!SubForm.SourceObject = "YourSourceObject" should work
Arno R
Hi Arno, thanks for the response. In my subform's open event I have VBA SQL code which defines its record source. It's this that isn't refreshing when the main form's open even fires. I'm using global variables as containers for project names, the contents of which change depending on which option is selected from the option group on the main form. The contents of the GVs are then used in the SQL code.
It's a bit difficult for me to explain but I hope you get the gist.
Regards, Keith.
I guess your sub's open event will *not* fire when you call the mainform's open event. I guess you need to call the sub's open event explicitly in this case. (Or just close and reopen the main form?)
HTH Arno R
Thanks Arno, I had been trying to fire the sub's open event from the main
form but can't get the syntax right. Thanks for your patience, I feel like
a total clueless newbie on this.
Keith.
"Keith Wilby" <he**@there.com> schreef in bericht news:43**********@glkas0286.greenlnk.net... "Arno R" <ar***********@tiscali.nl> wrote in message news:43**********************@text.nova.planet.nl. .. "Keith Wilby" <he**@there.com> schreef in bericht news:43**********@glkas0286.greenlnk.net... "Arno R" <ar***********@tiscali.nl> wrote in message news:43**********************@text.nova.planet.nl. .. Hi Keith, Are you trying to (re)set the sourceobject for the sub ??
Something like Me!SubForm.SourceObject = "YourSourceObject" should work
Arno R
Hi Arno, thanks for the response. In my subform's open event I have VBA SQL code which defines its record source. It's this that isn't refreshing when the main form's open even fires. I'm using global variables as containers for project names, the contents of which change depending on which option is selected from the option group on the main form. The contents of the GVs are then used in the SQL code.
It's a bit difficult for me to explain but I hope you get the gist.
Regards, Keith. I guess your sub's open event will *not* fire when you call the mainform's open event. I guess you need to call the sub's open event explicitly in this case. (Or just close and reopen the main form?) HTH Arno R Thanks Arno, I had been trying to fire the sub's open event from the main form but can't get the syntax right. Thanks for your patience, I feel like a total clueless newbie on this.
You are welcome Keith,
Try: Call Form_NameOfSubForm.Form_Open (False)
Arno R
"Arno R" <ar***********@tiscali.nl> wrote in message
news:43**********************@text.nova.planet.nl. ..
"Keith Wilby" <he**@there.com> schreef in bericht
news:43**********@glkas0286.greenlnk.net... "Arno R" <ar***********@tiscali.nl> wrote in message news:43**********************@text.nova.planet.nl. .. "Keith Wilby" <he**@there.com> schreef in bericht news:43**********@glkas0286.greenlnk.net... "Arno R" <ar***********@tiscali.nl> wrote in message news:43**********************@text.nova.planet.nl. .. Hi Keith, Are you trying to (re)set the sourceobject for the sub ??
Something like Me!SubForm.SourceObject = "YourSourceObject" should work
Arno R
Hi Arno, thanks for the response. In my subform's open event I have VBA SQL code which defines its record source. It's this that isn't refreshing when the main form's open even fires. I'm using global variables as containers for project names, the contents of which change depending on which option is selected from the option group on the main form. The contents of the GVs are then used in the SQL code.
It's a bit difficult for me to explain but I hope you get the gist.
Regards, Keith.
I guess your sub's open event will *not* fire when you call the mainform's open event. I guess you need to call the sub's open event explicitly in this case. (Or just close and reopen the main form?)
HTH Arno R
Thanks Arno, I had been trying to fire the sub's open event from the main form but can't get the syntax right. Thanks for your patience, I feel like a total clueless newbie on this.
You are welcome Keith,
Try: Call Form_NameOfSubForm.Form_Open (False)
Arno R
Tried that Arno but it won't compile. This is a "nice to have" that I've
spent way too much time on so I'm going to leave it now. Thanks anyway.
Regards,
Keith.
"Arno R" <ar***********@tiscali.nl> wrote in message
news:43**********************@text.nova.planet.nl. .. (Or just close and reopen the main form?)
Hi Arno, I got it to work using this method in the end, thanks for the tip.
Regards,
Keith. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Rey |
last post by:
Howdy all.
Appreciate your help with several problems I'm having:
I'm trying to determine if the Visit subform (subformVisits) has a new
record or been changed, i.e. dirty. The form that...
|
by: Charlene |
last post by:
I have an Invoice/Invoice Details form/subform. In the page footer of the
Invoice Details subform I have a textbox with the control source set to
=Sum(). I then pull this value into the main form...
|
by: Lyn |
last post by:
Hi,
I am working on a genealogy form. The only table (so far) lists everybody
in the family, one record per person. Each record has an autonum ID.
The parent form (frmMainForm) displays the...
|
by: MLH |
last post by:
I have created two forms: frmBrowseNegsMainform and
frmBrowseNegsSubform. I put a subform control on the
first of these. The SourceObject property for the subform
control is, of course,...
|
by: Sally |
last post by:
I need to be able to click in a subform and run code but at the same time I
need to be able to scroll the records without running the code. I tried
coding the Enter event of the subform control but...
|
by: PC Datasheet |
last post by:
I'm stuck on something that seems should be easy and I need some help. My
main form has an option group with five options. My subform chooses from
different lists depending on which option is...
|
by: Ecohouse |
last post by:
I have a main form with two subforms. The first subform has the child
link to the main form identity key.
subform1 - Master Field: SK
Child Field: TrainingMasterSK
The second subform has a...
|
by: DMUM via AccessMonster.com |
last post by:
Hello
I am trying to pass the name of my subform to a function/sub but I can't
seem to get it to work. I am using an autokey function (ctrl E) to unlock
text boxes on a subform. I have a few...
|
by: ApexData |
last post by:
I am using the following code in my TabControl to manage subform
loads. The code assigns the subForms SourceObject.
- Do I also need code to DeAssign the SourceObject when leaving the
Tab, I'm...
|
by: samdev |
last post by:
I have created two combo boxes in a subform....
For example
1. Combo Box State
2. Combo Box City
3. When a state from the Combo Box State is selected, the City combo
box updates to reflect...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
| |