to sjc0(流浪者)
还是不行,我用的是VB,请再赐教
还是不行,我用的是VB,请再赐教
解决方案 »
- 如何获取li中的选中值。。
- 用3层的方法写了个datalist分页。在输出html的时候出了点问题。请帮解决!谢谢!!
- 关于一个SQL存储过程的问题
- 开发办公管理查询系统思路是什么?
- DetailsView如何在自已编写数据源的情况下实现插入操作,汗。。。
- 怎样设定水晶报表绑定存储过程.
- c#中有没有专门处理页面异常的事件?
- SQL 语句如何书写看起来比较清晰、明了?
- Response.write("document.write()");如何一起写?
- vs2010提示未能完成操作
- 上传中文文件名的文件
- 我更菜,到现在还不知道什么是水晶报表,是干什么的,总是在 csdn 上看到有人问关于水晶报表的问题,求高手给简单解释一下!谢谢了
VB中你加吧!再试!
Imports System.IO
Imports System.TextPublic Class Test
Public Shared Sub Main()
Dim path As String = "c:\temp\MyTest.txt"
Dim path2 As String = path + "temp"
Try
Dim sw As StreamWriter = File.CreateText(path)
sw.Close()
' Do the Copy operation only if the first file exists
' and the second file does not.
If File.Exists(path) Then
If File.Exists(path2) Then
Console.WriteLine("The target file already exists.")
Else
'try to copy it
File.Copy(path, path2)
Console.WriteLine("{0} was copied to {1}.", path, path2)
End If
Else
Console.WriteLine("The source file does not exist.")
End If
Catch e As Exception
Console.WriteLine("The process failed: {0}", e.ToString())
End Try
End Sub
End Class