Windows Application Development Cookbook

Discover over 125 solution-based recipes to help you build applications for smartphones, tablets, and desktops

Windows Application Development Cookbook

This ebook is included in a Mapt subscription
Marcin Jamro

1 customer reviews
Discover over 125 solution-based recipes to help you build applications for smartphones, tablets, and desktops
$0.00
$39.99
$49.99
$29.99p/m after trial
RRP $39.99
RRP $49.99
Subscription
eBook
Print + eBook
Start 30 Day Trial
Subscribe and access every Packt eBook & Video.
 
  • 4,000+ eBooks & Videos
  • 40+ New titles a month
  • 1 Free eBook/Video to keep every month
Start Free Trial
 
Preview in Mapt

Book Details

ISBN 139781786467720
Paperback512 pages

Book Description

Need to ensure you can always create the best Windows apps regardless of platform? What you need are solutions to the biggest issues you can face, so you can always ensure you’re making the right choices and creating the best apps you can.

The book starts with recipes that will help you set up the integrated development environment before you go ahead and design the user interface. You will learn how to use the MVVM design pattern together with data binding, as well as how to work with data in different file formats.

Moving on, you will explore techniques to add animations and graphics to your application, and enable your solution to work with multimedia content.

You will also see how to use sensors, such as an accelerometer and a compass, as well as obtain the current GPS location. You will make your application ready to work with Internet-based scenarios, such as composing e-mails or downloading files, before finally testing the project and submitting it to the Windows Store.

By the end of the book, you will have a market-ready application compatible across different Windows devices, including smartphones, tablets, and desktops.

Table of Contents

Chapter 1: Getting Started
Introduction
Setting up the IDE
Arranging windows
Creating a new project
Running the application
Adding a new page
Placing a control
Handling events
Navigating between pages
Passing data between pages
Handling the back button
Changing a default page
Modifying the back stack
Utilizing additional features of the emulator
Breakpoints-based debugging
Step-by-step debugging
Executing code while debugging
Logging information while debugging
Monitoring the CPU and memory usage
Chapter 2: Designing a User Interface
Introduction
Adding a button
Adding a text block
Adding a textbox
Adding a password box
Adding a checkbox
Adding a combobox
Adding a listbox
Adding an image
Adding controls programmatically
Arranging controls vertically
Arranging controls horizontally
Arranging controls in a scrollable view
Defining a page-limited style
Defining a global style
Applying styles programmatically
Arranging controls in a grid
Arranging controls in absolute positions
Choosing date and time
Adding icons to app bars
Creating and using a user control
Presenting a message dialog
Adjusting design based on the device type
Localizing content in XAML
Localizing content programmatically
Forcing the current language
Chapter 3: MVVM and Data Binding
Introduction
Creating the view model for a page
Introducing bindings and commands
Binding a value to a textbox
Binding with a value converter
Using value converters with parameters
Showing a progress bar during calculations
Binding a collection to a list view
Binding a collection to a grid view
Binding a collection to a combobox
Binding a collection to a hub
Chapter 4: Data Storage
Introduction
Creating a directory
Reading a structure of directories
Creating a file
Iterating through files
Renaming a directory
Renaming a file
Removing a directory
Removing a file
Writing a text file
Reading a text file
Writing an XML file
Reading an XML file
Writing a JSON file
Reading a JSON file
Writing a binary file
Reading a binary file
Creating a SQLite database and tables
Storing data in a SQLite database
Selecting data from a SQLite database
Updating data in a SQLite database
Removing data from a SQLite database
Chapter 5: Animations and Graphics
Introduction
Animating the showing of controls
Using animation to hide controls
Adding animation to show the collection of items
Animating the repositioning of items' collection
Animating the color of an element
Animating the size of an element
Animating the position of an element
Animating the rotation of an element
Animating the font size of an element
Drawing shapes programmatically
Handling the tap touch event
Handling the pinch touch event
Handling the rotate touch event
Handling the pinch and rotate touch events
Rendering 3D graphics
Chapter 6: Multimedia
Introduction
Playing a movie clip
Playing an audio file
Presenting a collection of photos
Preparing a photo album with captions
Modifying an image
Converting an image into grayscale
Recoloring an image
Choosing a file to open
Choosing a file to save
Taking an image from a camera
Recording a movie from a camera
Scanning a QR code
Synthesizing speech
Recognizing speech
Chapter 7: Built-in Sensors
Introduction
Detecting motion using an accelerometer
Reading data from a compass
Obtaining the orientation of a device
Reading data from a light sensor
Launching vibrations
Reading NFC tags
Obtaining the current GPS location
Disabling switching off the screen
Chapter 8: Internet-based Scenarios
Introduction
Opening a website in a default browser
Presenting a website within a page
Composing an e-mail message
Starting a phone call
Launching a Skype call
Opening a map in an external application
Showing a map within a page
Drawing icons, polylines, and polygons on a map
Adding a custom marker to a map
Getting the coordinates of a clicked point on a map
Launching GPS-based navigation
Calling API methods
Downloading a file from the Internet
Chapter 9: Testing and Submission
Introduction
Creating a unit test
Running a set of tests
Adding a project to the Windows Dev Center
Associating an application with the store
Adjusting the manifest file
Obtaining a map token
Receiving push notifications
Preparing files for submission
Submitting the application
Updating the application
Generating promotional codes
Browsing reviews and ratings
Analyzing acquisitions

What You Will Learn

  • Start developing universal applications for Windows 10
  • Design user interface in the XAML language
  • Use the MVVM design pattern with data binding
  • Store data in files and in a database
  • Use multimedia content and animations 
  • Capture data from built-in sensors
  • Handle various Internet-based scenarios
  • Test the application and submit it to the Windows Store

Authors

Table of Contents

Chapter 1: Getting Started
Introduction
Setting up the IDE
Arranging windows
Creating a new project
Running the application
Adding a new page
Placing a control
Handling events
Navigating between pages
Passing data between pages
Handling the back button
Changing a default page
Modifying the back stack
Utilizing additional features of the emulator
Breakpoints-based debugging
Step-by-step debugging
Executing code while debugging
Logging information while debugging
Monitoring the CPU and memory usage
Chapter 2: Designing a User Interface
Introduction
Adding a button
Adding a text block
Adding a textbox
Adding a password box
Adding a checkbox
Adding a combobox
Adding a listbox
Adding an image
Adding controls programmatically
Arranging controls vertically
Arranging controls horizontally
Arranging controls in a scrollable view
Defining a page-limited style
Defining a global style
Applying styles programmatically
Arranging controls in a grid
Arranging controls in absolute positions
Choosing date and time
Adding icons to app bars
Creating and using a user control
Presenting a message dialog
Adjusting design based on the device type
Localizing content in XAML
Localizing content programmatically
Forcing the current language
Chapter 3: MVVM and Data Binding
Introduction
Creating the view model for a page
Introducing bindings and commands
Binding a value to a textbox
Binding with a value converter
Using value converters with parameters
Showing a progress bar during calculations
Binding a collection to a list view
Binding a collection to a grid view
Binding a collection to a combobox
Binding a collection to a hub
Chapter 4: Data Storage
Introduction
Creating a directory
Reading a structure of directories
Creating a file
Iterating through files
Renaming a directory
Renaming a file
Removing a directory
Removing a file
Writing a text file
Reading a text file
Writing an XML file
Reading an XML file
Writing a JSON file
Reading a JSON file
Writing a binary file
Reading a binary file
Creating a SQLite database and tables
Storing data in a SQLite database
Selecting data from a SQLite database
Updating data in a SQLite database
Removing data from a SQLite database
Chapter 5: Animations and Graphics
Introduction
Animating the showing of controls
Using animation to hide controls
Adding animation to show the collection of items
Animating the repositioning of items' collection
Animating the color of an element
Animating the size of an element
Animating the position of an element
Animating the rotation of an element
Animating the font size of an element
Drawing shapes programmatically
Handling the tap touch event
Handling the pinch touch event
Handling the rotate touch event
Handling the pinch and rotate touch events
Rendering 3D graphics
Chapter 6: Multimedia
Introduction
Playing a movie clip
Playing an audio file
Presenting a collection of photos
Preparing a photo album with captions
Modifying an image
Converting an image into grayscale
Recoloring an image
Choosing a file to open
Choosing a file to save
Taking an image from a camera
Recording a movie from a camera
Scanning a QR code
Synthesizing speech
Recognizing speech
Chapter 7: Built-in Sensors
Introduction
Detecting motion using an accelerometer
Reading data from a compass
Obtaining the orientation of a device
Reading data from a light sensor
Launching vibrations
Reading NFC tags
Obtaining the current GPS location
Disabling switching off the screen
Chapter 8: Internet-based Scenarios
Introduction
Opening a website in a default browser
Presenting a website within a page
Composing an e-mail message
Starting a phone call
Launching a Skype call
Opening a map in an external application
Showing a map within a page
Drawing icons, polylines, and polygons on a map
Adding a custom marker to a map
Getting the coordinates of a clicked point on a map
Launching GPS-based navigation
Calling API methods
Downloading a file from the Internet
Chapter 9: Testing and Submission
Introduction
Creating a unit test
Running a set of tests
Adding a project to the Windows Dev Center
Associating an application with the store
Adjusting the manifest file
Obtaining a map token
Receiving push notifications
Preparing files for submission
Submitting the application
Updating the application
Generating promotional codes
Browsing reviews and ratings
Analyzing acquisitions

Book Details

ISBN 139781786467720
Paperback512 pages
Read More
From 1 reviews

Read More Reviews