-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Microsoft.Maui.Controls.BindableObject: Warning: Value is an invalid value for Maximum #217
Comments
Here's a piece of code just in case private void UpdateGrid(List<List<string>> allData)
{
try
{
for (int i = 0; i < 10; i++)
{
var row = new List<string>();
foreach (var currencyData in allData)
{
row.Add(i < currencyData.Count ? currencyData[i] : "");
}
Trace.WriteLine($"PaginationStepper Maximum: {DataGrid.PageCountProperty.DefaultValue}");
TradeDataGrid.Clear();
TradeDataGrid.Add(row);
}
}
catch(Exception ex)
{
Trace.WriteLine(ex);
}
} |
Seems like there could be bugs in both this control and your usage. I see you set Setting an invalid page number should probably fallback to a reasonable value, instead of failing. An erroneously low value should default to 1, and an erroneously high value should default to the last page. And a hardcoded value of 1 should never fail, even when there are no records. I will review the code to ensure this is the case. Until then, I recommend just removing the |
I added these attributes just to see if the error would go away but no, tried different options but nothing worked. |
It is possible the error is not coming from the DataGrid at all. Also, the use of the square brackets to define the property names for the columns is unlikely to work. Although the error you showed seems unrelated. Make a normal collection and define the properties that way. You can also use sub-properties with a dot as the defined PropertyName. |
I'm new to MAUI.
This error keeps popping up:
Can you tell me what to do?
The text was updated successfully, but these errors were encountered: