I have a program that opens what I call external files. These are files in a folder that pertain to individual invoices or orders. They are named like: 1234.pdf, 1234.tif, 5678.xls, 5678.xls, 5678.txt. Up till now I have just display a list of the files for one invoice or order on the screen and let the user pick which file they would like to view. I then use the following code (short version) to open the file in the windows default program.
This works well. Now the client wants to prevent the sales people from possible opening other salesman files. I currently only let the salesman see there invoices/orders. So the problem is not in the list of files presented to the user, but rather in the "file open" open options in the windows programs such as notepad, etc. that would let then navigate to other files. To help solve this on the server we have removed access to these folders for all salesman. I have tried to start a process as a different user that has permission to these folders, but some of the programs need permission to copy the file before it is displayed, and that permision seems to go back to the original user (salesman). Can somebody provide some guidance? maybe you have done something like this. I tried some other code for impersonation, but that didn't work either.
Auguy
Sylvania/Toledo Ohio
Code:
Dim psInfo As New System.Diagnostics.ProcessStartInfo(FullFileName)
psInfo.WindowStyle = ProcessWindowStyle.Normal
myProcess1 = System.Diagnostics.Process.Start(psInfo)
Auguy
Sylvania/Toledo Ohio