Skip to content
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

MVVM Binding in MainPage #4

Open
jbdioli opened this issue Jun 19, 2024 · 0 comments
Open

MVVM Binding in MainPage #4

jbdioli opened this issue Jun 19, 2024 · 0 comments

Comments

@jbdioli
Copy link

jbdioli commented Jun 19, 2024

Hello

If I'm using the MVVM pattern, MainpageViewModel, in the MainPage, then I want to bind the text in EntryMaterial, it doesn't work, it gives an error: "No property, BindableProperty, or event found for "Text", or mismatching type between value and property."

in the MainPage.xaml:

<input:EntryMaterial x:Name="MEEntry" PlaceholderLabel="Firstname ..." Text="{Binding Firstname}"/>

in the MainpageViewModel:

public partial class MainpageViewModel : BaseViewModel { [ObservableProperty] private string _firstname = "John"; }

Thank you so much for your help :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant