Did you do a step by step debugging to see where the error is? For example: Did you check whether

CLSIDFromProgID( L"DVBViewerServer.DVBViewer", & clsid );

returns a valid clsid?

I assume you are developing using Microsoft Visual C++? I recommend to use the Microsoft Tool "OLE COM Object Viewer" to inspect the DVBViewer COM Library. From there you can generate .h Header and clsid files as stubs for your DVBViewer class that make the development easier.

You might get some hints from these two threads, these are in German but there are a lot of code samples and downloads that might help:

Before posting a bug or problem please read the following hints:
There is no support for outdated versions! You can download the current DVBViewer Pro release as registered customer in the member's area.https://www.DVBViewer.tv/members/. In case of OEM versions like the DVBViewer TechniSat Edition (DVBViewer TE2) only the card manufacturer is responsible for support.
First of all: Keep calm! With haste you may worsen the damage or problem.
Read the Wiki and/or the old manual.
If nothing applies please use the DVBViewer forum search function. Select Search and enter a search item (at least 4 let­ters). You may also use the link to the Google site search at the top of the forum without search item length restrictions. There is a high probability that your problem has already been discussed and solved in the past.
If the search delivers no results you may ask for assistance in the forum. You should carefully formulate your question, at best take your time and write it off-line first. Please provide detailed step-by-step instructions for reproducing the problem, if possible.
Please use the Support Tool (Download) for providing additional information. Perform the following steps:
If there is a problem with DVBViewer Pro, launch DVBViewer in Debug Mode - see start menu -> DVBViewer (-> Support) -> DVBViewer Pro (Debug Mode).
Reproduce the problem.
Close DVBViewer, or if there is a problem with the DVBViewer Media Server / Recording Service, stop it by using the menu that appears after right-clicking the blue DVBViewer tray icon.
Store and execute supporttool.exe in the DVBViewer installation folder (where DVBViewer.exe is).
The Support Tool collects relevant configuration files and system information in a support.zip file. Please attach this file to your post.

You can delete old attachments here if you have not enough attachment space. The support.zip contains the following information (no specific user data):
SystemInfo.txt (containing information about the operating system, CPU type und speed, available RAM, graphics card with current driver version, registered video and audio decoders)
DVBViewer configuration files (setup.xml, windowdef.xml, hardware,xml, usermode.ini, DVBSource.ini).
DVBViewer Media Server or Recording Service configuration files (svchardware.xml, service.xml).
Configuration files of add-ons provided by dvbviewer.com (Audiorecorder.ini, TransEdit.ini, TSPlayer.ini)
Log files (DVBViewer.log, svcdebug.log, OSD.log, OSDerror.log) if available
Additionally you should indicate the following:
exact name of the TV-card and used driver version
graphics card and used driver version
Requests without the required information cannot be answered!