29.12.2014 Views

Android - SecureAuth

Android - SecureAuth

Android - SecureAuth

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Launch an External Browser<br />

<strong>Android</strong>:<br />

@Overrideprotected void onCreate(Bundle savedInstanceState) {<br />

{super.onCreate(savedInstanceState);<br />

…<br />

Button button = (Button)<br />

findViewById(R.id.login_button); button.setOnClickListener(new OnClickListener()<br />

{ @Override<br />

public void onClick(View v) {<br />

Intent i = new Intent(Intent.ACTION_VIEW,<br />

"https://secureauth.mycompany.com/<strong>SecureAuth</strong>1/");<br />

} }); …}<br />

startActivity(i);<br />

iOS:<br />

24<br />

- (IBAction) startLogin: (id)sender<br />

{<br />

}<br />

NSURL *url = [NSURL<br />

URLWithString:@"https://secureauth.mycompany.com/<strong>SecureAuth</strong>1/"];<br />

[[UIApplication sharedApplication] openURL:url];

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!