Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Visual Basic > VB.NET 1.0 > Pro VB.NET 2002/2003
|
Pro VB.NET 2002/2003 For advanced Visual Basic coders working .NET version 2002/2003. Beginning-level questions will be redirected to other forums, including Beginning VB.NET.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Pro VB.NET 2002/2003 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 May 13th, 2004, 10:49 AM
Registered User
 
Join Date: May 2004
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Run exe from VB .NET windows program

I would like to run an external program (.exe) from inside a vb.net program designed for the compact framework. If possible, I'd also like to pass the name of the file the program is to open. I've seen suggestions about using API functions, but I can't figure out how to do it. Any suggestions or code examples?

 
Old May 14th, 2004, 09:40 AM
Authorized User
 
Join Date: Mar 2004
Posts: 61
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I've done this in two different ways. The first is using the shell command to call the exe. The other is to create a process for your other application. You should be able to pass the file name of the application to both without a problem. Let me know if you have any more questions.

Brian
 
Old June 16th, 2004, 09:44 AM
Registered User
 
Join Date: Aug 2003
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to weichunglow
Default

Hi guys,

'Call teh java compiler to compile a program
        System.Diagnostics.Process.Start("javac", "something.java")
'call the calculator
        System.Diagnostics.Process.Start("calc")

This is just an example running program with arguement.
the first parameter is teh program name, the second one is the arguement for the program

 
Old August 20th, 2005, 02:10 AM
Registered User
 
Join Date: Feb 2005
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi

IconSult

Try This

System.Diagnostics.Process.Start("C:\YourExe.exe")

Manish

Thanks and Regards
Manish Kaushik
 
Old October 16th, 2006, 01:05 PM
Registered User
 
Join Date: Oct 2006
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to subamahadev
Default

i have a question based on caling a exe from the vb.net program

we can call using System.Diagnostics.Process.Start() but how can we get the output from the process to the vb.net program say for example

System.Diagnostics.Process.Start("javac.exe","file name.java")
but if errors r there in the code how do i display it in my program...

i am developing a java editor using vb.net so i need to get the errors if any to teh program where it need to be displayed...

 
Old September 18th, 2011, 08:15 AM
Registered User
 
Join Date: Sep 2011
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Talking manoj

HI sweety thanks i got it





Similar Threads
Thread Thread Starter Forum Replies Last Post
How to run another .exe from my program shivendra C++ Programming 1 July 28th, 2006 04:56 AM
What Windows can VB .NET App run on ocarroll General .NET 6 February 27th, 2006 08:14 AM
Running an external program (.exe) in VB.net webgen VS.NET 2002/2003 1 July 18th, 2005 12:57 PM
Call VB Exe from VB Program jmss66 VB How-To 5 December 12th, 2004 11:17 AM
Files needed to run a VB.Net Windows Apps daniel VB.NET 2002/2003 Basics 2 October 15th, 2004 09:29 AM





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