Opening a page by code in Xamarin.iOS -


below code navigates page in swift.
how can run code in xamarin.ios ?

let storyboard : uistoryboard = uistoryboard(name: "main", bundle:nil)  let nextviewcontroller = storyboard.instantiateviewcontrollerwithidentifier("nextview") nextviewcontroller self.presentviewcontroller(nextviewcontroller, animated:true, completion:nil) 

here's translation:

var storyboard = uistoryboard.fromname("main",null); var nextviewcontroller = storyboard.instantiateviewcontroller("nextview") nextviewcontroller; presentviewcontroller(nextviewcontroller, true, null); 

or if using async await:

var storyboard = uistoryboard.fromname("main",null); var nextviewcontroller = storyboard.instantiateviewcontroller("nextview") nextviewcontroller; await presentviewcontrollerasync(nextviewcontroller, true); 

Comments

Popular posts from this blog

'hasOwnProperty' in javascript -

How to put a lock and transaction on table using spring 4 or above using jdbcTemplate and annotations like @Transactional? -

How to understand 2 main() functions after using uftrace to profile the C++ program? -