Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Azure COM Objects

Tags:

web

com

azure

I am trying to move a website I am hosting on a server with IIS over to an Azure web site. I'm using a COM object but I'm not sure if I can register this? I found some posts talking about uploading the dll and registering it on start up but the article seems to be missing. Is this possible?

like image 391
thecaptain0220 Avatar asked Apr 16 '13 14:04

thecaptain0220


People also ask

What are Azure objects?

Azure Blob storage is Microsoft's object storage solution for the cloud. Blob storage is optimized for storing massive amounts of unstructured data, such as text or binary data. Blob storage is ideal for: Serving images or documents directly to a browser.

What is Azure object anchors?

Azure Object Anchors is a mixed reality service that helps you create rich, immersive experiences by automatically aligning 3D content with physical objects. Gain contextual understanding of objects without the need for markers or manual alignment.

Does Azure have object storage?

Explore the comprehensive suite of Azure storage services for object, block, and file storage to meet your data's highest demands. Easily scale your performance, get high availability and enterprise-grade security, and unify data management with Microsoft cloud storage solutions.


2 Answers

I had this exact problem registering legacy COM Components on Azure. I documented my methodology here:

AspPDF and AspJPEG on Windows Azure

Igorek is correct, you will need to use a Web Role to achieve this. The solution above is based on a single Web Role with a startup script to run regsvr32 as a startup task.

To summarise, there are essentially two parts to achieving this. First create a batch file to run the regsvr32 command:

chcp 1252>NUL
regsvr32 /s .\library\my-com-class.dll
exit /b 0

Then define a startup task in your ServiceDefinition.csdef file:

<Startup>
<Task commandLine="mybatchfile.cmd" executionContext="elevated" taskType="simple" />
</Startup>

This will trigger the command file to run on deployment.

like image 189
QFDev Avatar answered Sep 30 '22 14:09

QFDev


You cannot register a COM object within an Azure Website. You will need to upgrade to Web Roles in order to do this. Registration of com object can happen during the startup scripts then.

like image 36
Igorek Avatar answered Sep 30 '22 12:09

Igorek