Tech Support Forum banner
Status
Not open for further replies.
1 - 1 of 1 Posts

·
Registered
Joined
·
1 Posts
Discussion Starter · #1 ·
Hi,

I've created a web service to execute a simple DOS command.

here is my web service code

Dim strbatFilePath As String
strbatFilePath = "e:\gems\Dev\Supplier\cmdr.bat"
Dim fs2 As FileStream
fs2 = New FileStream(strbatFilePath, FileMode.Append)
Dim sw2 As New StreamWriter(fs2)
sw2.WriteLine("copy e:\gems\Dev\Supplier\dir.log e:\gems\Dev\Supplier\reuters")
sw2.Close()
Dim objProcess As Process
objProcess = New Process
objProcess.StartInfo.FileName = strbatFilePath
objProcess.StartInfo.CreateNoWindow = True
objProcess.StartInfo.UseShellExecute = False
objProcess.StartInfo.RedirectStandardOutput = True
objProcess.Start()
objProcess.WaitForExit()
objProcess.Close()

when ever I invoke this web service from my client windows application.

it is creating batch file, i'm suspeting the problem might be in executing the DOS command.

the "Supplier" folder has fullcontrol permissions to "IIS_WPG" Account.

but every time throughing a error called

"server was unable to process required -->Access denied."

Is this problem with the permissions?. if so what do i need to do to rectify this problem?.

thanks in advance.

Bhawani
 
1 - 1 of 1 Posts
Status
Not open for further replies.
Top