He guys im gettina a weird error in Xamarin(not the first time).. When i post data to my rest api using HttpClient and MultipartFormDataContent it works fine on IOS simulator however when i deploy on testflight and use a device it keeps giving me a Http Exception error..Posting does work on my login and all my get requests..Any sugestions would be great. Thanks in advance
Asked
Active
Viewed 55 times
0
-
Do your app has network usage permissions? – Ph0b0x Oct 31 '18 at 13:34
-
ya it does and all the relevent references – Oct 31 '18 at 13:35
-
Is it only happening on your POSTs? Can you try add a simple GET code to test if it's happening on all HTTP Requests? Can you share the exact words of your HTTP error? Code? – Ph0b0x Oct 31 '18 at 13:37
-
For iOS make sure your endpoint is using https otherwise you will have to whitelist the url in the plist file. Here's a post that explain better: https://stackoverflow.com/a/40299837/1771254 – pinedax Oct 31 '18 at 15:12
-
the URl im using is https.. The problem only occurs when i post a large amount of data i did set my timeout time to 2 min just for testing and still getting the same issue. – Nov 01 '18 at 06:52
-
its also not even making it to the api...sometimes i do get back sucess but not all the time i think it might be something to do with the posting size – Nov 01 '18 at 07:22
-
Weird thing is it works fine on a simulator with 100% success rate but on a device it works sometimes – Nov 01 '18 at 07:25