System.setProperty: Invalid Escape Sequence

Im trying to make a reference to a bin.

System.setProperty("mbrola.base", "C:\Users\Name\Desktop\FreeTTS\MBrola Project"); 

But Im getting this error:

Invalid escape sequence (valid ones are \b \t \n \f \r \" \' \\ )
Jon Skeet
people
quotationmark

Yes, because this isn't a valid string literal:

"C:\Users\Name\Desktop\FreeTTS\MBrola Project"

You need to escape the backslashes:

"C:\\Users\\Name\\Desktop\\FreeTTS\\MBrola Project"

The string itself will only have the single backslashes though - you're just escaping it in source code.

people

See more on this question at Stackoverflow