FTP class library

  • Thread starter Thread starter J.C. Developer
  • Start date Start date
J

J.C. Developer

Hi, does anyone know a FTP class library that I can use with my
applications.
I already downloaded the IDSSAPI NET but it is not working and no support
for it.
The Sapphire and Rebex solutions are very expensive.
Thank you for your help in advance.

JC
 
Hi does anyone know how to do this in VB.net CF?
I've been trying for weeks to get a vb.net ftp solution but it seems
impossible!Please help i'm getting desperate! I've used the IpWorks Library
which works great but i cann't use any 3rd party software! All i need to do
is connect to the ftp server and upload a file! It seems so simple.

Please please help me as soon as possible, i'm supposed to meet a deadline!

Thanks for any time you can give

Jimbo.
 
Hi does anyone know how to do this in VB.net CF?


I have used the one from csharphelp, the one in archive9, in the
CompactFramework. Just create a C# class library and put the code in it.
Then reference it from VB.
 
You mean i can include a C# library in my vb.net CF application?

I've done as you said and copied the C# code from csharphelp
into a class file in my vb.net app but how do i reference / include
the c# file? i cann't get it working in a vb form.

THanks so much for helping, i really appreciate it.
 
You have to reference the Class Library (dll) from your project (Solution
Explorer->References).

Cheers
Daniel
 
but its not a dll its just a class file? do i need to make a class file into
a dll, how do i do that?

Sorry to be a pain and thanks for everyone's help but this is going a bit
over my head so it might need spelling out for a simpleton!

THANKS SO MUCH
 
Create a new Class Library under Smart Device project under C#. Then add you
class tot hat and build it. You now have a dll so I refer you to my previous
post.

Cheers
Daniel
 
Hey guys, look really sorry to continue being a pain in the neck, i'm trying
really hard here.

I've downloaded this C#library:
http://www.developerfusion.com/show/4340/
and compiled it into a .dll file just as you said and referenced it into my
vb.net project. 2 problems:

One on build (this appears twice):

Error: The dependency 'mscorlib, Version=1.0.5000.0, Culture=neutral,
PublicKeyToken=969db8053d3322ac' in project 'withdll' cannot be copied to the
run directory because it would conflict with dependency 'mscorlib,
Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'.

and then after that if i carry on regardless, it hangs, i tried debugging
and stepping through but the library is over my head!

this is my code:

Dim ff As New WebCamService.FtpClient


ff.Server = "ftpserver"
ff.Username = "myusername"
ff.Password = "mypassword"

ff.Login()

ff.RemotePath = "file1.txt"
ff.Upload("/My Documents/Hello.txt")
ff.Close()


Please help (again) your being excellent and very patient with me so thanks!

Jimbo.
 
Error: The dependency 'mscorlib, Version=1.0.5000.0, Culture=neutral,
PublicKeyToken=969db8053d3322ac' in project 'withdll' cannot be copied to the
run directory because it would conflict with dependency 'mscorlib,
Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'.

I just tried the following:

1) Start VS2003
2) Create new C# SmartDevice Application, Class Library.
3) Right click on solution, click add Project
4) Add a new Visual Basic Application, Windows Forms Application.
5) On the VB Application, References, click Projects tab, and reference
the C# class library.
6) Add some code to instantiate the Class Library's Class1 in the VB
WinForm app.
7) Hit Run, Debug.

It all works.

So maybe you need to use Project References.
 
Hey saint stephen thats a graet idea, that works well i never thought of
including 2 projects! BUT......

i cann't break out any champagne yet, i'm still a way off, the c# library
still doesn't run smoothly. the main glitch is it hangs when it gets here
createDataSocket();

anyone got any ideas? please bare in mind i'm a vb developer and can not
program c# at all.
here's the code:

ff.setRemoteHost("myhost")
ff.setRemoteUser("myusername")
ff.setRemotePass("mypassword")
Try
'logon works....sometimes!
ff.Login()
Catch
MsgBox("sht")
End Try


ff.upload("/My Documents/Hello.txt")

End Sub


public void upload(string fileName,Boolean resume)
{

if(!logined)
{
login();
}

Socket cSocket = createDataSocket();
 
Back
Top