添加链接
link管理
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接
473,573 Members | 5,623 Online

Activator.GetOb ject() does not work when called via COM

I have a Windows Service written in C# that gets an object via
Remoting using the Activator.GetOb ject() and then calls a method on it.
When called via .NET apps, everything works great.

I made a .NET Interop wrapper that executes the same method, but when
I call the method via VB6, I get the following error:

"Trying to create a proxy to an unbound type."

This doesn't make sense to me, my base class is derived from
MarshalByRefObj ect, is there a COM limitation?

Mark.

Oct 25 '06 # 1
1 3702
There you go. Hope this can help you. VB.NET and C# should act the same:
http://msdn.microsoft.com/library/de...vbbestprac.asp

I am going to play with it too.
Good luck.
chanmm

<mk*******@gmai l.comwrote in message
news:11******** **************@ k70g2000cwa.goo glegroups.com.. . I have a Windows Service written in C# that gets an object via
Remoting using the Activator.GetOb ject() and then calls a method on it.
When called via .NET apps, everything works great.

I made a .NET Interop wrapper that executes the same method, but when
I call the method via VB6, I get the following error:

"Trying to create a proxy to an unbound type."

This doesn't make sense to me, my base class is derived from
MarshalByRefObj ect, is there a COM limitation?

Mark.

Oct 26 '06 # 2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5980
by: CJM | last post by: I'm building an ASP app that uses Windows Authentication (IWA). I have an authentication routine that assesses if & how the user can use the application (see code snippet below). Users of a particular group have full permissions (configured via IIS) and all other users have read/execute permissions. When I call the authentication page...
1347
by: rlum | last post by: I have a remoting app that calls a windows service using the Activator.GetObject(type, url). works great with studio 2002 and framework 1.0. However I upgraded to 2003 and 1.1. Now it dosen't allow any access to it. it creates the transparent proxy with no methods available. It looks like I need reflection permissions correct? how and where do...
20275
by: Otie | last post by: I found the following under the GetObject help notes and in the example for GetObject: "This example uses the GetObject function to get a reference to a specific Microsoft Excel worksheet (MyXL). It uses the worksheet's Application property to make Microsoft Excel visible, to close it, and so on. Using two API calls, the DetectExcel Sub...
1628
by: Baskar RajaSekharan | last post by: Hi I have one doubt in C#. I created one component called CustomTesting in VC7. The DLL contains Two Method called Execute and SetOCxInterface. I want to Load the from my Sample application(which is in C#) with out Addeing it in Reference. ie i want to load it dynamically with the help of Activator.CreateInstance. Then i want to...
17057
by: System.Reflection Activator | last post by: ************************************** //Load the Assembly Assembly a = Assembly.LoadFrom(sAssembly); //Get Types so we can Identify the Interface. Type mytypes = a.GetTypes(); BindingFlags flags = (BindingFlags.NonPublic | BindingFlags.Public | BindingFlags.Static | BindingFlags.Instance | BindingFlags.DeclaredOnly); //Iterate through...
1225
by: MichaelSL | last post by: When I build an executable which uses System.Activator.CreateInstance and execute it on my PC, which has Microsoft Visual Studio installed, the CreateInstance works just fine and the class constructor is called. But when I move this executable to another PC (even one with Microsoft Visual Studio) the execution proceeds all the way to the...
2244
by: Ian Frawley | last post by: I have used the Activator class a number of times in my Windows apps and Windows Services and was thinking of using it again in one of my web services that I have been developing. I have been told that this is a bad idea as it will greatly affect the performance of my web service. So I have been thinking about it and all my other apps...
8658
by: newscorrespondent | last post by: This method does not fail if the site is not running! Is there a way to check the proxy for failure? Thanks
1306
by: Jules Winfield | last post by: I have a singleton object that's accessed via remoting by way of Activator.GetObject(): SomeObject someObj=(SomeObject)Activator.GetObject(typeof(SomeObject),someUrl); My question is: Is the proxy returned by Activator.GetObject() thread-safe? I know that my IMPLEMENTATION of SomeObject has been built in a thread-safe way -- but is the...
.NET Framework
7656
by: Hystou | last post by: Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
7720
by: Hystou | last post by: Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
8013
by: tracyyun | last post by: Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
5547
by: isladogs | last post by: The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
5250
by: conductexam | last post by: I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
3689
by: TSSRALBI | last post by: Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
3678
by: adsilva | last post by: A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1245
by: muto222 | last post by: How can i add a mobile payment intergratation into php mysql website. 981
by: bsmnconsultancy | last post by: In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use .