Invalid URI: There is an invalid sequence in the string

Apr 12, 2014 at 10:08 AM
I am using LinqToTwitter to post tweets. However i am getting this error and i don't know how to fix

Exception message

Invalid URI: There is an invalid sequence in the string.

Exception stacktrace
       at System.UriHelper.EscapeString(String input, Int32 start, Int32 end, Char[] dest, Int32& destPos, Boolean isUriString, Char force1, Char force2, Char rsvd)
   at System.Uri.EscapeDataString(String stringToEscape)
   at LinqToTwitter.Net.Url.PercentEncode(String value)
   at LinqToTwitter.TwitterExecute.<PostToTwitterAsync>d__34`1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
   at LinqToTwitter.TwitterContext.<TweetOrReplyAsync>d__163.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
   at LinqToTwitter.TwitterContext.<TweetAsync>d__150.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
   at _48_Twitter_Poster.MainWindow.<func_SendTweet>d__1a.MoveNext() in d:\48_Twitter_Poster\48_Twitter_Poster\MainWindow.xaml.cs:line 790
The tweet that causes this error
message 

👓 message ➨

message 

⚅ message ☊
 #msg
So how can i solve this problem ? Thank you


stackoverflow question : http://stackoverflow.com/questions/23028518/invalid-uri-there-is-an-invalid-sequence-in-the-string-error-when-using-linq
Coordinator
Apr 12, 2014 at 8:21 PM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.