I have generated Master/Details pages, however i now get this compile error:
error CS1061: 'DataGridRowMouseEventArgs' does not contain a definition for 'rID' and no accessible extension method 'rID' accepting a first argument of type 'DataGridRowMouseEventArgs' could be found (are you missing a using directive or an assembly reference?)
I'm getting the same error. Debugging isn't the issue. When you put in an attempted fix, Radzen replaces the code when you attempt to run the project.
Here is the error I'm receiving:
|Error|CS1061|'DataGridRowMouseEventArgs' does not contain a definition for 'Id' and no accessible extension method 'Id' accepting a first argument of type 'DataGridRowMouseEventArgs' could be found (are you missing a using directive or an assembly reference?)|VendorSignInLog|C:\Development Projects\Blazor\VendorSignInLog\server\Pages\Visit.razor.designer.cs
Here is the code from VS:
protected async System.Threading.Tasks.Task Grid0RowDoubleClick(DataGridRowMouseEventArgs<VendorSignInLog.Models.ByVendorSil.Visit> args)
{
await DialogService.OpenAsync("Edit Visit", new Dictionary<string, object>() { {"Id", args.Id} });
}
Has anyone solved this? I'm kind of dead in the water with my project right now.
DataGridRowMouseEventArgs is an object that does not include "Id" as a property and that is why you get the error.
However, i see what you are trying to do. If you want to access the object on the row you clicked on you have to use "args.Data" and in your case you want to change "args.Id" to "args.Data.Id" if you have a property on the object that is called "Id"
Hi there, I run Blazor Web Assembly App on .NET5 and Radzen 2.63.7.
If I use "RowDoubleClick" event on a DataGrid to open the Edit-Dialog for ${event.id}, I get the same error as described above:
error CS1061: 'DataGridRowMouseEventArgs' does not contain a definition for 'id' and no accessible extension method 'id' accepting a first argument of type 'DataGridRowMouseEventArgs' could be found (are you missing a using directive or an assembly reference?) [PROJECT.csproj]
If I change ${event.id} to ${event.Data.id} as described above, it works perfectly.
Shouldn´t this work "out-of-the-box"?
Thanks, but it doesn´t work out-of-the-box if I create a simple CRUD-Page:
at first, "RowSelect" event is prefilled
if I choose to use "RowDoubleClick", then I expect radzen to set the parameter value "correctly", but the value is set to ${event.id} instead of ${event.Data.id}