C# Application Problem on Windows 2003 Server

N

noisefree

Hello,

I have a problem on an application I am developing:

This C# Windows Application calls a C# Web Service, which it uses the
SourceSafeTypeLib DLL to interact with Visual Source Safe 6.

The problem comes out when I call the VSS method "Get(ref string Local,
int flags)", which should get a VSS file and save it to disk.
I pass "E:\max\tmp\vss\AssemblyInfo.cs" as the Local path string, but
the program exit with the error:
"System.Runtime.InteropServices.COMException (0x8004D84B): Access to
file "d:\windows\system32\inetsrv\AssemblyInfo.cs" denied".
As you can see this is NOT the path I gave to the program (why win2K3
is changing it?)

It used to work just fine on Windows XP, that's why I'm pretty sure
it's not an application problem.
Unfortunately a few days ago I had my laptop re-installed w/Win2003,
and since then it won't work anymore
So after some research I've found out that it should depends on the way
Win2003 handles access security..

If it can help: the VSS DB is on another machine which I map as share
and access it with the proper authenticated domain user (I repeat: on
WinXP it worked just fine...)

Any guess would be appreciated.

thank you
 
R

Robson Siqueira

noisefree,

Try to change the flags you use. I have something here like this working:

itm.Get(ref tempFile, (int)VSSFlags.VSSFLAG_REPREPLACE +
(int)VSSFlags.VSSFLAG_FORCEDIRNO);

where itm it is a VSSItem object.
 
N

noisefree

Robson,

thank you very much for your helpful advice!
I finally have my program working now.

I used these flags: (int)(VSSFlags.VSSFLAG_FORCEDIRYES |
VSSFlags.VSSFLAG_RECURSYES) which I know now they are the problem...

Thanks a lot, you're great!
M@x
 

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