UploadStringCompletedEventArgs.Result Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets the server reply to a string upload operation that is started by calling an UploadStringAsync method.
public:
property System::String ^ Result { System::String ^ get(); };
public string Result { get; }
member this.Result : string
Public ReadOnly Property Result As String
Property Value
A Byte array that contains the server reply.
Examples
The following code example displays the value of this property.
void UploadStringCallback2( Object^ /*sender*/, UploadStringCompletedEventArgs^ e )
{
String^ reply = dynamic_cast<String^>(e->Result);
Console::WriteLine( reply );
}
private static void UploadStringCallback2(Object sender, UploadStringCompletedEventArgs e)
{
string reply = (string)e.Result;
Console.WriteLine(reply);
}
Private Shared Sub UploadStringCallback2(ByVal sender As Object, ByVal e As UploadStringCompletedEventArgs)
Dim reply As String = CStr(e.Result)
Console.WriteLine(reply)
End Sub
Remarks
You should check the Error and Cancelled properties to determine whether the upload completed. If the Error property's value is an Exception object or the Cancelled property's value is true
, the asynchronous operation did not complete correctly and the Result property's value will not be valid.
Applies to
Feedback
https://aka.ms/ContentUserFeedback.
Kommer snart: I hele 2024 udfaser vi GitHub-problemer som feedbackmekanisme for indhold og erstatter det med et nyt feedbacksystem. Du kan få flere oplysninger under:Indsend og få vist feedback om