WFBweb
asked on
Open a OneNote 'file' while in Access?
I'm in design phase for a client who wants to use tablet pcs....with OneNote keeping client interview info. While in an Access form can I open OneNote to notes kept for a particular client if I'm able to develop the filename in Access? How?
You can use the shell command to open an application while in Access. See VBA Help (Ctl-G or Alt-F11) and enter Shell Function in the Answer Wizard for details.
Maybe an invisible textbox on the form containing the Access developed filename and path and a command button when clicked to activate the shell command?
ASKER
I copied the example from Shell help and modified:
Public Function testopenOneNote()
Dim RetVal
RetVal = Shell("C:\testfolder\Misce llaneous.o ne", 1)
End Function
Then I did a RunCode in a macro and got this error:
Runtime error '5' Invalid procedure call or argument
I also called it from a command button in a form and got the same result.
Public Function testopenOneNote()
Dim RetVal
RetVal = Shell("C:\testfolder\Misce
End Function
Then I did a RunCode in a macro and got this error:
Runtime error '5' Invalid procedure call or argument
I also called it from a command button in a form and got the same result.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Works great....wish I'd known about 'shell' a few years back...thanks.
Didn't I give you the answer?
ASKER
I goofed....I didn't even look up...thought they were all from you.