RobotStudio event

ABB.Robotics.Controllers.Discovery.NetworkScanner TypeInitializationException was unhandled

Hi ,everyone ,I am new in using PC SDK, thank you very much for your busy schedule to visit my question. ABB.Robotics.Controllers.Discovery.NetworkScanner initialization error, my project is set to X86, ABB.Robotics.Controllers.PC.dll version 6.3.7016.2009, Runtime version is v4.0.30319. May I ask you, what is the problem, thank you.

Comments

  • I am using version 6.3.6890, so a bit lower compared with your version. The warning already indicates the problem. The ABB dll is build against version v4.5 and then you can not use runtime version v4.0. So probably if you change your runtime version to the same version (or higher) as the one used for the ABB dll, it will work...


  • Hi,John_Verheij.Thank you very much for your reply.I have installed the version 6.03 of ABB.Robotics.Controllers.PC.dll,but ABB dll in the VS2013 property browser is shown in v4.0.30319.The problem can not be solved, I will try to follow your ideas, once again thank you.
  • I am using version 6.3.6890, so a bit lower compared with your version. The warning already indicates the problem. The ABB dll is build against version v4.5 and then you can not use runtime version v4.0. So probably if you change your runtime version to the same version (or higher) as the one used for the ABB dll, it will work...


    Hi,John_Verheij.I tried a lot of versions of the ABB dll,from V5.61 to V6.03.The version of Robot Communication Runtime is the same as that of ABB dll. The result obtained is the NetworkScanner class initialization failure. the project is set to x86, I do not know what causes the initialization failure.





  • The ABB Industrial Robot Communication Runtime is in the RobotWare Tools and Utilities folder - you should try to install it manually.
  • What do you mean with NetworkScanner initialization error? It is something like this right?

    <div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; NetworkScanner scanner = new NetworkScanner();<br></div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; scanner.Scan();</div>
  • What do you mean with NetworkScanner initialization error? It is something like this right?

    <div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; NetworkScanner scanner = new NetworkScanner();<br></div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; scanner.Scan();</div>

  • What do you mean with NetworkScanner initialization error? It is something like this right?

    <div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; NetworkScanner scanner = new NetworkScanner();<br></div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; scanner.Scan();</div>
    Hi,John_Verheij.while executiing this statement "NetworkScanner scanner = new NetworkScanner();" will throws an TypeInitializationException.





  • The ABB Industrial Robot Communication Runtime is in the RobotWare Tools and Utilities folder - you should try to install it manually.
    Hi,graemepaulin. Thank you for your reply, I tried the method you mentioned, but no use, my ABB.Robotics.Controllers.PC.dll and Robot Communication Runtime version is the same, all from the same directory. Project platform is set to x86, I do not know where the problem, you can help me?



  • When I try to set up a project with the same settings it works without problems. Maybe you can share your project and then I can have a look
  • When I try to set up a project with the same settings it works without problems. Maybe you can share your project and then I can have a look
    I'm glad you can help me.My app is a simple PC SDK application as application manual of PC SDK mentioned.I put my application package upload for you ,dll file in debug directory. once again say thank you.
    abb1.rar 268.5K
  • John_Verheij
    John_Verheij ✭✭✭
    edited September 2016
    According to the exception you have to add two additional references:
    • RobotStudio.Services.RobApi
    • RobotStudio.Services.RobApi.Desktop

    After adding these two references it works, but I am not sure why these two references are needed

  • baijun
    baijun
    edited September 2016
    According to the exception you have to add two additional references:
    • RobotStudio.Services.RobApi
    • RobotStudio.Services.RobApi.Desktop

    After adding these two references it works, but I am not sure why these two references are needed

    Hi,John_Verheij.Thanks you very much, you solved my problem perfectly.I appreciate the quality of your helping others, you are my role model. Thanks again and Have a good day :D).