PC SOFT

FOROS PROFESIONALES
WINDEVWEBDEV y WINDEV Mobile

Inicio → WINDEV 2024 → problem with dot net method return value Task<string>
problem with dot net method return value Task<string>
Iniciado por guest, 12,jun. 2016 17:09 - 1 respuesta
Publicado el 12,junio 2016 - 17:09
Hello Gang !

I have a problem with dot net object method.
The dot net assemblies is written in C# and compiled with visual studio 2015.

The method is

// SendCodeRequest
//
// Parameters:
// phoneNumber : UNICODE string
// Return Value:
// Task<string>

[ <Result> = ] SendCodeRequest (LOCAL phoneNumber is UNICODE string)

I know the method is working but I can't get the return Value Task<string>

Info(myobject:sendcoderequest(MyPhoneNumber)) or Trace(myobject:sendcoderequest(MyPhoneNumber)) doesnot work .
what ever i do There is error :
An element of '.NET Object' type cannot be converted to the 'string' type.


How to get returned value ??
Thanks !!
Publicado el 12,junio 2016 - 22:37
Hi

from what you are showing us, there must be a "task" class in your assembly
Declare/instantiate an object from this class, and put your result in it.

Best regards