# How can multithread Visual Basic servers be implemented

**URL:** <https://techcommunity.softwareag.com/t/how-can-multithread-visual-basic-servers-be-implemented/58924>\
**Category:** Forum\
**Tags:** Mainframe-Integration, EntireX\
**Created:** [November 19, 2003, 5:20pm UTC](https://techcommunity.softwareag.com/t/how-can-multithread-visual-basic-servers-be-implemented/58924 "2003-11-19T17:20:55Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Thierry\_Casier](https://avatars.discourse-cdn.com/v4/letter/t/5f9b8f/32.png) [@Thierry\_Casier](https://techcommunity.softwareag.com/u/Thierry_Casier)\
**Post date:** [November 19, 2003, 5:20pm UTC](https://techcommunity.softwareag.com/t/how-can-multithread-visual-basic-servers-be-implemented/58924/1 "2003-11-19T17:20:55Z")

</div>

Hello,  
  
We are using a ACI server that is written in Visual Basic .NET. For communication to the broker we are using the Broker ActiveX control. When the .NET server starts it can instantiate multiple servers by the multithreading mechanism of .NET. However the Broker ActiveX control can only be started once, you can verify this in the control center.  
Each .NET thread must pass it’s call to OLE32.dll which then serializes all calls to the Broker ActiveX control. Other languages like C don’t have this problem but the syntax is on a lower level then VB.  
An enhancement proposal has been submitted to SAG for this but meanwhile we would like to continue development.   
Has anybody already dealed with this problem and how did you resolve it?  
  
best regards,  
  
Thierry Casier

---

<div class="post-metadata">

**Author:** ![Clauder](https://avatars.discourse-cdn.com/v4/letter/c/4da419/32.png) [@Clauder](https://techcommunity.softwareag.com/u/Clauder)\
**Post date:** [November 21, 2003, 7:07pm UTC](https://techcommunity.softwareag.com/t/how-can-multithread-visual-basic-servers-be-implemented/58924/2 "2003-11-21T19:07:40Z")

</div>

Hello,  
  
Use “Attach Server”   
  
In EntireX Comunicator Release 7.1 now aviable Attach Manager on UNIX and Windows  
In the docu see “Release Notes” → “What’s New in this Release” → “Attach Manager on UNIX and Windows”.  
  
or make your Attach Manager  
  
Attach Manager Server  
Register (function=6,Option=13)  
Receive-loop (function=2,option=0,conv-id=NEW,wait=30S)  
 if error-code=“00100022”  
 Start Application Server in new thread  
 elsif error-code=“00740074”  
 Continue  
 else  
 exit-loop  
 endif  
end-loop  
Deregister (function=7,option=3)  
end  
  
Server Application  
 Register (function=0,option=0)  
 conv-id=NEW  
 Receive-loop (function=2,option=0,wait=NO)  
 Send-data (function=1)  
 end-loop  
 Deregister (function=7,option=3)  
end  
  
Hope this helps.  
  
Let me know if you need additional information.  
  
Regards,  
Clauder Balzano.

---

<div class="post-metadata">

**Author:** ![Thierry\_Casier](https://avatars.discourse-cdn.com/v4/letter/t/5f9b8f/32.png) [@Thierry\_Casier](https://techcommunity.softwareag.com/u/Thierry_Casier)\
**Post date:** [November 25, 2003, 4:14pm UTC](https://techcommunity.softwareag.com/t/how-can-multithread-visual-basic-servers-be-implemented/58924/3 "2003-11-25T16:14:50Z")

</div>

Clauder,  
  
Our development team has taken another way. They create multiple EXE files to start multiple servers. So they don’t use attach management but they hope to start enough servers to keep up with the load.  
We’ll see if this can be successfull.  
  
thanks anyway for your reply.  
  
Thierry Casier  
  
Thierry Casier

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [April 2, 2021, 2:39pm UTC](https://techcommunity.softwareag.com/t/how-can-multithread-visual-basic-servers-be-implemented/58924/4 "2021-04-02T14:39:33Z")

</div>


