ElliottService System.TypeInitializationException

System.TypeInitializationException may occur in ElliottService if you log onto the server using the same user account configured to run Elliott Service.

Symptoms


You configured a user account to run the Elliott Service in IIS. You log onto the machine hosting Elliott Service using the same user account. While Elliott Service is running, you log off the server. After you log off, you start getting exceptions like the one shown below. You will continue to encounter exceptions in subsequent calls until you restart IIS.
System.TypeInitializationException: The type initializer for '[NAME]' threw an exception. ---> System.Runtime.InteropServices.COMException: Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG))

Cause

The user log off likely interferes with the normal operation of Elliott Service

Resolution

Configure a dedicated login to run Elliott Service. Do not use the same login to log on the machine hosting Elliott Service.

More Information

The following steps were used to reproduce this problem in a test environment running Windows 2008 R2 server and IIS 7.
  1. Set up Elliott Service in IIS. 
  2. Configure Elliott Service to run as a predefined user account. (e.g., DomainName\ElliottServiceUser)
  3. Log onto the machine using the same user account. (e.g., DomainName\ElliotServiceUser)
  4. Ensure Elliott Service is in a clean state by running the next two commands: iisreset -stop then  iisreset - start
  5. Ensure the transaction component is running. This can be done by making a call to any ElxxxxxxService methods. For example, make a call to ElicustmService ViewCustomer.
  6. Start sending traffic to the Elliott Service. If you have a test website or application that calls the web service, you can use it to send traffic. In our test environment, we have a test program that calls various web services.
  7. Log off the server
  8. ElliottService will start having System.TypeInitializationException.

VYC 
updated on 2018-04-04

Developer Documentations

  1. Received Code 9999 with Web Services Call
  2. Received Return Status Code 3 When Using Elilogin Login Method
  3. Elliott Web Service Requirements
  4. Elliott eStore Checklist
  5. LN API
  6. FN API
  7. RN API
  8. IN and DF API Change (V9.0)
  9. FA API Changes (V9.0)
  10. VA API Changes (V9.0)
  11. CartService
  12. EliarachService
  13. ElicshtxService
  14. EliattrbService
  15. ElisyscdService
  16. EliNoteService
  17. El2rstimService
  18. EliOrderService
  19. ItemInquiry
  20. EliitmiqService
  21. EliShiptoService
  22. El2getfrService
  23. Steps Required to Test ReportWriter in V8.2
  24. Installation of ElliottService, NETcellent’s Web Services for Elliott
  25. ResellerFinder
  26. EliaptrxService
  27. VendorInquiry
  28. EliloginService
  29. ElislsmnService
  30. EliserhsService
  31. EliatpobService
  32. ElievprcService
  33. ElihdtrxService
  34. ElicuswlService
  35. QueryTurnaround
  36. InvoiceInquiry
  37. ElicustmService
  38. EligetcdService
  39. OrderInquiry
  40. EliordiqService
  41. EliecontService
  42. EliautdpService
  43. El2CrCrdService
  44. Log-Timer / ElliottTimer.Ini Support
  45. Alpha Document Number Support (V8.5/V9.0)
  46. ElliottService System.TypeInitializationException
  47. Feature - Printing API to Dynamically Set Number of Copies
  48. The Values and Meanings of Distribution Types - ARDISFIL, APDISFIL, IMDISFIL, BMDISFIL
  49. DD API Changes (V9.0)
  50. PA API (V9.0)
  51. Validate License API
  52. AP API
  53. TP API: Temporary Path
  54. Data Structures for Report Desk Defaults and Enforcements
  55. COBOL to VB Interface Programs
  56. IN API: Option to Support Files and Folders Validation
  57. FF API: File Functions
  58. ID API
  59. LK: Links API
  60. FFLNearYou
  61. Report Desk Developing and Debugging
  62. Report Desk Groups
  63. Developing a New Elliott V8.5 Report Desk User Defined Report (UDR)
  64. Feature - Report Desk Report Footer Lines
  65. Report Desk Resolution of Pervasive.Data.SqlClient.dll

Feedback and Knowledge Base