Command line parameter
Posted by: fredometro on
Jan 6th, 2004 |
Filed under: MS-Access
Quertion: Hi
I am trying to pass a simple command line parameter to my Access Application. In my Shortcut I have written this:
“M:\\MyApp.MDB” /Cmd “Success!”
and in the actual application the first line of code displays what’s in the command line. ie:
msgbox Command(),vbInformation
———————————
All I am getting are blank lines.
Any Suggestions,
Many thanks
Ted
Hi!
There is a very simple explanation:
Your command is:
“M:\\MyApp.MDB” /Cmd “Success!”
So you call MyApp.mdb, which is associated with Access, so, as expected, access launches the MDB as expected, but in the file association process, it looses all the rest, thus your blank line.
The easiest is to enter the command like this:
“c:\\program files\\microsoft office\\office\\msaccess.exe” /cmd Success!
Or whereever you have msaccess.exe installed.
There is another solution, which implies messing the registry. Just post a follow up and I can start trying: I LOVE messing the registry.
Regards.
Fredix gave this follow-up answer on 1/25/2002:
Hi! Me again!
I couldn’t resist to try the registry trick.
1) Click start/run, type regedit, click ok
2) If you are not familiar with the registry or abused with the bourbon, just concentrate and make no mistake. There is no Undo command.
3) Open the HKEY_CLASSES_ROOT key and browse down until you find the .mdb key. Open it.
4) Depending on your version of Access, you have: Access.Application.9 for Access 2000 or Access.Application.8 for Access 97.
5) The previous step was only for your culture. There is nothing to do here, just check its here.
6) In Edit menu, click find. Enter Access.Application.8 (97) or Access.Application.9 (2000). Click Find Next
7) Open this found key and look for a key named ‘Command’. Its under Access.Application.8\shell\open\
On the right part of the screen, click on the red icon. The value looks like this
I:\\Program Files\\Microsoft Office 97\\Office\\MSACCESS.EXE /NOSTARTUP “%1″
9) Note that my theory is correct: There is only one parameter taken here. You should add two more: One for the /cmd, and one for the “success!”
10) Change the value so that it is:
I:\\Program Files\\Microsoft Office 97\\Office\\MSACCESS.EXE /NOSTARTUP “%1″ %2 %3
Note there is no ” with the %2 and the %3
11) Close your editing box and try your command: “M:\\MyApp.MDB” /Cmd “Success!”
12) Guess what is displayed in your message box?
You can do the same with Access.Application.9 if you have Access 2000.
I hope this makes sense to you.
Regards.


May 6th, 2009 at 11:35 am
now I’ll stay tuned..
May 18th, 2009 at 2:22 pm
mm. luv it
June 13th, 2009 at 2:46 am
The article is ver good. Write please more
June 19th, 2009 at 5:08 am
Thank you for article. It is very good read.
I love to read http://www.fredometro.com!
dallas teeth whitening
July 4th, 2009 at 1:53 am
I should email you about it.
July 6th, 2009 at 9:14 pm
Some of us even don’t realize the importance of this information. What a pity.
August 18th, 2009 at 5:56 pm
How to Choose a Faxing Product
How to Decide Whether to Buy a Franchise
How to Communicate in a Business Crisis
How to Insure a Home-Based Business
1. Determine what additional insurance coverage you will need to insure your home-based business.
2. Check out insurance programs available through self-employment organisations or the local Chamber of Commerce.
3. Contact the insurance company that provides your home owner’s or rental policy insurance to determine the riders and additions you need to insure your home-office property.
4. Investigate business interruption insurance, which reimburses you if you are suddenly unable to conduct your business.
5. Conduct a daily backup of computer data and transfer information to a safe place.
All it and is much another you can find out on a site
http://napkins.v3host.be
September 7th, 2009 at 6:23 am
well.. it’s like I knew!
September 8th, 2009 at 8:44 pm
now I’ll be tuned..
September 19th, 2009 at 7:23 am
Excellent site, keep up the good work
September 19th, 2009 at 5:18 pm
Cool site, love the info. I do a lot of research online on a daily basis and for the most part, people lack substance but, I just wanted to make a quick comment to say I’m glad I found your blog. Thanks,
A definite great read..
-Bill-Bartmann
September 22nd, 2009 at 5:03 am
I don’t know If I said it already but …Cool site, love the info. I do a lot of research online on a daily basis and for the most part, people lack substance but, I just wanted to make a quick comment to say I’m glad I found your blog. Thanks,
A definite great read..
-Bill-Bartmann
September 29th, 2009 at 5:31 pm
Great site, how do I subscribe?
November 11th, 2009 at 10:31 am
Hello,
visits my coooool website - crimenetwork.biz.
killu.crimenetwork.biz
http://crimenetwork.biz
very coooool!
yo yo, my name is killu, and i have no skills. my server i let manage by 2×4, but i tell everybody that i am pro.
my server is maximum ddos protected!!!!
you do not must abuse my hoster & domainregistrar, both are bulletprooooooooof man.
visit my site or go DIE, motherfucke
k!llu - gangsternetwork - your master - bigest botnet
November 11th, 2009 at 1:26 pm
Salut,
mon nom est : Anna, J’ai 24 ans bientot
Je vais bientot presenter mes activites sur un petit blog de france television
http://blog.france2.fr/musculation-appartement/ sur la musculation a pratiquer chez soi
peut etre pourrons nous echanger sur le sujet ?
A+
November 11th, 2009 at 11:43 pm
yoo.. nice
November 13th, 2009 at 1:27 pm
added to my rss reader
November 15th, 2009 at 12:57 pm
eh.. bookmarked thoughts
November 18th, 2009 at 3:22 pm
yeah. bookmarked style
November 24th, 2009 at 1:16 pm
Hello,
I’m Anna, I’m thirty two old, I work in a french rest house. it’s great to come with you and I’d like to talk in english
cheers,
Ann :: [url=http://jobfairincalifornia.com/annajoicles/2009/11/23/maison-de-retraite/]maison de retraite[/url]
November 25th, 2009 at 6:17 pm
Hi,
I’m Ann, I’m 38 old, I work in a french rest house. it’s great to share with you and I’d want to improve my english
cheers,
Ann :: [url=http://annajoicles.pinoycube.com/2009/11/23/maison-de-retraite/]maison de retraite[/url]
December 1st, 2009 at 4:19 am
Hello,
I’m Anna, I’m thirty three old, I work in a medicalised french rest house. it’s great to come with you and I’d like to wite in english
regards,
Ann :: [url=http://blogfriends.com/maisonderetraite/2009/11/30/maison-de-retraite-mdicalise/]maison de retraite[/url]
December 12th, 2009 at 6:14 am
Ass Parade
December 12th, 2009 at 6:15 am
Slave In Pain
December 12th, 2009 at 6:16 am
Girls on Cams
December 12th, 2009 at 6:18 am
Budapest Hardcore
December 12th, 2009 at 6:19 am
Cute Pussies Bonanza
December 12th, 2009 at 6:20 am
Gemma Massey Nude
December 12th, 2009 at 6:21 am
Lisaas Space
December 12th, 2009 at 6:22 am
Butt Bang Boys
December 12th, 2009 at 6:23 am
Celeste Fox
December 12th, 2009 at 6:24 am
Gay No Limit
December 12th, 2009 at 6:25 am
Unknown Twinks
December 12th, 2009 at 6:26 am
Trixy Potter
December 12th, 2009 at 6:27 am
Dirty Kinky Mature
December 12th, 2009 at 6:28 am
Foxy Jacky
December 12th, 2009 at 6:29 am
Lesbian Video Pass
December 12th, 2009 at 6:30 am
Brittany Avalon
December 12th, 2009 at 10:08 pm
any updates coming ?
December 15th, 2009 at 3:08 pm
Yo,
I’m Ann, I’m 32 old,
I work in a medicalised french rest house. it’s nice to share
with you and I’d would like to talk in english
regards,
Anna :: [url=http://www.retraiteplus.fr]maison de retraite[/url]
December 18th, 2009 at 1:00 am
Hi,
I now got a quick internet access, it’s great to share with you
regards,
Nathan from [url=http://israel.storeblogs.com/]israel[/url]
December 21st, 2009 at 1:03 pm
yoo… cognitively post
December 22nd, 2009 at 4:40 am
Hello,
I am Spike, soon 35 years ,
I teach plastic art at college
see you,
Seb from [url=http://www.spikeseduction.com]seduction[/url]
December 22nd, 2009 at 8:08 am
Yo,
I am Sebastien, soon 43 ,
I teach plastic art at college
bye,
Seb from [url=http://www.spikeseduction.com]seduction[/url]
December 22nd, 2009 at 11:35 am
Hello,
I am Seb, soon 38 ,
I teach plastic art at college
see you,
Spike from [url=http://www.spikeseduction.com]seduction[/url]
December 26th, 2009 at 6:43 am
yo.. funny text!
January 3rd, 2010 at 8:14 pm
Please can anyone tell me how to start trading Forex, and if it’s possible to stsrt with a little amount. Would also like to know about trading from my home (I live in Africa). Will be glad to receive any answer.
[url=http://forexrobot-review.info]best forex software[/url]
January 3rd, 2010 at 9:06 pm
I am looking at purchasing a robot but want to know how to sort the rubbish out from the good. I am currently looking at forex megadroid, Poison robot, Pips Leader. Any suggestions, has anyone tried these robots with success.
[url=http://forexrobot-review.info]best forex software[/url]
January 5th, 2010 at 4:12 am
Hi,
I am Mark, soon 41 , I teach sports in high school
bye bye,
Mark, my little blog [url=http://www.2rouesfrance.com]moto[/url]
January 5th, 2010 at 7:38 am
Hello,
I am Mark, soon 43 years , I teach sports in high school
bye bye,
Mark, my little blog [url=http://www.2rouesfrance.com]moto[/url]
January 5th, 2010 at 11:16 am
Hi,
I am Mark, soon 39 years old, I teach sports in high school
bye,
Mark, my little blog [url=http://www.2rouesfrance.com]moto[/url]
January 6th, 2010 at 1:17 pm
Hi,
I am Mark, soon 36 old, I teach sports in high school
regards,
Mark, my little blog [url=http://www.2rouesfrance.com]moto[/url]
January 27th, 2010 at 6:19 am
Great site, I will be back. Well done
April 16th, 2010 at 8:32 pm
pokemon hentai…
I’m agree with you but imho you should think about that problem… Free porn hairy gallery[ ?????]…
May 14th, 2010 at 4:47 pm
naruto shippuden hentai…
orges famale masterbation famale bare feet thumb pics fam?? llysex fam?? l??…
June 5th, 2010 at 5:16 pm
NARUTO HENTAI VIDEOS…
St Charles, Asian porn , Asian porn, trnb, Easter clipart , Easter clipart, 032, Stars , Stars, 358, Science fair projects , Science fair projects, xnvysc, The hun , The hun, %(((, Verzi za abraham , Verzi za abraham, O, Where can i see eurythmics vide…
Add A Comment
You must be logged in to post a comment.