anitha T

anitha T

  • NA
  • 73
  • 8k

How to use web view in tappedlink

Sep 18 2017 4:09 AM
CustomUlineLabel lblTandCLink = new CustomUlineLabel()
{
Text = "terms of use",
ShallUnderLine = true,
TextColor = AppGlobalVariables.black,
//FontSize = Device.OnPlatform(height * 2, height * 2.5, height * 3),
//StartIndex = 47,
//EndIndex = 59,
//NoOfChar = 12,
////HeightRequest = height * 6,
//Margin = new Thickness(0, Device.OnPlatform(height * 0, height * 1.25, height * 2), 0, 0),
VerticalTextAlignment = TextAlignment.Center,
HorizontalOptions = LayoutOptions.Center,
VerticalOptions = LayoutOptions.Center
};
var webView = new WebView(){Source = new UrlWebViewSource{Url = Constants.termsofuseURL,},};
var tapLblTandCLink = new TapGestureRecognizer();
tapLblTandCLink.Tapped += (s, e) =>
{
//webView.Source = Constants.termsofuseURL;
Device.OpenUri(new Uri(webView.ToString()));
//Device.OpenUri(new Uri(Constants.termsofuseURL));
};
lblTandCLink.GestureRecognizers.Add(tapLblTandCLink);
 
 
 
Can we do this ?