shell command

S

Slickuser

When I run this code on my local box. An output file is created.
When I run it on the server as an admin account, the file doesn't
create as all.

Any idea?

using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
System.Diagnostics.Process.Start("CMD.exe", "/c qwinsta > C:/
abc/test.txt");
}
}
 
N

not_a_commie

I'm pretty sure the UseShellExecute in .NET does more than what you're
doing there. I'd try that route.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top