How do I access a smartcard that is locally attached to a Windows Server 2008R2 in a self written Windows service that is running on that server?
NB: I can access the same smartcard when I start the service as normal Windows 10 application from the command line.
You did not provide enough information about the problem you are experiencing but changing service identity to LocalService and not using RDP usually helps.