<UserControl x:Class="MyApplication.frmMaptip" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml"> <Grid> <StackPanel Background="White"> <Border BorderBrush="Black" BorderThickness="2"> <WebBrowser Height="170" Width="400" Name="webBrowser1" VerticalAlignment="Top"/> <Button Height="25" Width="75" Content="Test" Click="Button_Click"/> </Border> </StackPanel> </Grid> </UserControl>
private void Button_Click(object sender, RoutedEventArgs e) { this.webBrowser1.Navigate("http://www.google.com"); }
public partial class usercontrolMaptip : UserControl { public usercontrolMaptip(); { InitializeComponent(); Loaded += usercontrolMaptip_Loaded; } private void usercontrolMaptip_Loaded(object sender, RoutedEventArgs e) { var popParent = Parent as Popup; if (popParent == null) return; popParent.AllowsTransparency = false; popParent.IsOpen = false; Loaded -= IdentifyMapTips_Loaded; }
Signed in members can post, follow updates, and more. New here? Register a free account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.