Watch Tom Duffy add an event handler to the simple Xamarin app using C# and Visual Studio for Mac.
- [Instructor] To finish the app, we need to implement…the event handler we specified in the buttons clicked event.…So let's double-click on the XamarinExamplePage.xaml.cs file…to open it in the code editor.…So I'll expand the node and you'll find the C Sharp file…underneath the XAML file.…And just beneath the InitializeComponent call, let's add in…our say hello method.…So that doesn't return anything, it's void.…
And then sayHello is the name of the method.…And since it's an event handler, its signature…must include a reference to the source of the event.…I'm going to store that in a variable called sender.…And it also has to include an event ArgsObject…to store any event data passed along…so that means EventArgs and let's give that a variable name.…I'll just call it E.…
And I'm getting some red lines…because the EventArgs is in the system namespace…so I'm going to have to import that…by typing in using System.…And that should make the EventArgs class available to us.…Inside the say hello method,…let's create a variable for our message…
- Hybrid vs. native cross-platform apps
- Choosing an editor
- Building a Cordova app
- Building an Ionic app
- Buildin an app with the Create React Native App
- Building an app with the React Native CLI
- Building a Titanium app
- Building a Xamarin app
Skill Level Beginner
Ionic 3.0 for Mobile App Developerswith Sani Yusuf5h 43m Intermediate
React Native: Building Mobile Appswith Steven Emmerich2h 32m Intermediate
1. Intro to Cross-Platform Development
4. React Native
- 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.