473,396 Members | 1,840 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

How can I set the Windows Shortcut 'Start in' Parameter from Access?

I have developed an Access application and am attempting to add a
button to one form that will run our Work Order system. The Work
Order system is normally started from an icon on the desktop.

The Shortcut has the following values
Target: C:\oracle6i\BIN\ifrun60.EXE C:\MP5i\bin\r5logon.fmx
Start in: C:\MP5i\bin
Shortcut Key: None
Run: Normal Window

I am using the Call Shell function to execute the external
application. I copied the "Target" string from the shortcut and used
it as the Command line in the Shell command.

Here is my code:

Dim stAppName As String
stAppName = "C:\oracle6i\BIN\ifrun60.EXE " &
"C:\MP5i\bin\r5logon.fmx"
Call Shell("stAppName", 1) ' Open Work Order System

When I click the button the Work Order system attempts to start, but
it is attempting to load/attach other files (other than r5logon) that
are located in the directory specified in the 'Start in' section of
the shortcut. Therein lies the problem. Is there a way for me to
specify that 'Start in' directory from my application before or during
the execution of the Shell command. Or is there an entirely different
way that I should be doing this?

Isn't the Start In parameter similar to the old 'Path' statements used
in DOS?

Thanks for any help you can give.

Barry
Nov 12 '05 #1
1 12400
bc*****@cityofsacramento.org (Barry Cannon) wrote in message news:<50**************************@posting.google. com>...
I have developed an Access application and am attempting to add a
button to one form that will run our Work Order system. The Work
Order system is normally started from an icon on the desktop.

The Shortcut has the following values
Target: C:\oracle6i\BIN\ifrun60.EXE C:\MP5i\bin\r5logon.fmx
Start in: C:\MP5i\bin
Shortcut Key: None
Run: Normal Window

I am using the Call Shell function to execute the external
application. I copied the "Target" string from the shortcut and used
it as the Command line in the Shell command.

Here is my code:

Dim stAppName As String
stAppName = "C:\oracle6i\BIN\ifrun60.EXE " &
"C:\MP5i\bin\r5logon.fmx"
Call Shell("stAppName", 1) ' Open Work Order System

When I click the button the Work Order system attempts to start, but
it is attempting to load/attach other files (other than r5logon) that
are located in the directory specified in the 'Start in' section of
the shortcut. Therein lies the problem. Is there a way for me to
specify that 'Start in' directory from my application before or during
the execution of the Shell command. Or is there an entirely different
way that I should be doing this?

Isn't the Start In parameter similar to the old 'Path' statements used
in DOS?

Thanks for any help you can give.

Barry


Barry,

look in the documentation if ifrun60.exe has some commandline option
to choose the default startup-directory or environment-variables you
could set.

Otherwise try making a batchfile containing the lines
c:
cd C:\MP5i\bin
start C:\oracle6i\BIN\ifrun60.EXE C:\MP5i\bin\r5logon.fmx

and call it through:
call shell("mybat.bat",0)

I think that will work ...

Marc.
Nov 12 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

17
by: Paul Rubin | last post by:
Dumb question from a Windows ignoramus: I find myself needing to write a Python app (call it myapp.py) that uses tkinter, which as it happens has to be used under (ugh) Windows. That's Windows...
3
by: Michael | last post by:
Hi, I have a windows service developed using c# and it needs to lunch another windows application. I have been trying to use Process class to do it but the problem is becase windows service...
3
by: Stanislaw Findeisen | last post by:
Does anyone know how to create file shortcuts in Windows? The only way I know is like: --------------------------------------------------------------- import win32com.client ...
1
by: Iyer, Prasad C | last post by:
Hi, I am trying to create a small utility program which would be configured in registry. Something like this Windows Registry Editor Version 5.00 @="\"python...
2
by: Ganesh | last post by:
I have to change the tartget property of a windows start->Program->X's shortcut properties using c program. Do we have any function for that ? please reply me ASAP.. as it is urgent !
9
by: hhh12347 | last post by:
FolderBrowserDialog crashes on my Windows 2000 computer. Here is a C# test program: using System; using System.Windows.Forms; public class TestForm : Form { FolderBrowserDialog...
2
by: graeme34 via AccessMonster.com | last post by:
Hi I was wondering if there was any way of making the windows for the currently opened objects in access invisible on the bottom toolbar. Iam using Access 2003 also is it possible to turn of the...
1
by: Sue | last post by:
Is there a way to set up an alert in Microsoft Access so that when the computer is turned on or user logs on, an alert message is displayed if data in a table meets a certain condition, example...
3
FishVal
by: FishVal | last post by:
Windows Script Host Object library. Full name: Windows Script Host Object Model LibName: IWshRuntimeScripting Location: ...\WINDOWS\system32\wshom.ocx The present tip is closely related to...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.