hello,
i have a wpf control that i'm developing.
this control contains and encapsulate another control.
i want to expose a property of the inner control to the window that consumes the control.
i also want the inner control to perform logic when this property changed.
any suggestions?
...
Hello, I am trying to get a selected text in a TextBox embedded in a listView. This seems so easy, but I couldn't really find a elegant solution.
When I click on "Create Rule" menu item, I want to get the TextBox in which the menu item resides.
I appreciate any help! I spent way too long of my time on this...
...
...
Using Expression Blend, I am trying to create an interface where the tabs are on the left, and the display area is on the right. It would give more of the illusion of buttons on the left.
I tried adding the SimpleTabControl with a Fill layout, and setting the TabStripPlacement to Left. However this gives me a control which has 2 tabs st...
I’m having the following issue with WPF Combo Box:
XAML:
<Window.Resources>
<ResourceDictionary>
<DataTemplate DataType="{x:Type this:Data}">
<ComboBox IsTextSearchEnabled="False" IsEditable="True"
Text="{Binding Value}" ItemsSource="{Binding Menu}"/>
</DataTemplate>
</ResourceDictionary>
</Window.R...
How Many type of gradient brushes are available like LinearGradientBrush, SolidColorBrush?
and when we create a GradientStop how the offset works?
LinearGradientBrush LGB = new LinearGradientBrush();
LGB.StartPoint = new Point(0, 0);
LGB.EndPoint = new Point(0, 1);
LGB.GradientStops.Add(new GradientStop(C...
What is the difference between StaticResources and DynamicResources in WPF?
EDIT :
This code in XAML file :
<ComboBox Canvas.Left="14" Style="{StaticResource ComboBoxStyle}"
Canvas.Top="137" Height="33" Name="cmbItem" Width="170"
SelectionChanged="cmbItem_SelectionChanged">
<ComboBoxItem>Name</ComboBoxItem>
...
In this example property
Data=
M150.655,
39.109L10.407,
53.785L0.602,
1.309l158.026-0.806L150.655,
39.109z
How this "Data" property works? and use of these 5 values?
<
Style x:Key="ButtonStyler"
TargetType="{x:Type Button}">
<Setter Property="Cursor"
Value="Hand" />
<Setter Property="Template">
<Setter.Value>
<Con...
I'm making a simple log viewer which is composed of a big TextBox which shows the file, and a DispatchTimer that updates the TextBox from time to time by setting its Text property.
Whenever the focus is set to the TextBox, it keeps automatically scrolling to the place where the cursor is, even when I'm explicitly issue ScrollToEnd() on ...
I'd like to design a custom control which can be used as a container like other Layout controls. I want this control to have a dependency property named Header which can display header for this control. Basic intention is to imitate looks of portlet control available in Sharepoint etc. with configurable headers.
Any links, suggestions, ...
I used XamlPadX to copy the defaultstyle of the ComboBox and pasted it into my app ressources.
Now after that I cannot open the combobox anymore. If I click on the dropdown button, nothing happens.
Another thing is bugging me. Altough the app compiles and runs, the designer shows me an error on the following line:
<ComboBox Name="modi...
How can i get full union bounding box of control with all of its descendant controls, with out display full control,
For example i have a panel in which i am displaying the child item. when panel have control that are visible
VisualTreeHelper.GetDescendantBounds(myPanel);
return the desired result,
but if some items are not visible d...
Hello,
Given the following code:
<Window x:Class="WpfApplication76.Window1"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:col="clr-namespace:System.Collections;assembly=mscorlib"
Title="Window1" Height="300" Width="300">
<Window.Resour...
I have a listbox that uses a UserControl as the item template. Inside the UserControl, I have an image (an X) that when clicked, sends out event to remove the UserControl(listitem) from the listbox.
Is there a way to prevent the listbox from selecting that item when a user clicks on the image but still allows listitem selection for eve...
Is silverlight can be use in wpf windows application?
Some slight confusion about it, what benefits of silverlight may be taken in wpf windows application?
Is there any licensing required for silverlight developement and deployment?
...
How can use the WebBrowser control in WPF to navigate using Search engine uri and input key?
For Example if I have the following function
private void Search( Uri uri, string keyword )
{
}
How can I concatnate the Uri and keyword sucha as Uri = www.google.com and Keyword = WPF.
I want the search result of 'WPF' in window?
...
I've been busy working on a program that can solve Minesweeper puzzles (for no other reason than I think it's fun). When it comes down to the UI, though, I greatly dislike the idea of instantiating over a hundred of the same control, one per cell. Should I create a custom control that handles all of its drawing and input itself? What ...
I am trying to make a custom control in WPF. I want it to simulate the behavior of a LED that can blink.
There are three states to the control: On, Off, and Blinking.
I know how to set On and Off through the code behind, but this WPF animation stuff is just driving me nuts!!!! I cannot get anything to animate whatsoever. The plan is...
I want to play gif recurrsivley file using MediaElement. Is there any inbuild property like (repeat or any other) to play files non stop ?
I have played in repeat mode using following code.
objMediaPlayer.Source=new System.Uri("XXX.gif");
objMediaPlayer.LoadedBehavior= MediaState.Manual;
objMediaPlayer.MediaEnded+=new RoutedEventHa...
The code I'm working on is part of a WPF application that should display a set of stacks of playing cards that the user can interact with. So there's three UserControls I'm working with:
MainControl
CardStackControl
CardControl
In MainControl.xaml:
<StackPanel
Grid.Row="0"
Orientation="Horizontal">
<Ite...
How to make a floating icon equal to that of Babylon, which is in the top-center of the screen and when the User puts de mouse over it moves? It is possible to make a wpf animation together? Can I make an animation when the WPF User puts the mouse? It would be perfect ...
...