Office中国论坛/Access中国论坛
标题:
急呀,各位帮忙看看这段代码总是执行不对
[打印本页]
作者:
jsyzzym
时间:
2004-11-8 18:46
标题:
急呀,各位帮忙看看这段代码总是执行不对
Private Sub CommandButton1_Click()
Dim a$, b$, c$, d$
a = "LS" & TextBox2.Text & ".DOC"
b = TextBox1.Text
c = "\\zjyz\doc$\" & b & "\TEMP\"
Set fs = Application.FileSearch
With fs
.LookIn = c
.FileName = "ls568.doc"
If .Execute() > 0 Then
MsgBox "There were " & .FoundFiles.Count & _
" file(s) found."
Else
MsgBox "There were no files found."
End If
End With
上面代码中如果我将共享目录中的$符号去掉就能找到文件,但加上后却找不到,各位看看问题出在哪儿,但我又需要将共享目录隐藏
欢迎光临 Office中国论坛/Access中国论坛 (http://www.office-cn.net/)
Powered by Discuz! X3.3