Well it's not really very dynamic, at least it won't change at runtime.
The idea is I have buttons and each one has a unique image ( icon 32x32 ). The buttons all share a style where I mess with the ControlTemplate. So each image also has 2 colors one normal and another when I mouse over.
I noticed that when I declare the source path f...
I'm trying to deploy a desktop application written on WPF 4.0 that uses SQLite through Entity Framework. So i've changed .config file (absolute path to db -> relative) and copied database file itself to app's directory. It seems to be working fine, but on other PC it's throwing an error during runtime. Supplying System.Data.SQLite.dll an...
Whilst playing around with resources in my visual studio 10 project, I came across a build action called "Splash Screen", which led me to find this article on the neat splash screen capabilities of WPF.
Hunting around, I found this MSDN article on making a splash screen in Windows Forms, but it's a different type of approach: rather tha...
I have some shared styles which define how my DataGrids look and i keep them in Styles.xaml
I added a settings page, that will let the user change some of the colors. On that page, I have a sample grid (which automatically looks like the other grids thanks to shared resource styles). On that page, a user can use a color picker, to modi...
Hello friends. I want do something like this.
<Style TargetType="{x:Type ListBoxItem}" >
<Setter Property="Style">
<Setter.Value>
<Border Style="{StaticResource BorderStyle}" Width="200" >
</Border>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="BorderStyle" TargetTy...
I am trying to get 2 buttons to be beside each other and evenly take up the entire row underneath the "main area".
I seem to be missing something
Thanks!
<Grid Background="Transparent" Margin="0" Opacity=".8">
<Border Name="MaskBorder" Grid.RowSpan="3">
<Border Name="MainBorder" Background="Aqua">
<Grid>
...
Hi
I'm trying to display a fiew lists in a FlowDocument. I Realized that when using
MarkerStyle = TextMarkerStyle.Disc, the list gets less indentation then with the others. Im looking for a way to display lists with Disc-Markers but the same indentation as the other markers get, any hints?
Heres a snippet that shows my problem :
...
Hi,
I get the following error on the WPF code bellow:
'Setter' object cannot be added to 'EventTrigger'. The given object must be an instance of TriggerAction or a derived type.
<Style x:Key="LinkLabel" TargetType="{x:Type Label}">
<Setter Property="FontFamily" Value="Tahoma"/>
<Setter Property="FontSize" Value="12"/>
<Se...
For a day now I'm struggling to solving this issue, regarding scaling a textblock and a textbox upon pinching the scatterViewItem for resizing it.
I've tried putting each of the elements in their viewbox, but also having the whole grid in a viewbox.
The issue is that it(the textbloxk, that is) doesn't scale upon pinching or stretching ...
I have about 100 TextBoxes in a Form. I need to validate them if they are decimal for instance.
This works, but it is too verbose, I don't want to have 800 in place of 100 rows in XAML.
<TextBox.Text>
<Binding Path="MyPath" UpdateSourceTrigger="PropertyChanged" Stringformat="{}{0:N}" NotifyOnValidationError="True">
<Binding....
By window-popup I mean a popup which sort of stays only with a window/application. As far as I know I will have to explicitly handle showing/hiding of popup based on Application.Current.Activated/Deactivated
Application.Current.MainWindow.Activated/Deactivated
ParentWindow.Activated/Deactivated
I want to make sure Alt-Tab hides/shows t...
So I have a class that looks like this:
internal class MyClass
{
public static readonly DependencyProperty IsSomethingProperty =
DependencyProperty.RegisterAttached(
"IsSomething", // property name
typeof(bool), // property type
typeof(MyClass), // owner type
...
I've looked through many topics here, and googled for the information, but I haven't found anything relating to my question.
What I want to do is have it so when a user starts the application, the main window (not an MDI) opens with four imageboxes, each showing an image of the form that would open when they click on it. Once the select...
I am using the WPF expander like a drawer, it expands up out so that the header remains above the content. When it is collapsed the grid cell that it is in is made smaller as well.
I want the expand direction to remain down so that the content fills in below it, however because it moves up it would look better if the icon with the dire...
Hello ;
I am very new to C#, and i am trying to use a help package for my project.
The package is written in c and has
1) /bin/ several .dll files
2) /include/ has a header file
3) /lib/msvc/ .lib file
my question is how can i use those files in my C# WPF project?
i know there is no "#include" in C#, and the .dll can not be imported ...
I have a typical treeview and a viewmodel. The viewmodel has an observable collection of other viewmodels that serves as a data source for the tree.
public class TreeViewVM {
public ObservableCollection<ItemVM> Items { get; private set; }
public ItemVM SelectedItem { get; set; }
}
and the ItemVM :
public class ItemVM {
...
I'm creating a HUD window for inspecting biz entities in my WinForms application.
I wanted to have a completely different style of window (minimize the content area and showing only the TitleBar, no system buttons, etc) so I created a WPF application for this.
The problem is that I want this Window to 'live' inside my WinForms applic...
Hello Gurus!
I've posted a similar problem here and wasn't able to successfully implement the solution suggested to me as it wasn't working.I've found a way round and wanted to improve it by binding the combobox to a custom objects to enable data validation.here is the xaml for this one
<Window xmlns:data="clr-namespace:Myproject">
<...
I have a ListBox whose ItemsSource is bound to a list of objects. The Listbox has a ItemTemplate with a DataTemplate containing a TextBlock. The textblock's Text is bound to the object's Name property (i.e. Text="{Binding Name}").
I would like to provide a radio button to show different views of the same list. For example allow a us...
Started with a default Prism Shell project using http://blogs.msdn.com/b/dphill/archive/2009/05/29/prism-quick-start-kit.aspx and all was working as expected. I began making changes and modifications and now the application is started twice, however the protected override DependencyObject CreateShell() method in the Bootstrapper is only ...