Attach a shortcut to a particular record in Access database in Out

S

Sandy

I have a database where a sales rep fills out a request and, using the
database, generates an Outlook email requesting approval to his/her boss. I
would like to include a shortcut in that email that the approver can click on
that will open the database and go directly to that record.

I can set up a hyperlink in the email that will open the database, but I'm
not sure how to look for a particular record based on that hyperlink.

Any ideas would be appreciated.
Thanks
 
D

Dale Fye

I think you can embed command line arguments in they hyperlink address of
your email. The key is getting the formatting of the hyperlink and
parameters properly.

Then, in your startup or splash form, check the value of the command$. If
nothing has been passed, then go on as normal, values were passed, then take
the appropriate actions.

I would google on Access +vba +"command line argument" and see what you can
find.
--
HTH
Dale

email address is invalid
Please reply to newsgroup only.
 
S

Sandy

Thank you very much. I just wasn't sure how to know what was being sent
after the /cmd in the command line. I did your search and found the code and
now I think I can get it to work.

My users will be very please.
 
D

david

You can create in code a windows shortcut to a query (like you
get by dragging a query and dropping it on the desktop) : they are
actually short files that look like this:

[Shortcut Properties]
AccessShortcutVersion=1
DatabaseName=db3.mdb
ObjectName=Query1
ObjectType=Query
Computer=DAVID
DatabasePath=C:\db3.mdb
EnableRemote=1
NetworkPath=\\DAVID\C\db3.mdb
CreationTime= 1c9330e37d1ec88
Icon=280

The only magic is that the file name extension is .MAQ

To get that to open at a particular record you need to first create a
query that only returns one record, but you can create text files
like that and include them in mail messages or drop them on your
network and include a url pointing at them.

(david)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top