What are the reasons an ATL server might fail to register?



What are the reasons an ATL server might fail to register?..

Answer / abhijit sukale

The following are the top three reasons an ATL server might
fail to register: 1. You built your project with
_WIN32_WINNT=0x400 (the default), and you are not running
the ATL server under Windows NT 4.0 or you do not have an
up-to-date version of Oleaut32.dll. To solve this problem,
run "DUMPBIN /EXPORTS OLEAUT32.DLL" and search for
UnregisterTypelib. If it is not there, then your server
cannot run. Remove this #define statement from Stdafx.h if
you want to run the ATL server under Windows 95 or older
versions of Windows NT. Alternatively, you can use
LoadLibrary and GetProcAddress so that you can run
optimally under both Windows 95 and Windows NT 4.0. The
Oleaut32.dll that ships with the Internet Explorer 3.x is
up-to-date.
2. You built your project as MinSize and Atl.dll is not
properly installed on the system. The correct version of
Atl.dll must be copied and registered by Regsvr32. There
are Windows NT and Windows 95 versions of Atl.dll. The
Windows 95 version runs under Windows NT. However, since it
does not use the UNICODE APIs, it is slightly less
efficient. Unless you build your project as MinDependency,
you will need to install the correct version of Atl.dll and
run Regsvr32 on it before you install your server.
3. You built your project as UNICODE, and you cannot run it
under Windows 95.
The following are the steps to troubleshoot: 1. For a DLL
server, run Regsvr32 in the debugger. Open the Project
Settings dialog box and click the Debug tab. In the
Executable for debug session text box, enter the full path
to Regsvr32.exe, such as C:\Sharedide\Bin\Regsvr32.exe. In
the Program arguments text box, specify the full path to
your DLL, such as C:\Myprojects\MyFolder\Debug\MyFile.dll.
Set a breakpoint at DllRegisterServer and start stepping.
2. For an EXE server, run it in the debugger and
specify /REGSVR as its command-line argument.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More ATL Interview Questions

What changes does a control need to run in the Visual Basic 5.0 Control Creation Edition?

0 Answers  


What Is the ATL Control-Hosting API?

2 Answers  


how do you like to go up in a swing

1 Answers   Colgate,


How to Reuse interface implementation in source in ATL projects ?

1 Answers   Syntel,


sap hana online training in USA UK CANADA INDIA AUSTRALIA

1 Answers   SAP Labs,






Which ATL Classes Facilitate ActiveX Control Containment?

1 Answers  


How to get the <PARAM> tag to work with an ATL control?

0 Answers  


why we write function's implementation in .h file while developing the Web application through VC++?

0 Answers   TCS,


Will ATL create all of the topological relationships within the topology layer?

0 Answers  


what type of questions are asked in the test of pcs and what type of questoins are asked by interviewer in pcs interview.

0 Answers  


How to Load Controls Specified at Run Time?

1 Answers  


how to create SDK based ATL ? how to create SDK based COM?

1 Answers   TCS,


Categories