I have some code that runs when a user click the close button at the top of the form:
Private Sub Form_Close()
If IsLoaded("frmContactdetails") Then
DoCmd.Close acForm, "frmSelectfromINvoiceListing"
DoCmd.OpenForm "frmContactDetails"...
Dear All - I need help!
I am trying to make a show a folder in Outlook as an Address Book using the following code:
'Add folder
Set myFolder = myFolders.Item("All Public Folders").Folders.Item("Report Distribution")
myFolder.Folders.Add stOfolder, olFolderContacts
'Make...
I currently have a make table query doing this job and it works fine. But now I want to pass a variable (lastupdate stored in a table) to the query and can't see how to do it?
Can I replace the query with VBA? and that way pass it the variable?
Any and all help would be appreciated.
Thanks
Nicky
Fixed it. Don't know how. Started again (for the third time) and something I did must have worked. Checked against old version from backup and no difference at all. Corruption? Who knows.
Thanks for your help anyway.
poctok
Rick - thanks for the reply. It is the SourceObject that keeps changing. I can get it to show the subforms I want in the form in design view but when I press save it changes so that one subform is repeated twice?
Poctok
The problem is this. I have a main form with a company id (comID) and two subforms:
subContactsbyCompany and
subSubscriptionsbyCompany.
These subforms each have their own SourceObject i.e. two separate queries which link to the company ID in the main form.
Each form works individually. But...
I think I know why it doesn't work. I have an autonumber field in my table. Testing this on a simple form with no autonumbers it works.
Is there a way to exclude the autonumber control from the code? And get it to just update the text controls?
Thanks for the help so far.
Thanks again - what you said makes sense and I thought it should work but no... this time the error is:
Run-time error 2185
You can't reference a property or method for a control unless the control has the focus.
I thought the point of the code was to loop through each of the controls?
Thanks for your post, but still no joy. When I use the ammended code I get the following error:
Run-time error '2448'
You can't assign a value to this object
This was the error I was getting when I used the other example in help.
Completely lost!
Hi,
I'm trying to use the Undo example in Microsoft Help (see below) on a form to reset the values of txt controls but keep getting the following error:
Run-time error '424'
Object Required
Can anybody help me?
Poctok
***
Example from Help -
Private Sub cmdUndoEdits_Click()
Private Sub...
I am importing excel spreadsheets into access using a static filename - this all works fine. Now I want to be able to let the user choose the file to import.
I can do this with a text input box but would like to let the user see the file selection window - let then use the window to select a...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.