Requery

Righteoo.. sorry. Will get a mockup done and do just that, thanks

And just so you know, I haven’t given up either, but it’s time for bed over here. So, I’ll see you in the morning, if no one else has figured it out by then. Good night.
 
Took me a while to make the mock up work. Hopefully it'll show you the problem. Thanks
 

Attachments

Its odd that you chose to use a subform control where none was needed. Usually a subform is for detail or child records.
 
I didn't know if it was a subform or not. Its odd too that it didn't use the font specified in the controls. Or did it for you? Should be Ms Sans Serif.
 
Your main form is called FormRun and the subform control is also called FormRun. Change it to anything other than the main form name as using that will confuse Access … as well as yourself :rolleyes:

If you like it can be the same name as the subform itself which is FormRunSub in which case you can use Me.FormRunSub.Form.Requery on the main form button

BTW you could have just used Me.Requery on the button and it should requery the subform as well
 
I'd dragged FormRunSub onto FormRun without realisjng it would change it's name. It couldn't find the name anywhere in Properties. StillI can't get Me.Requery to work and Me.FormRunSub.Form.Requery brings up an error.
Is the "subform control" the Form I dragged in?

If a Date is added to the ThisDate Column, requery should re-order the whole thing by ThisDate? I found a r-click and "Sort Oldest To Newest" does wjhat's required but I still hope to find why the button doesn't work.
 
I've modified this slightly just to check what you were saying.
Subform control now called FormRunSub. I clicked on the outside edge then renamed it in the property sheet.

Command button requery definitely works.
I've reordered the dates to sort newest to oldest just so I could see the requery more clearly.

Hope that helps
 

Attachments

Took me a while to make the mock up work. Hopefully it'll show you the problem. Thanks
Good morning, kirkm. Looks like Colin picked it up while I was sleeping. Please let us know if this took care of it for you. Cheers!
 
Hi DbGuy & Colin, yes it is working just fine. Blimey... I spent all day on this yesterday. I did not see the Property Sheet ever show selection type 'SubForm/SubReport' before, so never seen a name. It's there now. Clicking on the square where the rulers meet sometimes brings it up, but sometimes there's a black square and the Property Sheet changes to show "Form". That's where I spent hours looking there for a Name of some kind (to find what I was looking at). There's some trick to where/what you click for each, it certainly doesn't toggle in a logical way and the response from a second click varys at times.
The "Me.FormSubMain.Form.Requery" was exactly what majP said to do in Msg #2.
Colin, how did you change "FormRun" to "FormSubRun" in that control? It won't let me edit it and "FormSubRun" isn't an option in the dropdown list.
Is there a reason why it would take on that name, instead of its own one?

DBGuy, I'll go back to that other thread about fonts, but this is what I was talking about. Do you see the MS Sans Serif font in design view? Why doesn't it use this font in Form View? For a brief moment I thought the newly found Property sheet would be the answer and have a font option, but no...

Anyway, thank you all very much and I'm sorry it took so long to kind of get a solution. Now I can do some work with it at last :) (If I can delete my Form and Import Colins).
 
The control name is actually FormRunSub...same as the form.
I renamed it in the main form property sheet As it is a control of the main form.

The only way it could have been named FormRun is if you did it yourself.
Otherwise it would have kept the subform name or possibly something like Child1.
 
Many thanks Colin. All sorted and the requery button is working.
You don't know whereabouts to set the name of the font that will be used by the subform?
 
Go to Design view (or Layout View)
Select a control or better still select them all using the mouse.
You can then change the font name, size etc from any of the following:
- Home tab or Format tab on the ribbon
- Format tab on the controls' property sheet
 
I have done both and although the controls show the right font (in design mode) when in Form view they're different. Its a change there I've been unable to figure out.
 
Your database is an MDB file so options are more limited
If you change it to ACCDB, the ribbon settings for text formatting will be enabled in Datasheet view so you can change it to what you want.
If you are using A2010 or later you can also use Themes as I described in a link provided earlier in this thread
 
Last edited:

Users who are viewing this thread

Back
Top Bottom