在运行应用程序时动态创建文本文件夹 [英] creating text folder dynamically when we run the application
问题描述
当我们自动运行应用程序时如何创建文本文件夹,错误和结果应该存储在该文件夹中。
(例如)D:\ application1 \ logfolder \
此路径由我创建
我应该获得
(例如)D:\ application1 \ logfolder\mar 29/3 / 2015 \\ \\ log_mar 29/03 / 2015.txt应该创建dyanamically并且错误和结果应该存储在那个文本文件中如
名称上传成功
mobileupload成功
。
。
任何人都可以帮助
how to create text folder when we run the application automatically and the errors and the result should store in that folder.
(e.g) D:\application1\logfolder\
this path create by me
And i should get
(e.g) D:\application1\logfolder\mar 29/3/2015\log_mar 29/03/2015.txt is should create dyanamically and the errors and result should store in that text file like
name upload successfull
mobileupload successful
.
.
can anyone help
推荐答案
使用Directory.CreateDirectory Method(String) [ ^ ]。
Use Directory.CreateDirectory Method (String)[^].
创建指定路径中的所有目录和子目录,除非它们已经存在。
Creates all directories and subdirectories in the specified path unless they already exist.
这篇关于在运行应用程序时动态创建文本文件夹的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!