Click here to Skip to main content
15,906,816 members
Home / Discussions / WPF
   

WPF

 
AnswerRe: Stored Procedure Population of Silverlight Combo Box Pin
Vimalsoft(Pty) Ltd8-Feb-11 19:57
professionalVimalsoft(Pty) Ltd8-Feb-11 19:57 
GeneralRe: Stored Procedure Population of Silverlight Combo Box [modified] Pin
VSS712J11-Feb-11 8:17
VSS712J11-Feb-11 8:17 
GeneralRe: Stored Procedure Population of Silverlight Combo Box Pin
Pete O'Hanlon11-Feb-11 9:10
mvePete O'Hanlon11-Feb-11 9:10 
GeneralRe: Stored Procedure Population of Silverlight Combo Box Pin
VSS712J11-Feb-11 10:29
VSS712J11-Feb-11 10:29 
Questionpaint eclipse control Pin
arkiboys7-Feb-11 4:13
arkiboys7-Feb-11 4:13 
AnswerRe: paint eclipse control Pin
Pete O'Hanlon7-Feb-11 4:27
mvePete O'Hanlon7-Feb-11 4:27 
GeneralRe: paint eclipse control Pin
arkiboys7-Feb-11 4:32
arkiboys7-Feb-11 4:32 
GeneralRe: paint eclipse control Pin
Pete O'Hanlon7-Feb-11 4:37
mvePete O'Hanlon7-Feb-11 4:37 
QuestionMultiple SilverLight apps Pin
Ray Cassick5-Feb-11 13:00
Ray Cassick5-Feb-11 13:00 
AnswerRe: Multiple SilverLight apps Pin
Abhinav S5-Feb-11 17:51
Abhinav S5-Feb-11 17:51 
GeneralRe: Multiple SilverLight apps Pin
Ray Cassick11-Feb-11 11:07
Ray Cassick11-Feb-11 11:07 
AnswerRe: Multiple SilverLight apps Pin
RichardGrimmer11-Feb-11 4:52
RichardGrimmer11-Feb-11 4:52 
GeneralRe: Multiple SilverLight apps Pin
Ray Cassick11-Feb-11 11:05
Ray Cassick11-Feb-11 11:05 
QuestionC# Client Server Application on WPF IDE Pin
LAPEC4-Feb-11 1:48
LAPEC4-Feb-11 1:48 
AnswerRe: C# Client Server Application on WPF IDE Pin
RobCroll4-Feb-11 1:54
RobCroll4-Feb-11 1:54 
AnswerRe: C# Client Server Application on WPF IDE Pin
Pete O'Hanlon4-Feb-11 1:57
mvePete O'Hanlon4-Feb-11 1:57 
AnswerRe: C# Client Server Application on WPF IDE Pin
Abhinav S4-Feb-11 5:12
Abhinav S4-Feb-11 5:12 
QuestionSilverlight Hierarchical template for Multiple Types in Treeview Pin
www.Developerof.NET3-Feb-11 23:47
www.Developerof.NET3-Feb-11 23:47 
AnswerRe: Silverlight Hierarchical template for Multiple Types in Treeview Pin
Mycroft Holmes7-Feb-11 19:44
professionalMycroft Holmes7-Feb-11 19:44 
I create a class ReportNode, it uses the NodeTag property to store the actual record that is used to populate the treenode

public class ReportNode : ViewModelBase
{
    public ReportNode(string sLabel, object oObject, string sColor)
    {
        NodeLabel = sLabel;
        NodeTag = oObject;
        Color = sColor;
    }
    public string NodeLabel { get; set; }
    public object NodeTag { get; set; }
    public string Color { get; set; }

    private ObservableCollection<ReportNode> _ChildNodes;
    public ObservableCollection<ReportNode> ChildNodes
    {
        get
        { return _ChildNodes; }
        set
        {
            _ChildNodes = value;
            base.OnPropertyChanged("ChildNodes");
        }
    }
}


Hierarchical data template binds the itemssource to the ChildNodes collection.

When loading the nodes I stuff the NodeLabel with the text to display and the list object goes in the NodeTag property. When accessing the node I test the typeof the nodetag to determine what to do with the node. I have 1 tree with 6 different data sources, works perfectly.
Never underestimate the power of human stupidity
RAH

Questionbind combobbox [modified] Pin
arkiboys3-Feb-11 23:40
arkiboys3-Feb-11 23:40 
AnswerRe: bind combobbox Pin
Pete O'Hanlon3-Feb-11 23:44
mvePete O'Hanlon3-Feb-11 23:44 
Questionpopulate combobox with names and ids Pin
arkiboys3-Feb-11 12:05
arkiboys3-Feb-11 12:05 
AnswerRe: populate combobox with names and ids Pin
_Maxxx_3-Feb-11 14:47
professional_Maxxx_3-Feb-11 14:47 
GeneralRe: populate combobox with names and ids Pin
arkiboys3-Feb-11 22:44
arkiboys3-Feb-11 22:44 
GeneralRe: populate combobox with names and ids Pin
_Maxxx_6-Feb-11 16:27
professional_Maxxx_6-Feb-11 16:27 

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.