Setting port in FtpWebRequest

倖福魔咒の 提交于 2020-01-02 06:36:41

问题


I need the user to be able to be able to modify the port for downloading FTP information - but I can't find a way of changing this in FtpWebRequest.


回答1:


Isn't the port just part of the URI used to create the web request?

FtpWebRequest request = (FtpWebRequest)WebRequest.Create("ftp://10.0.0.1:12345");


来源:https://stackoverflow.com/questions/4024922/setting-port-in-ftpwebrequest

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!