473,395 Members | 1,457 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Challenge for interop Champions

hello all,

i have created a windows control in VB.NET... i want to
use this control as an activex control in an activex
container.
now here is the scenario until now.

I Updated the project properties so that your assembly is
registered for COM interop by setting register for com
interop option checked.
i created the register and unregister methods inside the
control class. the code is given below:
-----------------------------------------------------------
<ComRegisterFunction()> Public Shared Sub AxRegister(ByVal
RegKey As String)
Dim sb As New StringBuilder(RegKey)
sb.Replace("HKEY_CLASSES_ROOT\", "")
Dim k As RegistryKey
k = Registry.ClassesRoot.OpenSubKey(sb.ToString,
True)
Dim ctrl As RegistryKey
ctrl = k.CreateSubKey("control")
ctrl.Close()
End Sub
<ComUnregisterFunction()> Public Shared Sub
AxUnregister(ByVal RegKey As String)
Dim sb As New StringBuilder(RegKey)
sb.Replace("HKEY_CLASSES_ROOT\", "")
Dim k As RegistryKey
k = Registry.ClassesRoot.OpenSubKey(sb.ToString,
True)
k.DeleteSubKey("control", False)
Dim inprocServer32 As RegistryKey
inprocServer32 = k.OpenSubKey("inprocServer32",
True)
k.DeleteSubKey("CodeBase", False)
k.Close()
End Sub
-----------------------------------------------------------
the project compiled successfully, and the dll was
created.

after that i copied the dll generated thus, into another
machine and registered the dll file using regasm.exe /tlb
on another machine. and the tlb file was generated and
registered successfully.

so far so good. now theoretically, i should be able to see
my control in the list of controls in project->components
window. but i can't. i can see it in project-> references
window, which is a list of non control activex components
(duh!). but i can't see it in the project->components
window.

what am i missing and where...?

this is an emergency and i am running out of time...

please help...

regards,

Nilotpal

Jul 19 '05 #1
0 1328

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

Similar topics

0
by: keefah | last post by:
Hi, I'm writing a C# web app that uses Outlook to send email. I use a reference to the Microsoft Outlook 11.0 Object Library, but it's giving me problems. I tracked down some stuff on the Net...
0
by: lacour | last post by:
I can't seem to figure out the difference between adding a COM dll reference in VS2003 and by using TLBIMP. I have a COM dll that references another COM dll, and I want the syntax of my...
8
by: Frank Buss | last post by:
A new challenge: http://www.frank-buss.de/marsrescue/index.html Have fun! Now you can win real prices. -- Frank Buß, fb@frank-buss.de http://www.frank-buss.de, http://www.it4-systems.de
8
by: Rob Edwards | last post by:
When trying to add the Microsoft CDO for Exchange Management Library (aka CDOEXM.dll) I receive the following message: "A reference to 'Microsoft CDO for Exchange Management Library' could not be...
0
by: Nilotpal | last post by:
hello all, i have created a windows control in VB.NET... i want to use this control as an activex control in an activex container. now here is the scenario until now. I Updated the project...
1
by: Ben | last post by:
Dear There, I have problem to implement a Web Service which integrate with ScanSoft OCR Engine. Scansoftware OCR Engine is run on server DLL and BIN files. What's the approach to do this...
0
by: Richard Jones | last post by:
The date for the second PyWeek challenge has been set: Sunday 26th March to Sunday 2nd April (00:00UTC to 00:00UTC). The PyWeek challenge invites entrants to write a game in one week from...
0
by: richard | last post by:
The date for the second PyWeek challenge has been set: Sunday 26th March to Sunday 2nd April (00:00UTC to 00:00UTC). The PyWeek challenge invites entrants to write a game in one week from...
2
by: JC | last post by:
Anybody knows what problem has this code? I think, in the Garbage Collector? You know the Solution? The program in the test's case, whit 350 contacts, run OK before number 86. The error is a...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
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...

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

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.