Solved

Setting Parameters

Posted on 2000-04-19
1
128 Views
Last Modified: 2011-09-20
Hello all, This should be an easy one!

I want to set parameter for an EXE. The DOS command line would look like this:

a:\Testexe -Sdx a:\dump.txt c:\1.txt c:\2.txt

How do i get the parameters 'c:\1.txt' & 'c:\2.txt' to come from 2 text boxes on the form. I want the user to be able to type in a path in txtbox1 and txtbox2 and that path be placed in the parameters for Testexe.

Heres the code i currently have:

wd = Shell("a:\testexe -Sdx a:\d.txt c:\1\1.txt c:\2\1.txt", vbNormalFocus)

Can you help?
0
Comment
Question by:hirschhouse
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 14

Accepted Solution

by:
wsh2 earned 35 total points
ID: 2732343
dim strCommand as String

strCommand = "a:\testexe -Sdx a:\d.txt " _
   & text1.text & "1.txt " _
   & text2.text & "2.txt "
wd = Shell(strCommand, vbNormalFocus)
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question