Schulz666
5/16/2007 5:01:00 PM
Hi,
I have created a .Net 2.0 COM component containing both HTTP and FTP
communication methods. The component was created in the Visual Studio 2005
environment. I am now trying to register the component on another development
machine, and use the component in the Visual Basic 6.0 environment.
I have used regasm to successfully register the component. The HTTP methods
work fine, however when attempting to instantiate an FTP object I receive an
error - "unable to cast System.Net.HttpWebRequest to
System.Net.FtpWebRequest".
Dim listRequest As FtpWebRequest = FtpWebRequest.Create(listUrl)
The code works fine on the original development machine, either from a .Net
2.0 application or a VB 6.0 application.
I am suspecting that either:
-I am registering it improperly on the second computer (I have tried
registering both with the /Codebase switch and without - the assembly is
currently unsigned)
-There is a problem with the .Net 2.0 framework on the second computer
Thanks in advance for any light you can shed,
Sheldon