Questions tagged [sendasync]

83 questions
0
votes
1 answer

Why does UDPSocket.SendAsync() requires connect() method to work?

I Was working with XXXAsync methods and socketeventargs in c# then when testing my console app, data was not being sent (locally- within a pc) and no error was thrown with this code at sender app. public class Client { private static Socket…
Crocodile
  • 43
  • 4
0
votes
1 answer

Get Mail Setting from Web.Config in SendAsync Method?

I am working on Forgot Password Functionality. In my web.config file I have done the mail settings:
M Armaan
  • 39
  • 8
0
votes
0 answers

ASP.Net - SMTP SendMailAsync Not Working

I have the following code to send email but I get the following error: An asynchronous module or handler completed while an asynchronous operation was still pending This is the code in controller: [AllowAnonymous] public async…
adam78
  • 9,668
  • 24
  • 96
  • 207
0
votes
1 answer

C# UWP Socket: using ReceiveAsync / SendAsync and handling a timeout without closing the socket

I'm writing a class library on UWP platform that is going to be used from a mobile UWP application. The library needs to talk with an external device through a proprietary protocol TCP-based. The protocol requires Receive or Send operation to be…
Yusef Maali
  • 2,201
  • 2
  • 23
  • 29
0
votes
1 answer

Post content stream gets bufferend when using compression on content-block

First to what works: (the description of my problem further down) A client application sends a long data-stream to the server WebAPI. The request is chunked (request.Headers.TransferEncodingChunked = True) and the data gets written to the stream "on…
spaark
  • 701
  • 10
  • 17
0
votes
0 answers

UWP http client delay in getting response

I found this peculiar behaviour of UWP HttpClient. For a simple get call of WCF service is taking time almost more than 100 seconds(happens for first few calls). I observed that the same service is way too faster in iOS and rest client. Attaching…
user998644
  • 11
  • 1
0
votes
0 answers

smtpClient.SendAsync: The email never arrives C#

SmtpClient Client = new SmtpClient(SMTPClientHostName, 25) { EnableSsl = true, Timeout = 30000, DeliveryMethod = SmtpDeliveryMethod.Network, UseDefaultCredentials = false, Credentials = new…
soulblazer
  • 1,178
  • 7
  • 20
  • 30
0
votes
1 answer

Not returning response of HttpRequest on partial content C# UWP

Code that did work now all of a suddent not working due to not returning response of HttpRequest on partial content C# UWPDropbox, Google Drive & Onedrive. I have a feeling that a Visual Studio or Windows 10 SDK upgrade caused this or maybe .Net has…
Sixjac
  • 339
  • 4
  • 16
0
votes
0 answers

Cannot convert lambda expression to type 'System.IAsyncResult' because it is not a delegate type

Can someone help me with this? I tend to work mostly in VB, so this C# compile error is a problem: // Copyright (c) .NET Foundation. All rights reserved. // Licensed under the Apache License, Version 2.0. See License.txt in the project root for…
0
votes
1 answer

Xamarin.Forms problems sending large picture over HttpClient SendAsync in Json format

from my Xamarin.Forms app I'm sending a picture and other fields to the server using HttpClient in Json format. If I send a little picture I've got with my front camera it's working fine, if I send a larger picture I've got with the rear camera it…
Stefano
  • 200
  • 4
  • 15
0
votes
0 answers

C# - about Windows.Forms Timer and SMTPClient.SendAsync

I have a Windows.Form Timer that triggers an event every x minutes(5 minutes for example). Basically when that event is triggered, it sends an email out. I used the SMTPClient.SendAsync(); but it does not send the email out successfully. I tried…
aresz
  • 2,589
  • 6
  • 34
  • 51
0
votes
0 answers

SmtpClient.SendAsync Method (MailMessage, Object) doesn't function in a asynchronous way

In MSDN it is explained that this method does not block the calling thread and allows the caller to pass an object to the method that is invoked when the operation completes. But when I used it in my asp.net project it still blocked the caller…
0
votes
1 answer

Ping Class SendAsync Help

I am new to programing and can not find or know what to search for to debug the thread that is started with the SendAsync Method. The code works good using the Send Method but when using SendAsync it goes to waiter.WaitOne() but i never get the…
0
votes
1 answer

When will SendAsync complete?

I'm writing a server and need to be able to send a message to all connected clients. I'm trying to decide if I should create SocketAsyncEventArgs for each connected socket and send all the packets at once. Another approach would be to use a single…
remdao
  • 885
  • 3
  • 17
  • 23
0
votes
1 answer

Is it possible to output SmtpClient.SendAsync() result to a MVC Razor view?

Is there a way to display an SmtpClient.SendAsync() method result (success or failure) on an MVC view from a call back function?
Alexander
  • 65
  • 1
  • 6