i need a help
my app is Tab & navigation based.
in the navigation model i have a section to get input from user and store it to SQLLite thats working fine when i clicking the "save" button
prob here is once its saved i need to navigate user to the preveios level of the navigation controller (same operation like Navigation Back button).
Any ideas?
Thanks in advance
Try calling popViewControllerAnimated:
[self.navigationController popViewControllerAnimated:YES];
Related
I need to add a back button to my navigation page. I tried NavigationPage.SetHasBackButton(page, true); but it didn't work and I tried in xaml also, still does not work. Can anybody help me?
Your code isn't right. In App.xaml.cs you need to set Main page to be new NavigationPage(new ProductDetail());
Then when you navigate away from ProductDetail, you will see the back button.
Also normal page navigation will use PushAsync. Are you wanting a modal popup for your second page?
I'm using Xamarin.Forms with Prism and a Master/Detail to create a "hamburger" menu. When the app runs, I navigate to NavigationService.NavigateAsync("MyMasterDetailPage/MyNavigationPage/MainPage");
I have items in the Master flyout menu for navigating to other pages. So I tap one and navigate to MyNavigationPage/SyncPage. At this point, if I hit the back button on Android, the app closes. Instead, I'd like to navigate back to the MainPage. I tried to hook into OnNavigatedFrom of the SyncPage to force navigation back to MainPage but the app is already closing by the time that event fires.
Implement the INavigationPageOptions interface on MyNavigationPage and set ClearNavigationStackOnNavigation = false
I implemented a solution similar to what Brian suggested but had to add a check to return true if it's the first time through in order to work correctly.
I have a custom pop-up form that I want to open automatically when you open the CustTable form and I'm trying to figure out what the best way to provide security around this is.
I'd like to have a security privilege/duty/role so that it can be added/removed to user accounts who want the functionality, but there is no "menu button" that is clicked.
What's the most "native" way to open this form from code?
I've found the Global::hasMenuItemAccess() method https://msdn.microsoft.com/en-us/library/aa593278(v=ax.50).aspx
Should I just use this in code or can I change the way I open the form to call the menu item through code? Or will that just say "user does not have access"?
You should still create a menu item for the form that you want to open and use the normal way to secure the menu item with security. Then, you can launch the form using the menu item.
Args args = new Args();
;
args.record(VendTable::find("XYZ"));
new MenuFunction(MenuItemDisplayStr(VendTable),MenuItemType::Display).run(Args);
I am using Navigation View Controller in storyboard to creates different views linked together by segue link. Therefore, all the back button are automatically created.
I have tried many ways to customize that back button with other text, or just no text but still cannot.
Here are the methods I tried,
self.navigationItem.backBarButtonItem.title = #"abc";
or
self.navigationController.navigationItem.backBarButtonItem.title = #"abc";
or
self.navigationItem.title = #"abc";
Please help me this one, thank you a lot :)
You can edit the back button's title in storyboards directly. Select the appropriate ViewController that's been imbedded in a NavigationController and then:
I'm using MonoTouch and my application setup looks something like this,
NavController
-TabBarController
-NavController
-View1
This works then I click on a tab and am directed to View1. The problem is that this was performed by the tabBarController and not the navigationController. So I get no Back button. Is there a way to capture a TabItemClicked event and manually use the NavigationController to push the View1 onto the stack? So I can get a back button.
I'm hiding the TabBar once I get to View1, so at the moment, there is no way back from View1.
Hope it may help you
http://21gingerman.wordpress.com/2009/04/06/tutorial-and-sample-code-for-iphone-app-with-tab-bar-and-nav-bar/