I have used this to save my file
string m_strDate = DateTime.Now.ToString("MM/dd/yyyy");
m_strDate = m_strDate.Replace("/", "");
strPath += "/FileHeader_" + m_strDate + ".txt";
So as per this I can save a file per day. But if I create for another time the data in that text file is getting replaced by the new one. Now what I need is I would like to save my file with some name along with date and a number like
"/FileHeader_1" + m_strDate + ".txt"
and so on.
1 Answer