Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

There is a VB.Command() and App used in VB6.0. I want to use the same in VB.Net but without the MS.VB reference.

Posted on 2009-04-21
6
Medium Priority
?
213 Views
Last Modified: 2013-12-17
There is a VB.Command() and App used in VB6.0. I want to use the same in C#.Net but without the MS.VB reference.
Can anyone please help.
Thanks
0
Comment
Question by:MPakeezah
  • 3
  • 3
6 Comments
 
LVL 53

Expert Comment

by:Dhaest
ID: 24191921
Can you show a part of the code that you mean?
What exactly do you mean ? Is it something that you call from code ?

Are you calling another application through the command (that is replaced by process)
Dim proc as System.Diagnostics.Process = new System.Diagnostics.Process()
proc.EnableRaisingEvents=false
proc.StartInfo.FileName="calc"
proc.Start()

Open in new window

0
 

Author Comment

by:MPakeezah
ID: 24191942
XLJob.Start(App, Command) in VB6.0
This is the code. the XLJob dll has been shared but not the code. I need to convert it to C# without the VB referencing.
0
 
LVL 53

Expert Comment

by:Dhaest
ID: 24191967
Take a look at the process-class
http://msdn.microsoft.com/en-us/library/system.diagnostics.process.aspx


System.Diagnostics.Process proc = new System.Diagnostics.Process();
proc.EnableRaisingEvents=false;
proc.StartInfo.FileName="calc";
proc.Start();

Open in new window

0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 

Author Comment

by:MPakeezah
ID: 24192029
The start job is taking App as parameter, what do i pass instead in C#.Net?
0
 
LVL 53

Expert Comment

by:Dhaest
ID: 24193701
And what is app ?

If you take a look at the process-class, the startinfo.filename will contain the exe that you want to execute
0
 

Accepted Solution

by:
MPakeezah earned 0 total points
ID: 24249989
.Start(System.AppDomain.CurrentDomain, Environment.CommandLine) is being used instead
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

This article is for Object-Oriented Programming (OOP) beginners. An Interface contains declarations of events, indexers, methods and/or properties. Any class which implements the Interface should provide the concrete implementation for each Inter…
A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
When cloud platforms entered the scene, users and companies jumped on board to take advantage of the many benefits, like the ability to work and connect with company information from various locations. What many didn't foresee was the increased risk…
Whether it be Exchange Server Crash Issues, Dirty Shutdown Errors or Failed to mount error, Stellar Phoenix Mailbox Exchange Recovery has always got your back. With the help of its easy to understand user interface and 3 simple steps recovery proced…
Suggested Courses

810 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