wpf-controls

PopUp window on a specific time in WPF?

How can I create and show a popup window at a specific time in WPF? What I mean how to display the window on the side of system tray. ...

Get the minimize box click of a WPF window.

How to get the minimize box click event of a WPF window? ...

Changing "active content" security settings on WPF WebBrowser control

I'm putting together a WPF application that will allow users to view PowerPoint files through the WebBrowser control, once the files have been saved as either .MHT or .HTML. The problem is that the files contain ActiveX controls, and the WebBrowser control by default will display a warning every time I load these files, saying "To help p...

WPF button content template

I want the content of a wpf button to be left aligned I tried the following but the text is still centered inside the button. <Button > <StackPanel HorizontalAlignment="Stretch"> <TextBlock HorizontalAlignment="Left" Text="Save"/> </StackPanel> </Button> What do i do? ...

Stretching a WPF Canvas Horizontally

How do I make a Canvas Stretch fully Horizontally with variable width? This is the Parent Canvas, so it has no parents, only Children. XAML Source: it displays in blend http://resopollution.com/xaml.txt ...

Changing Label properties programmatically

The problem is that I need to change Label FontWeight and FontStyle programmatically but nothing seems to work... this is what I've tried so far: label.FontWeight = FontWeight.FromOpenTypeWeight(99); For label.FontStyle I have no idea, I got stuck here: label.FontStyle = new FontStyle(); I have no idea what to do from there on. I g...

Replace text in WPF Richtextbox.

How to replace a character in WPf richtextbox? ...

AutoComplete TextBox in WPF

Hi, Can we make textbox to autocomplete in WPF? I found a sample where a combox box is used and the traingle is removed by editing style template. Do we better solution for autocomplete textbox? Thanks in advance Sharath ...

Setting the tag member of a ListBoxItem inside a datatemplate?

Hi, How would I be able to set the tag member of a ListBoxItem inside a datatemplate? I am databinding a ListBox and I am trying to add information to the ListBoxItem.Tag from my DataContext. I am using A DataTemplate to display the ListBoxItem. ...

Customise WPF "Slider" control to slide on a path

What would be the best way to get a slider control that slides on a path. At the moment I think the path I will use is a half circle arc. But I may need to change this later (or create other sliders with different paths. So I need to take that into account. Would it be best to start with the default Slider control and modify/extend it? ...

.NET WPF - System.Windows.Controls.TreeView Adding SubItems

After you have added Items to the "root" level of a System.Windows.Controls.TreeView, what is the proper way to add in "subitems" by name? System.Windows.Controls.TreeView.Items <-- doesn't seem to have a Find() or [] by name. UPDATE: Oh, wait... is it TreeView.FindName() ? Actually looks like FindName won't work because it returns ...

RichTextBox (WPF) does not have string property "Text"

Hi, I am trying to set/get the text of my RichTextBox, but Text is not among list of its properties when I want to get test.Text... I am using code behind in C# (.net framework 3.5 SP1) RichTextBox test = new RichTextBox(); cannot have test.Text(?) Do you know how come it can be possible ? thanks, ...

WPF - TreeView.FindName() problem

How come TreeView.FindName() can find things added to the Xaml doc at compile time but not dynamically added at runtime? ...

What is the difference between modifying a control by altering the control template and adding sub controls

Hi, I am new to WPF and I have a doubt in modifying a control. I came to know that one can modify a control by changing its Control Template. i.e., <Button> <Button.Template> <ControlTemplate> ... </ControlTemplate> </Button.Template> </Button> Also we can edit a control utilizing the Content Model. i.e., <Butto...

wpf toolkit data grid

hello i'm building a wpf app with data grids, the pattern is model view view model. all og my screens contains a contentcontrol, and i just assign him the view model, that have a suitable data template, anyway, my problem is with combo box column, the data context is the presented entity, and i need it to be the view model. whats the ...

Zoom in/out Treeview Items in WPF

hi, Can we zoom in/out the treeview items on Mouse hover ? Thanks Sharath ...

Embed Icon in WPF application.

I am using an icon in my application in two situations. In XAML as an Image for the Button using DynamicResource. In C# as NotifyIcon this.notifyIcon.Icon = new SystemDrawing.Icon("..//..//Shutdown.ico" ); My problem is if I delete the image the application not working. How can I bind the image with the exe file so that the applic...

IXAmlTypeResolver.Resolve failing in Blend

I'm attempting to do some type resolution inside of a WPF Markup Extension using the same namespace:StaticType.Property syntax that StaticExtension uses. The extension works fine at runtime and also in the Visual Studio designer, but it fails in Expression Blend. After some debugging I figured out that the failure occurs in a call to IXa...

WPF: How do I perform custom rendering of items in List or Grid?

With Adobe Flex I would create a custom ItemRenderer to change the display of items in a grid. This executes some code that overrides how the grid control renders items. How do I do this with WPF? What are the performance implications with the techniques available? My initial aim is to display an icon, a title, and a description. Ideall...

How to rotate Items in a WFP Listbox style ?

What i want to do is make a wpf listbox photo album for one my college project and i have come to a point when im really stuck. i simply need to design a data template/ listbox style so it will look like a stack jumbled of photos , Ie the top one being the item under focus (selected item) i drew a quick crude drawing in paint to help...