Click here to Skip to main content
15,911,039 members
Home / Discussions / WPF
   

WPF

 
GeneralRe: Custom SelectedItem in ListView Pin
Pete O'Hanlon1-May-10 20:22
mvePete O'Hanlon1-May-10 20:22 
QuestionLearning WPF basics - how to create & use (and re-use) a combobox 'template' bound to CONSTRAINed SQL columns Pin
Duke Carey30-Apr-10 8:26
professionalDuke Carey30-Apr-10 8:26 
AnswerRe: Learning WPF basics - how to create & use (and re-use) a combobox 'template' bound to CONSTRAINed SQL columns Pin
Pete O'Hanlon1-May-10 9:50
mvePete O'Hanlon1-May-10 9:50 
GeneralRe: Learning WPF basics - how to create & use (and re-use) a combobox 'template' bound to CONSTRAINed SQL columns Pin
Duke Carey3-May-10 0:58
professionalDuke Carey3-May-10 0:58 
GeneralRe: Learning WPF basics - how to create & use (and re-use) a combobox 'template' bound to CONSTRAINed SQL columns Pin
Pete O'Hanlon3-May-10 2:45
mvePete O'Hanlon3-May-10 2:45 
QuestionProblem while animating Web browser Control Pin
hassan_wahpk130-Apr-10 2:20
hassan_wahpk130-Apr-10 2:20 
AnswerRe: Problem while animating Web browser Control Pin
Abhinav S30-Apr-10 5:29
Abhinav S30-Apr-10 5:29 
GeneralRe: Problem while animating Web browser Control Pin
hassan_wahpk12-May-10 18:24
hassan_wahpk12-May-10 18:24 
In following code I try to animate webbrowser control directly and also by adding it to a dockpanel. In both cases I have no success, take a look

<Window
	xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
	xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
	x:Class="MainWindow"
	x:Name="Window"
	Title="MainWindow"
	Width="640" Height="480" mc:Ignorable="d">

	<Window.Resources>
		<Storyboard x:Key="Ani1">
			<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="webB1" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)">
				<SplineDoubleKeyFrame KeyTime="00:00:00.5000000" Value="0"/>
				<SplineDoubleKeyFrame KeyTime="00:00:01" Value="1"/>
			</DoubleAnimationUsingKeyFrames>
			<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="webB1" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[1].(SkewTransform.AngleX)">
				<SplineDoubleKeyFrame KeyTime="00:00:00.5000000" Value="0"/>
				<SplineDoubleKeyFrame KeyTime="00:00:01" Value="-12"/>
				<SplineDoubleKeyFrame KeyTime="00:00:01.7000000" Value="0"/>
			</DoubleAnimationUsingKeyFrames>
		</Storyboard>
		<Storyboard x:Key="ani2">
			<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="dockPanel" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[1].(SkewTransform.AngleX)">
				<SplineDoubleKeyFrame KeyTime="00:00:00.5000000" Value="19"/>
				<SplineDoubleKeyFrame KeyTime="00:00:01" Value="0"/>
			</DoubleAnimationUsingKeyFrames>
		</Storyboard>
	</Window.Resources>
	<Window.Triggers>
		<EventTrigger RoutedEvent="FrameworkElement.Loaded"/>
	</Window.Triggers>

	<Grid x:Name="LayoutRoot">
		<Button x:Name="btn1" HorizontalAlignment="Left" Margin="17,113,0,0" VerticalAlignment="Top" Width="56" Height="27" Content="Load" Click="btn1_Click"/>
		<Button x:Name="btn2" HorizontalAlignment="Left" Margin="17,144,0,0" VerticalAlignment="Top" Width="56" Height="26" Content="Start" Click="btn2_Click"/>
		<DockPanel x:Name="dockPanel" Margin="111,93,51,68" LastChildFill="False" RenderTransformOrigin="0.5,0.5" Background="Black">
			<DockPanel.RenderTransform>
				<TransformGroup>
					<ScaleTransform/>
					<SkewTransform/>
					<RotateTransform/>
					<TranslateTransform/>
				</TransformGroup>
			</DockPanel.RenderTransform>
			<WebBrowser x:Name="webB1" Margin="0,41,0,44" Width="462" Height="200" RenderTransformOrigin="0.5,0.5" d:LayoutOverrides="VerticalAlignment">
				<WebBrowser.RenderTransform>
					<TransformGroup>
						<ScaleTransform/>
						<SkewTransform/>
						<RotateTransform/>
						<TranslateTransform/>
					</TransformGroup>
				</WebBrowser.RenderTransform>
			</WebBrowser>
		</DockPanel>
	</Grid>
</Window>


VB code to call

imports System.Windows.Media.Animation 
Class MainWindow


Private Sub btn1_Click(ByVal sender as Object, ByVal e as System.Windows.RoutedEventArgs)

 dim uri1 as new Uri("http://www.codeproject.com")
		webB1.Navigate(uri1)
		
	End Sub

	Private Sub btn2_Click(ByVal sender as Object, ByVal e as System.Windows.RoutedEventArgs)
		'TODO: Add event handler implementation here.
		Dim Lobj as Storyboard = directcast(me.Resources("ani2"), Storyboard)
		Lobj.Begin
	End Sub
End Class


Thanks
QuestionCreate Image Programtically Pin
#realJSOP29-Apr-10 9:37
professional#realJSOP29-Apr-10 9:37 
AnswerRe: Create Image Programtically Pin
Abhinav S29-Apr-10 18:27
Abhinav S29-Apr-10 18:27 
GeneralRe: Create Image Programtically Pin
#realJSOP29-Apr-10 23:48
professional#realJSOP29-Apr-10 23:48 
QuestionRe: Create Image Programtically Pin
Michel Godfroid29-Apr-10 23:34
Michel Godfroid29-Apr-10 23:34 
AnswerRe: Create Image Programtically Pin
#realJSOP29-Apr-10 23:52
professional#realJSOP29-Apr-10 23:52 
AnswerRe: Create Image Programtically Pin
Tim Yen1-May-10 3:08
Tim Yen1-May-10 3:08 
GeneralRe: Create Image Programtically Pin
#realJSOP3-May-10 2:56
professional#realJSOP3-May-10 2:56 
QuestionDisplay an Exception in Treeview with innerexception being child Pin
Troyzajac29-Apr-10 5:19
Troyzajac29-Apr-10 5:19 
AnswerRe: Display an Exception in Treeview with innerexception being child Pin
rhuiden30-Apr-10 4:10
rhuiden30-Apr-10 4:10 
QuestionBinding Selected Value to Combobox Pin
LePoulpe30329-Apr-10 4:08
LePoulpe30329-Apr-10 4:08 
AnswerRe: Binding Selected Value to Combobox Pin
Parwej Ahamad29-Apr-10 6:14
professionalParwej Ahamad29-Apr-10 6:14 
GeneralRe: Binding Selected Value to Combobox Pin
LePoulpe3032-May-10 23:28
LePoulpe3032-May-10 23:28 
QuestionDatabase Populated Menu Pin
Tripathi Swati29-Apr-10 0:53
Tripathi Swati29-Apr-10 0:53 
AnswerRe: Database Populated Menu Pin
Abhinav S29-Apr-10 18:29
Abhinav S29-Apr-10 18:29 
GeneralRe: Database Populated Menu Pin
Tripathi Swati29-Apr-10 18:42
Tripathi Swati29-Apr-10 18:42 
GeneralRe: Database Populated Menu Pin
Abhinav S29-Apr-10 19:18
Abhinav S29-Apr-10 19:18 
Questionhow can I apply textblock properties to Path??? Pin
urooj_mahmood28-Apr-10 21:50
urooj_mahmood28-Apr-10 21:50 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.