Click here to Skip to main content
15,949,686 members

Comments by Luis M. Rojas (Top 11 by date)

Luis M. Rojas 15-Jul-24 8:41am View    
Thanks, thanks a lot. That is what i want.
I do not know LINQ, but i am going to see some examples.
Really thanks
Luis M. Rojas 5-Jun-23 12:39pm View    
That is what i want
Luis M. Rojas 20-May-23 15:28pm View    
Nothing, never get there, only try.. postasync, try and postasync
Luis M. Rojas 17-Apr-23 10:21am View    
What is client in this line?
These lines:
#if DEBUG
HttpClientHandler insecureHandler = DependencyService.Get<ihttpclienthandlerservice>().GetInsecureHandler();
HttpClient client = new HttpClient(insecureHandler);
#else
HttpClient client = new HttpClient();
#endif

Are you want to upload file more than 16384?
Not, i am just taking a picture with these lines:
var file = await MediaPicker.CapturePhotoAsync() ;
if (file == null) return;
var content = new MultipartFormDataContent();
content.Add(new StreamContent(await file.OpenReadAsync()), "file", file.FileName);
Web API built with..? ASP.NET CORE
Luis M. Rojas 5-Apr-23 11:02am View    
Well, if you see these lines:
content.Add(new StreamContent(await file.OpenReadAsync()), "file", file.FileName);
string url = "https://10.0.2.2:7254/api/GetData/Upload/";
client.BaseAddress = new Uri(url);
var response = await client.PostAsync("", content);
In this line:
content.Add(new StreamContent(await file.OpenReadAsync()), "file", file.FileName);
I can read and see the file.FileName
But in the Web Api, in this line: public async Task<string> Upload( List <iformfile> files)
files do not recive any value, i mean: it is EMPLY,
How do i pass the value from the program and pass it to the web api.
I did what you said.
Thanks to all