For Programmers: Free Programming Magazines  


Home > Archive > Smartphone Developer Forum > April 2006 > Help about placing a file on a FTP server









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Help about placing a file on a FTP server
jerome

2006-04-26, 8:06 am

Hello,
I have already made some post about this topic, but I decided to do some
changes.
I want to develop a program for a Windows Mobile 5.0 Smartphone. I think the
better and the more simple language to do this is the C#.
The goal of the program is to take a snapshot with the camera's phone and
automatically send it by placing this picture on a ftp server.
So to take the picture, I'll use CameraCaptureDialog() of
Microsoft.WindowsMobile.Forms, I think it will be not too difficult.
But my problem is to place it on the FTP server. I don't know how to connect
the device on Internet by a GSM/GPRS/UMTS connexion in C# and I don't know
how to put files on the server too.

I found some function to do this, like that :

System.Net.WebClient wc = new System.Net.WebClient();

wc.Credentials = new NetworkCredential(@"Username", @"Password");
wc.UploadFile(@"ftp://FTP/file.jpg",
System.Net.WebRequestMethods.Ftp.UploadFile, @`"\file.jpg");
wc.Dispose();

BUT it is not possible to do this with Windows Mobile 5.0 (the librairy is
only usable with .NET Framework). So i'm a bit lost.

So please, if someone knows how to make a Internet connexion in C# for a
smartphone and place a file on a FTP server, help me to start or tell the
good way to do.
Sample codes are greatly welcome.

Thx, Jerome
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com