Skip to main content

Solved !!! - Integrate lotus notes to third parties APP using interop.domino.dll COM API using C#

First of all before writing anything about this integration, i would like to say, i tried...tried..tried...so many times using the COM but couldn't succeeded and there were lot of things which needed to be understood just to make it work, Also the question i had was there is no documentation on IBM for C# COM API, but a good documentation on JAVA and C , so i was also not sure if this DLL would work? or we need some other way like ODBC or xPages or Webservice etc?

But i think "In IT, you should read your intuitions, that is where answer lies, because they are shouting from your experience.", Because i noticed that DLL has all the required classes and properties etc. and it has same methods as shown in JAVA docs on IBM, so i was sos sure this is the DLL that would 200% work

(i went into this thought process because i tried for 3 days without any luck, and later i found domino also has a web service which can be generated from domino designer etc., if i would have gone on that path, i might needed to understand it differently, but i had full trust on my intuition that this DLL has everything and if i make it work and get rid of the error, we are good to go)

just because it was a new system to me and i had no clue what is wrong, but i will try to put everything in here, So anyone out you can also get some information :), I will list down the issues that i faced, what one needs to do to solve, and also let me give you the URL of the code project which sample i used to have that interop.domino.dll, it is here, it is very good sample.


The error while initializing NotesSession class
Retrieving the COM class factory for component with CLSID {29131539-2EED-1069-BF5D-00DD011186B7} failed due to the following error: 80040154 Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG))

Above is the error i was getting no matter what i do, even if build the app using 32 bit or 64 bit but i was just was not getting rid of that error message and which took a lot of energy out of me, so if you get this error, just skip directly to the SOLUTION section :(

So my first goal was just to get rid of this error and the other challenge was to understand the classes and their properties inside it and methods available etc. but first goal was to get rid of this error, as i never saw lotus notes,i tried to install the latest "Lotus notes client" to see what it contains and what are the terminologies etc. and suddenly my above error just vanished without doing anything, before that i tried to register the class, tried to register the DLL etc but it just did not work, but now it worked and there was no run time error, i was puzzled, Later in my research i realize that even if you have interop.domono.dll referenced in your project, you still need "Lotus notes client" installed on the machine or the server from where you are making a call top lotus notes server.

Solution:
In order to execute your COM calls and use Notes classes inside it, you need to install "Lotus notes client" on that machine, Else it will keep giving you that Class not register error and you will end up going on that track of finding why it gives this error and registering it and 32 bit and 64 bit hell, and by the time you realize you would be on totally another track of the problem solving :).


The goal of this post was just to let you know that even if you have interop, you still need lotus notes client installed, Code samples you can get it from IBM's java examples, sames classes are available in interop.domino.dll

Comments

Popular posts from this blog

One or more exceptions occurred while processing the subscribers to the 'item:creating' event

I was recently installing the packages from one of the QA environment to my local Sitecore instance, "Media library package" to be precise, And it started giving me this below error One or more exceptions occurred while processing the subscribers to the 'item:creating' event Looking at the sitecore logs, it gave me more info on the context and the actual inner exception was following Solution: 'Name' should consist only of letters, digits, dashes or underscore Now it was evident that some of my file names were violating the naming rule, I could see in the log just before exception from where the installer stopped creating items, and that file name had round braces "(" and ")" at the end of it, with my surprise I was able to create the item with those name in the content tree, but below was the solution for it, Solution I am using SC 9.0.1 and in that Go to Sitecore.Marketing.config file residing in "App_Config\Sitecore\Mar...

401.1 Unauthorized with windows authentication error code 0xc000006d

How many of you have faced this hosting issue when you do everything what it takes to run the site with windows authentication but still you are getting the same error again and again? If you think you also have faced the same issue and you tired of reading MSDN KBs for it and still have not found the issue (If KB has solved the issue, well and good, if not you can try this trick),Please Read below Typical scenario In typical hosting with IIS, i did every possible things like enabling windows authentication, changing it in web.config, configuring connection pool, authorization rules, it asks me for window authentication login and despite of entering correct credentials it always fails and keeps on asking for login, and when pressed cancel it gives 401.1 with 0xc000006d error code Solution (Which worked for me at-least after trying for almost 6-9 hrs) You need to change the Loop Back Check in registry so that it allows the host names which you are giving in url are allowed and au...

Zero to Hero - A real life RCA of exact issue in Sitecore Managed Cloud environment

Hello All, The purpose of today's post is to share a real life burning and escalated scenario which was new to me and how did I approach it and how big the escalations were and what was the outcome Sitecore's goodwill was at stack not because Sitecore is not capable of handling it but just because our environment was Sitecore Managed Cloud, and any issue that comes if its infra, back end code, front end code will be first pointed as Sitecore issue and that is where our consultancy and experience will play a role to prove that it is not Sitecore issue.  Issue we faced Out of the blue our site started giving "504 Gateway Time-out", and it was reported that almost everyone is getting this error, but when we used to browse the site, everything looked good and never 504. 504 Gateway Time-out error tells that, That the request went to Content Delivery servers of Sitecore from gateway, but gateway did not get response in time from those CDs and hence it gave time out error. ...