[resolved] Using tFileInputMail - invalid escape sequence error

One Star

[resolved] Using tFileInputMail - invalid escape sequence error

Hello there,
I am trying to develop code that reads an email file on my desktop, extracts key fields from the email and displays the values on the console. I am using the tFileInputMail and tLogRow components. I received the following errors while executing it. Please help!

Exception in thread "main" java.lang.Error: Unresolved compilation problem:
Invalid escape sequence (valid ones are \b \t \n \f \r \" \' \\ )





at xyz.reademail_0_1.Reademail.tFileInputMail_1Process(Reademail.java:520)

at xyz.reademail_0_1.Reademail.runJobInTOS(Reademail.java:1276)

at xyz.reademail_0_1.Reademail.main(Reademail.java:1133)

Accepted Solutions
Ten Stars

Re: [resolved] Using tFileInputMail - invalid escape sequence error

File path references in Java must either be formatted as: 
"C:/Users/hkamara2/Desktop/Emails/20141204-173946_1.mail"
OR
"C:\\Users\\hkamara2\\Desktop\\Emails\\20141204-173946_1.mail"

All Replies
Moderator

Re: [resolved] Using tFileInputMail - invalid escape sequence error

Hi hkstrz,
Could you please share us your tFileInputMail component setting screenshot with us?
Best regards
Sabrina
--
Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.
One Star

Re: [resolved] Using tFileInputMail - invalid escape sequence error

Hey Sabrina,
Thanks for replying. Uploaded the screenshot.
Best,
Hema
One Star

Re: [resolved] Using tFileInputMail - invalid escape sequence error

Hey Sabrina,
Thanks for replying. Uploaded the screenshot.
Best,
Hema
One Star

Re: [resolved] Using tFileInputMail - invalid escape sequence error

 
Hey Sabrina,
Thanks for replying. Uploaded the screenshot.
Best,
Hema

having some trouble with attaching an image. Here are the settings.

File Name: "C:\Users\hkamara2\Desktop\Emails\20141204-173946_1.mail"
Schema: Built-in
Mail-type : MIME
Attachment export directory - "C:\Users\hkamara2\Desktop\Emails"
Mail parts -

Column               Mail part
Date                       Date
Author                   Author
Object                   Object


Nothing under the Multivalues column is ticked.
Six Stars

Re: [resolved] Using tFileInputMail - invalid escape sequence error

You are in java, you need to either flip your slashes so they are not escape characters, or add another slash to them for a literal "\".
One Star

Re: [resolved] Using tFileInputMail - invalid escape sequence error

please can anybody explain me why this error occurs
Ten Stars

Re: [resolved] Using tFileInputMail - invalid escape sequence error

File path references in Java must either be formatted as: 
"C:/Users/hkamara2/Desktop/Emails/20141204-173946_1.mail"
OR
"C:\\Users\\hkamara2\\Desktop\\Emails\\20141204-173946_1.mail"