Solved

Calling a Console application from Asp.net

Posted on 2015-01-05
4
93 Views
Last Modified: 2015-01-20
I have a need to call a console application from my asp.net web app and sends few parameter to the console application.
I need to know is it even possible, if yes any example would be helpfull.
0
Comment
Question by:yadavdep
[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
  • 2
4 Comments
 
LVL 33

Expert Comment

by:it_saige
ID: 40531985
Is this console application running on the server or the clients?

-saige-
0
 
LVL 75

Expert Comment

by:käµfm³d 👽
ID: 40531993
Also, is this a .NET console application or not?
0
 

Author Comment

by:yadavdep
ID: 40532042
Console application will be on the same server where the site is hosted.
It is donet console application only.
0
 
LVL 75

Accepted Solution

by:
käµfm³d   👽 earned 500 total points
ID: 40532235
You have two options:

1) You can invoke the process from the command line using the System.Diagnostics.Process class (example at bottom ofa page)

2) You can add a reference to the console application's assembly the same way you add a reference to a DLL. Then it's just a matter of invoking the correct method (and instantiating the correct class, if necessary).
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone 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

Suggested Solutions

Title # Comments Views Activity
vb.net convert long time to mm:ss 23 22
make control visible based off other control value 7 22
c#, case, if 4 22
c# ftp code 3 35
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
Performance in games development is paramount: every microsecond counts to be able to do everything in less than 33ms (aiming at 16ms). C# foreach statement is one of the worst performance killers, and here I explain why.
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

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