This recipe is by far the book's shortest and simplest recipe. We are going to illustrate how to open the device's web browser and load a web page.
Open PlayStation Mobile Studio and create a new project. You can download the full sources as Ch9_Example1
.
Open AppMain.cs
and replace the code with the following:
using System; using Sce.PlayStation.Core; using Sce.PlayStation.Core.Environment; namespace Ch9_Example1 { public class AppMain { public static void Main (string[] args) { var action = Shell.Action.BrowserAction(@"http://www.gamefromscratch.com"); Shell.Execute(ref action); } } }
Run the application and you should see the following screenshot:
A web browser will open on the user's device and load the world's greatest website!