Disable back button text - ios

I want to disable the back button text in Xamarin iOS,
along with the button itself. I already disabled the back button itself but the text is left.
Does anyone know of any way to disabling the text as well?
Thanks

You can accomplish this in two ways:
NavigationItem.SetHidesBackButton(true, false);
or
NavigationItem.BackBarButtonItem = null;
If you use the second solution, then you would have to recreate the button if you ever want to make it visible again.

With Navigation Page:-
NavigationPage.SetBackButtonTitle(this, ""); //Empty string as title
or hide the Back button with:
NavigationPage.SetHasBackButton(this, false);

Related

Show a popup from a popup in DNN

In DNN is it possible to navigate to a different popup control from another popup control?
I have a pop up edit control with some buttons. When I click on one of the buttons I would like to show a different edit control in the pop up window.
I have tried using this code in the button's click handler:
Response.Redirect(EditUrl("", "", "MyControlKey"))
but when I click the button Firefox shows a "Corrupted Content Error" in the pop up window.
Can this be made to work, and if so how?
Never mind I figured it out. This seems to do what I want:
Dim url = DotNetNuke.Common.NavigateURL("MyControlKey", $"mid={ModuleId}", "popUp=true")
Response.Redirect(url)

How to disable isEnable and isUserInteraction attributes but keep cursor show in UITextField?

I have a custom framework for UITextField. For now, I want to disable two attribute as the question above but still keep the cursor show in my custom textfield. I already disable the keyboard with set the inputView = UIView(), and that successful for hide the keyboard even show the cursor inside textField.
My goal is disable both attributes like above or another for can not Select All action from my textField, but still keep the cursor available anytime.
Hope to hear the ideas from you guys. Thank a lot!

Removing back arrow in navigation bar keeping back button title

I have xamarin forms ios application,where I need to remove the back arrow in the navigation bar but the title should be displayed and when user clicks on on that back button title it should navigate to previous view.
I tried using `
NavigationPage.SetBackButtonTitle(this, "Cancel");
NavigationPage.SetHasBackButton(this, false);
But the back arrow is still displaying,is there any why to have only the text Cancel without <symbol?
I solved my issue by adding a custom renderer as follows
public override void ViewWillAppear(bool animated)
{
base.ViewWillAppear(animated);
this.NavigationController.TopViewController.NavigationItem.LeftBarButtonItem =new UIBarButtonItem(“Cancel”, UIBarButtonItemStyle.Plain, (sender, args) => { });
}
In your AppDelegate.cs file, in the FinishedLaunching method add these lines:
UINavigationBar.Appearance.BackIndicatorImage = new UIImage();
UINavigationBar.Appearance.BackIndicatorTransitionMaskImage = new UIImage();
This will however, remove it for every page. If you want it for just one page I would suggest like EvZ already mentioned: use a modal page or find another way.
Another way is to set the above lines to null which will restore the normal arrow. But this would mean implementing a custom renderer, dependency service or similar.
Remove navigation-bar and use image/header on navigation place and write into image/Header into navigation title...
image onclick event into write back command

Change ToolBar Title dynamically on click events in Fragment on Xamarin android?

First let me explain something, so you guys can understand better my problem:
I'm using Toolbar and i have a Fragment called Location Fragment where i have 6 floationg action button vertically .
When you click on one of the floating action button some action like geofence,live tracking,current location etc are performed on the same map fragment.
So my problem is that when i click any of the floation action button ,like when i click geo-fencing floation action button the title on the tool bar should change with the geofence title..In this way for all the Floating action button the title of toolbar should change. in my case the title of the tool bar is not changing .
I have tried to use setTitle or this.Activity.Title="Geo-fence" on the click method of Floating action button,but still it remains same title .
Change ToolBar Title dynamically on click events in Fragment
In your Fragment, add the following code in your click events :
((AppCompatActivity)Activity).SupportActionBar.SetTitle(Resource.String.YourTitle);
this.SupportActionBar.Title = "Your Title";

How to disable selection of bar char?

I have implemented a bar chart and I would like to move to a more specific on click on that bar chart. for that I am using "ChartViewDelegate(Chartviewselected)" it is working fine. but issue is first time when I select bar chart it goes smothly to next screen. but when come back on that screen selected bar shows selected default, when click on that bar again then it gets unselected. because of that chartview delegate(chartview selected) method not called. So I want to disable default selection of bar chart. is there any property to disable selection of bar chart?
Use dataSet.highlightEnabled = false
When coming back to the screen try calling:
lineview.delegate!.chartValueNothingSelected!(lineview)
According to ChartViewBase.swift:
// Called when nothing has been selected or an "un-select" has been made.
#objc optional func chartValueNothingSelected(_ chartView: ChartViewBase)
If you need to removed highlighted Bar while come back from Previous screen put below code in viewWillApper() it will remove highlighted Bar.
//Manyally Remove Selected Bar
[self.chartView highlightValues:NULL];
Hope this will helps!

Resources