Click here to Skip to main content
15,918,267 members
Home / Discussions / WPF
   

WPF

 
GeneralRe: Bind CLR Object Instance To A ListBox Pin
BlitzPackage22-May-08 6:36
BlitzPackage22-May-08 6:36 
GeneralRe: Bind CLR Object Instance To A ListBox Pin
Insincere Dave22-May-08 9:39
Insincere Dave22-May-08 9:39 
GeneralRe: Bind CLR Object Instance To A ListBox Pin
BlitzPackage22-May-08 14:52
BlitzPackage22-May-08 14:52 
GeneralRe: Bind CLR Object Instance To A ListBox Pin
BlitzPackage24-May-08 11:00
BlitzPackage24-May-08 11:00 
QuestionResource Dictionaries. Pin
Jammer21-May-08 6:04
Jammer21-May-08 6:04 
AnswerRe: Resource Dictionaries. Pin
User 27100925-May-08 8:14
User 27100925-May-08 8:14 
GeneralRe: Resource Dictionaries. Pin
Jammer26-May-08 10:16
Jammer26-May-08 10:16 
GeneralRe: Resource Dictionaries. Pin
User 27100926-May-08 10:35
User 27100926-May-08 10:35 
Run this, you'll get all your colors and brushes.

<br />
    Private Sub Window1_Loaded(ByVal sender As Object, ByVal e As System.Windows.RoutedEventArgs) Handles Me.Loaded<br />
<br />
        Dim pi As PropertyInfo() = GetType(SystemColors).GetProperties<br />
<br />
        For Each obj As PropertyInfo In pi<br />
            If obj.PropertyType Is GetType(System.Windows.ResourceKey) Then<br />
                Dim objBrush As Object = Me.FindResource((obj.GetValue(Nothing, Nothing)))<br />
                If TypeOf objBrush Is SolidColorBrush Then<br />
                    Debug.WriteLine("Brush: " & CType(objBrush, SolidColorBrush).Color.ToString)<br />
                ElseIf TypeOf objBrush Is System.Windows.Media.Color Then<br />
                    Debug.WriteLine("Color: " & CType(objBrush, System.Windows.Media.Color).ToString)<br />
                Else<br />
                    Debug.WriteLine("should not get here")<br />
                End If<br />
            End If<br />
<br />
        Next<br />
    End Sub


Cheers, Karl

» CodeProject 2008 MVP
» Microsoft MVP - Client App Dev

My Blog | Mole's Home Page | MVP Profile

Just a grain of sand on the worlds beaches.



modified 27-Feb-21 21:01pm.

GeneralRe: Resource Dictionaries. Pin
Jammer26-May-08 11:12
Jammer26-May-08 11:12 
GeneralRe: Resource Dictionaries. [modified] Pin
Jammer26-May-08 23:36
Jammer26-May-08 23:36 
GeneralRe: Resource Dictionaries. Pin
Jammer27-May-08 6:38
Jammer27-May-08 6:38 
GeneralRe: Resource Dictionaries. Pin
User 27100927-May-08 8:47
User 27100927-May-08 8:47 
GeneralRe: Resource Dictionaries. Pin
Jammer27-May-08 8:58
Jammer27-May-08 8:58 
QuestionGet the top most child windows Pin
Rohde21-May-08 5:34
Rohde21-May-08 5:34 
AnswerRe: Get the top most child windows Pin
Jammer21-May-08 5:59
Jammer21-May-08 5:59 
GeneralRe: Get the top most child windows Pin
Rohde21-May-08 20:20
Rohde21-May-08 20:20 
GeneralRe: Get the top most child windows Pin
Jammer21-May-08 23:30
Jammer21-May-08 23:30 
GeneralRe: Get the top most child windows Pin
Rohde21-May-08 23:35
Rohde21-May-08 23:35 
GeneralRe: Get the top most child windows Pin
Jammer22-May-08 1:08
Jammer22-May-08 1:08 
AnswerRe: Get the top most child windows Pin
James Lonero5-Jun-08 8:04
James Lonero5-Jun-08 8:04 
GeneralRe: Get the top most child windows Pin
Rohde5-Jun-08 11:08
Rohde5-Jun-08 11:08 
QuestionExpression Blend September Preview Issue Pin
katelva21-May-08 3:29
katelva21-May-08 3:29 
AnswerRe: Expression Blend September Preview Issue Pin
Michael Sync24-May-08 21:31
Michael Sync24-May-08 21:31 
QuestionSkinning & Themes Pin
Jammer20-May-08 23:17
Jammer20-May-08 23:17 
AnswerRe: Skinning & Themes Pin
Jammer21-May-08 1:04
Jammer21-May-08 1:04 

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.