# PC SDK As Service?

**URL:** <https://tech-community.robotics.abb.com/t/pc-sdk-as-service/10636>\
**Category:** RobotStudio\
**Tags:** service, dienst, pcsdk\
**Created:** [March 14, 2022, 2:48pm UTC](https://tech-community.robotics.abb.com/t/pc-sdk-as-service/10636 "2022-03-14T14:48:00Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Spawn14](https://avatars.discourse-cdn.com/v4/letter/s/cc9497/32.png) [@Spawn14](https://tech-community.robotics.abb.com/u/Spawn14)\
**Post date:** [March 14, 2022, 2:48pm UTC](https://tech-community.robotics.abb.com/t/pc-sdk-as-service/10636/1 "2022-03-14T14:48:00Z")

</div>

I’m having trouble running a program developed with the PC SDK as a service.

When calling or setting the controller, the DLL \> **ABB.Robotics.Controllers.PC.dll** \< throws an error.

> _The type initializer for “ABB.Robotics.Controllers.Controller” threw an exception._\<

This my Code:  
“**mController = Controller.Connect(mAnlage.GUI, ConnectionType.Standalone)**”

Where “mController = ABB.Robotics.Controllers.Controller”

I read the GUI beforehand with a WindowsForm app and also assigned the controller with it. It doesn’t seem to work in a service. The same result when I try to assign a controller via the ControllerInfoCollection. The Netscanner also throws errors in a service when initializing. Is there any workaround?
