I have very small and simple problem but I am not getting solutions on it. Actually I am getting a CSV file path using file chooser. I am entering the data in this csv file
String filepath2=filepath.replace("\","\\") is not valid code - \ is a special character in string literals and needs to be escaped:
String filepath2=filepath.replace("\","\\")
\
String escapedFilepath = filepath.replace("\\","\\\\"); //double all backslashes