Solved

In-Proc ActiveX server?

Posted on 1997-05-21
2
315 Views
Last Modified: 2013-12-03
Hi y'all, ActiveX question here.

Say I've got an in-proc ActiveX server that supports ActiveX Automation.

Now say that I want to write automation scripts in various ActiveX-compatible languages that access the in-proc server. (I'm specifically concerned about Lotusscript and Lotus Notes.)

Now, say that these scripts are going to be called and terminated repeatedly, losing all their states each time they are terminated.

What is the most performant way for a script to connect to an ActiveX in-proc server running this way?  If each script starts out with a

server = CreateObject("serverapp.Application") or whatever, will it incur a large performance penalty?  Can you even use an in-proc server this way?

And specifically for Notes, is there any way to keep the handle to my ActiveX in-proc server around between script (agent) invocations?

Answers will result in gratuitous "thank you"s.

Larry Edelstein
Director of Engineering
SpotMedia Communications

0
Comment
Question by:ledelste
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 1

Accepted Solution

by:
gtschech earned 150 total points
ID: 1397547
CreateObject() is a high-level interface thats used inside VBA. If you are programming in plain C/C++, your call would be CoCreateInstance().
In any case, the operating system will be invoked to find out where the Class Factorx for the object resindes, which is determined by some Registry entries. After that process, there will be not too much pemalty, because in-process servers behave much like normal 'linked' classes.

You can keep the pointer to the script as long as you wish (but release it before you leave your program), if the scripting language has some form of 'reset' feature, i.e. you can always start a new procedure without having to cope with old variable settings. For I have no special knowledge about Lotus scripting, I can't tell you explicitly, but I believe it should be always possible.
0
 

Author Comment

by:ledelste
ID: 1397548
Don't really understand the second para; in my case, I have an ActiveX server that I want to serially re-use, but it may be that I have no way of maintaining state, so I need to know the quickest way to reconnect to it.  I stated this clearly in my question but it was misunderstood.

The information about CreateObject was useful, however.
0

Featured Post

Creating Instructional Tutorials  

For Any Use & On Any Platform

Contextual Guidance at the moment of need helps your employees/users adopt software o& achieve even the most complex tasks instantly. Boost knowledge retention, software adoption & employee engagement with easy solution.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Does Microsoft Office 2016 support COM/ActiveX? 3 141
ODBC Connection; Switch between 2 SQL Databases VBA 11 145
Need to create an object factory 2 52
Problem to file 3 98
This article shows a few slightly more advanced techniques for Windows 7 gadget programming, including how to save and restore user settings for your gadget and how to populate the "details" panel that is displayed in the Windows 7 gadget gallery.  …
As more and more people are shifting to the latest .Net frameworks, the windows presentation framework is gaining importance by the day. Many people are now turning to WPF controls to provide a rich user experience. I have been using WPF controls fo…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question