Wrox Programmer Forums
|
Beginning VB 6 For coders who are new to Visual Basic, working in VB version 6 (not .NET).
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Beginning VB 6 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old September 19th, 2006, 10:40 AM
Registered User
 
Join Date: Sep 2006
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default Exes from VB Call

What is the best (most efficient and security-wise) way of calling an exe from a VB that will accept command-line arguments?
Also, what is the simpliest way of calling an exe that you may not know where it resides (i.e. call the exe without having to specify a full path for it just the name of the exe)? Thanks in advance for any help.

RP

 
Old September 19th, 2006, 11:34 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 2,189
Thanks: 5
Thanked 59 Times in 57 Posts
Send a message via MSN to gbianchi
Default

hi there..

shell is a nice way to execute an exe... also you could try it with some api (i dont remember any now...)
if you don't know where the exe is you will have to have it in the path variable so windows will find it.


HTH

Gonzalo
 
Old September 19th, 2006, 12:23 PM
Registered User
 
Join Date: Sep 2006
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thats what I've been doing so far so it's nice to know someone agrees. Here's a quick one I'm unsure of though. Is there a way to compile my exe and put it into a Setup.exe but somewhere have the installation set the environment variable for the path to include this path? Somehow set the path variable automatically would eliminate having the customer do it. Thanks for the response.

RP

 
Old September 19th, 2006, 12:25 PM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 2,189
Thanks: 5
Thanked 59 Times in 57 Posts
Send a message via MSN to gbianchi
Default

sure.. that's depends how you deploy your program... a lot of installer have an option to add a path variable to the path...

HTH

Gonzalo
 
Old September 19th, 2006, 12:46 PM
Registered User
 
Join Date: Sep 2006
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Right now what I do is I go into the Application Wizard and create the Setup.exe and, if need be, zip it up and send to customers. When you refer to "installers" I assume you are talking about something outside of the Setup.exe that gets created. If so, where can I go about getting an installer or something to add more smarts to my installations? Thanks again.

RP

 
Old September 19th, 2006, 12:55 PM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 2,189
Thanks: 5
Thanked 59 Times in 57 Posts
Send a message via MSN to gbianchi
Default

well.. you can add the thing you want to the setup created with the setup wizard. There is a project call setup1 that can be open and you can change things inside to add the thing you want.. that's the exe used when you created the P&D.

If I were you i will try to google a solution, for sure someone try to do this before...

HTH

Gonzalo





Similar Threads
Thread Thread Starter Forum Replies Last Post
Call VB exe in another vb program Swati Chari BOOK: ASP.NET Website Programming Problem-Design-Solution 1 March 14th, 2008 11:43 AM
Protection to VB EXEs ?! rutumanu Pro VB 6 7 October 4th, 2006 08:49 AM
Call VB Exe from VB Program jmss66 VB How-To 5 December 12th, 2004 11:17 AM
how do i call autocad through VB 6 belzicool VB How-To 3 December 2nd, 2004 10:46 PM
How to call a program in as400 through vb 6 gokul VB Databases Basics 0 October 20th, 2004 03:41 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.