Command<T>
Wisej.Web.Command<T>
Namespace: Wisej.Web
Assembly: Wisej.Framework (3.0.0.0)
Implements the ICommand interface wrapping execute and canExecute actions.
You can use this class to wrap custom commands to bind to controls that implement the ICommandSource interface and need to access the typed data source records. In the snippet below, the CommandDemoViewModel class derives from BindingList and allows the commands to directly interact with the typed DataItem property.
Now you can use data binding or a code assignment to connect the view model's Add command to a button's Command property.
Parameters
Name | Description |
---|---|
T | The Type of the data passed to the actions. |
Constructors
Command(execute, canExecute)
![](https://docs.wisej.com/~gitbook/image?url=https%3A%2F%2F2647619304-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FHOivImCoV8KSJbQyp6QI%252Fuploads%252Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%252Finstance.png%3Falt%3Dmedia&width=300&dpr=4&quality=100&sign=d2776d01&sv=1)
Name | Type | Description |
---|---|---|
execute | ||
canExecute |
Implements
Name | Description |
---|---|
Defines a command that can be used for data binding. |
Last updated