在Silverlight中通过FTP上传文件 [英] upload the files via FTP in Silverlight

查看:61
本文介绍了在Silverlight中通过FTP上传文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在Silverlight中通过FTP上传文件?

在代码中:

how is upload the files via FTP in Silverlight?

in code :

private void btnFtpUpload_Click(object sender, RoutedEventArgs e)
        {
            var socket = new Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp);
            var args = new SocketAsyncEventArgs();
 
           
            args.RemoteEndPoint = new DnsEndPoint("localhost", 21);
           
          
           args.Completed +=
                delegate
                {
                    Thread.Sleep(1000);
                   SendString("username: xxx",
                               delegate
                               {
                                   SendString("password: xxx", delegate
                                   {
 
                                   }
                               }, socket);
                };
            socket.ConnectAsync(args);
        }




用下划线字体显示的部分发生错误!

添加代理时发生错误:args.Completed [/Edit]

请帮助我




In part that is displayed with Underline font an error occurs!

The error occurs were the delegate is added: args.Completed[/Edit]

Please help me

推荐答案

这听起来可能会更加复杂,因为有可能,但是还有很多工作:
http://forums.silverlight.net/t/180751.aspx/1 [ ^ ]
This is going to sound more complicated that needs be, becouse it is possible, but a lot of work:
http://forums.silverlight.net/t/180751.aspx/1[^]


这篇关于在Silverlight中通过FTP上传文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆