on 2022 Feb 08 11:20 AM
Hi
On below line i am getting error . I am using Windows form Application. In Application Arguments i have given - 0030002C0030002C00530041005000420044005F00440061007400650076002C0050004C006F006D0056004900490056
In
oCompany = new SAPbobsCOM.Company();
System.Runtime.InteropServices.COMException
HResult=0x80040154
Message=Retrieving the COM class factory for component with CLSID {632F4591-AA62-4219-8FB6-22BCF5F60090} failed due to the following error: 80040154 Class not registered (0x80040154 (REGDB_E_CLASSNOTREG)).
Source=System.Private.CoreLib
StackTrace:
at System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean wrapExceptions, Boolean& canBeCached, RuntimeMethodHandleInternal& ctor, Boolean& hasNoDefaultCtor)
at System.RuntimeType.CreateInstanceDefaultCtorSlow(Boolean publicOnly, Boolean wrapExceptions, Boolean fillCache)
at System.RuntimeType.CreateInstanceDefaultCtor(Boolean publicOnly, Boolean skipCheckThis, Boolean fillCache, Boolean wrapExceptions)
at System.Activator.CreateInstance(Type type, Boolean nonPublic, Boolean wrapExceptions)
at System.Activator.CreateInstance(Type type)
at SapAddOn.StartUp.IsSapConnected() in D:\Projects\SapAddOn\StartUp.cs:line 39
at SapAddOn.StartUp.Main() in D:\Projects\SapAddOn\StartUp.cs:line 19
int oErrorValue = -1;
string oErrorMessage = string.Empty;
SAPbouiCOM.SboGuiApi oSboGuiApi = new SAPbouiCOM.SboGuiApi();
string[] strCon = Environment.GetCommandLineArgs();
//SboGuiApi = new SAPbouiCOM.SboGuiApi();
oSboGuiApi.Connect(strCon[1]);
oApplication = oSboGuiApi.GetApplication();
oCompany = new SAPbobsCOM.Company();
string oCookies = (string)oCompany.GetContextCookie();
string oconStr = oApplication.Company.GetConnectionContext(oCookies);
if (oCompany.Connected == true)
oCompany.Disconnect();
oCompany.SetSboLoginContext(oconStr);
User | Count |
---|---|
98 | |
8 | |
6 | |
6 | |
5 | |
5 | |
4 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.