Command Buttons

  • Thread starter Thread starter Richard
  • Start date Start date
R

Richard

I created a command button on a form that links to a word
document. After I close the link a second version of the
database opens leaving me with two open databases. Why.
This only happens if I acess the link form the command
button. I open the word document and start the query it
doesn't happen
 
Don't know why it happens, but this fixes it

dim strAppTitle as string

strAppTitle = dbs.Properties("AppTitle")
CurrentDb.Properties("AppTitle") = "Microsoft Access"
RefreshTitleBar
Call word here

and after it closes...

CurrentDb.Properties("AppTitle") = strAppTitle
RefreshTitleBar

This will need error handling around it in case
property "AppTitle" does not exist
 
Back
Top