I deployed my web app from my development machine (WinXP Pro) to the production server (Windows 2003). Everything works except for a COM library I am referencing from my business object.
The references in my solution are:
Web Project ---> Business Layer Project (DLL) ---> COM Library
I suspect part of my problem is I didn't properly deploy, I just grabbed everything under \wwwroot\MyWebApp and copied it to the server. I'm going to be researching proper deployment strategies, but in the meantime maybe someone could give me suggestions.
In my error log, the exception source is "Interop.AccpacCOMAPI", and the message is "Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG))" and the stack trace is as follows:
at AccpacCOMAPI.AccpacSessionClass.Init(String ObjectHandle, String AppID, String ProgramName, String AppVersion) at WSTimesheets.AccPacWrapper.GetAccPacEmployeeList(Guid AppUserID) in C:\Documents and Settings\Joe\My Documents\Visual Studio 2005\Projects\WellServe\BusLogic\WSTimesheets\AccPacWrapper.cs:line 239
Here is a snippet of the code:
1 // Open a session to AccPac
2 bool sessionOpened = false;
3 bool linkOpened = false;
4 AccpacCOMAPI.AccpacSession accpacSession = null;
5 AccpacCOMAPI.AccpacDBLink dbLinkRead = null;
6 AccpacCOMAPI.AccpacView viewEmployees = null;
7
8 string apAppID = AppID;
9 string apProgramName = AppName;
10 string apVersion = AppVer;
11 string apUserID = UserID;
12 string apPassword = UserPassword;
13 string apDatabaseID = DatabaseID;
14
15 accpacSession = new AccpacCOMAPI.AccpacSession();
16
17 try
18 {
19 accpacSession.Init("", apAppID, apProgramName, apVersion);
20 accpacSession.Open(apUserID, apPassword, apDatabaseID, DateTime.Today, 0, "");
21 sessionOpened = true;
22 }
23 catch (Exception e)
24 {
25 ErrorLogger errLog = new ErrorLogger();
26 errLog.LogException(e, AppUserID, "AccPacWrapper.GetAccPacEmployeeList() - failed to open AccPac session");
27 }
Line 19 is where the stack trace indicates the error is occurring.