Learn how to bind properties of a control to data in a model or class that you create and set as the BindingContext for the page.
- [Instructor] We got our layout…looking okay for our product detail,…but we're using static data.…And what we really wanna do at runtime…is display the data from our API that we're pulling back.…And so rather than using a static text like…product name here, we wanna bind that text property…to a value on our product object.…Remember, in our solution back here…we had our product.…We've got a variety of properties here…that we wanna display and some that we won't.…So we have the name, the description.…
Then we have a few things related to the image.…You'll notice I have a string for the image,…and that's the URI I get back from the API.…But I also have a URI typed property that wraps that…where I take that string and I create a URI from it.…You'll see why I need that as we get into the binding.…So for the text, instead of putting static values in there,…I'm gonna use the curly braces again and type binding.…Now these curly braces are extensions to the markup,…where we're not just putting static text in here,…we're giving it different kinds of extensions.…
- Creating a Xamarin.Forms solution
- Navigating between pages
- Screen layouts and controls in Xamarin.Forms
- Data binding
- Adding style to a control
- Using a Xamarin.Essentials package
- Embedding native controls in your shared forms
- Writing custom renderers
Skill Level Beginner
Xamarin Development: Authentication and Identitywith Matt Milner1h 32m Intermediate
What you should know1m 21s
2. Layout and Controls
3. Native Platform Integration
4. Native Controls and Renderers
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.