Commit 9c123494 by Simhachalam ch

added timestamp to log file

parent 95a288c3
...@@ -612,7 +612,8 @@ public class ChatActivity extends AppCompatActivity implements OnDSListener, OnD ...@@ -612,7 +612,8 @@ public class ChatActivity extends AppCompatActivity implements OnDSListener, OnD
private void exportAndSaveLogs(List<ChatLog> chatLogList) { private void exportAndSaveLogs(List<ChatLog> chatLogList) {
String baseDir = android.os.Environment.getExternalStorageDirectory().getAbsolutePath(); String baseDir = android.os.Environment.getExternalStorageDirectory().getAbsolutePath();
String fileName = "chatlog.csv"; String dateString = Util.getDateTime(new Date().getTime());
String fileName = "ChatLogs_" + dateString + ".csv";
String filePath = baseDir + File.separator + fileName; String filePath = baseDir + File.separator + fileName;
File f = new File(filePath); File f = new File(filePath);
CSVWriter writer; CSVWriter writer;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment