Foxtable(狐表)用户栏目专家坐堂 → FTP问题


  共有3423人关注过本帖平板打印复制链接

主题:FTP问题

帅哥,在线噢!
BG小白
  1楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:二尾狐 帖子:579 积分:3965 威望:0 精华:0 注册:2019/11/14 23:06:00
FTP问题  发帖心情 Post By:2021/1/18 23:30:00 [只看该作者]

Dim str1 As String
str1= FileSys.GetName(dlg.FileName)
If ftp1.DirExists(str) Then
    ftp1.ChangeDir(str)
    If ftp1.FileExists(str1) = True Then
        MessageBox.Show("已有重名文件")
        Return
    Else
        If ftp1.Upload(dlg.FileName) = True Then
            Messagebox.show("上传完成!","提示",MessageBoxButtons.OK,MessageBoxIcon.Information)
            e.form.controls("TextBox4").text = FileSys.GetName(dlg.FileName)
        Else
            Messagebox.show("上传失败!","提示",MessageBoxButtons.OK,MessageBoxIcon.Information)
        End If
    End If

为什么红色那段代码没有效果,我里面已经有个名为1的文件了,但是还能上传,是不是因为目录的原因呢?

 回到顶部
总数 29 1 2 3 下一页