Impersonate with windows service for Service A/C
Impersonate with windows service not work for Service Account..
Business Requirement:-WindowsService1 should fectch files on the client laptop as well as any Mapped drives related with Servers.
To access server,client/business provides service account mydomain\globalServiceAccount and globalserviceAccountPassword
Since this WindowsService1 should fetch Laptop files and any mapped server(service account).
While imporsonating the service it is not fectching any files on the Server
e.g. Z mapped drives is \\abcServer\sharedFolder <--to access this folder Service account is required.
Event after performing imporsonate , my service windowservice1 is not at all fectching any files,where as there
are files available on \\abcServer\SharedFolder.
Let me know if you have any inputs or pointer that will windowService1 to fetch files from the myLaptop where this Service is installed.
1>I logged into my Laptop with my usercredentials(mydomain\myuserId,mypassword)
2>WindowsService1 is runnning on MyLaptop.
3>I Mapped any other server with z drives 'abcServer\sharedFolder.(with service account-mydomain\globalServiceAccount and globalserviceAccountPassword)
4>my WindowsService1 should fetch files with imporsonation from 'abcServer\sharedfolder"
5>my WindowsService1 should also fetch files stored in mydesktop and C: drives files.
any inputs/code snippet/pointer would be a great help
Since i am new to Windows Service,let me know if your inputs help me to resolve this.