Skip to main content

FileSystemCommandResult.GetClientCommandResult() Method

Gets the command’s execution result that will be send to the client.

Namespace: DevExtreme.AspNet.Mvc.FileManagement

Assembly: DevExtreme.AspNet.Core.dll

Declaration

public object GetClientCommandResult()

Returns

Type Description
Object

The command result.

Remarks

The command result format:

{
  success,
  errorId,
  result
};

Where:

  • success - Specifies whether the command is processed successfully.

  • result - The command’s result.

  • errorId - The error code. All error codes are stored in the FileSystemErrorCode enumeration class.

The following example illustrates how to use the GetClientCommandResult method.

public class FileManagerApiController : Controller {
    public object FileSystem(FileSystemCommand command, string arguments) {      
        var result = processor.Execute(command, arguments);
        return Ok(result.GetClientCommandResult());
        //...
    }
}

Concepts

Online Demo

Online Example

See Also