相关代码 |
|
Ch13-02-01.aspx 检查指定的文件是否存在 Sub Button1_Click(Obj As Object, E As EventArgs) Dim FileName As String = File1.Text If Trim(File1.Text) = "" then Label1.Text = "请输入文件名称!" Exit Sub End If Dim Files As New FileInfo(FileName) If Files.Exists Then Label1.Text = "文件存在!" Else Label1.Text = "文件不存在!" End if End Sub 文件名称: Runat="Server" /> OnClick="Button1_Click" Runat="Server" /> BorderColor="#FF0000" Runat="Server" />
相关资源 |
|