C# WPF app combobox pulldown not working correctly
$30-5000 USD
Cancelled
Posted over 12 years ago
$30-5000 USD
Paid on delivery
I have a C#, WPF app that is having a problem with the combobox pulldown. It on some occassions is not displaying either the pull down choice chosen or the correct data. I am told that i need Bind ComboBox to an ObservableCollection, so UI will get automatically updated. I do not know how to do this or locate this area. here is some of the code: I think it should not take too long, I also will have other such work as we are promoting this [login to view URL] someone to do this Friday AM USA Eastern time.
[Export]
class ScheduleViewModel : TabViewModel, ISelectedContentTab
{
//
private readonly String[] _assessmentType = new String[] { "All", "INCOMPLETE", "COMPLETED", "COMPLETED LATE", "INCOMPLETE LATE", "NOT STARTED - LATE", "NOT STARTED", "SUBMITTED", "SUBMITTED LATE" };
//pk display ALL as default in detail tab.
//
public ScheduleViewModel()
: base()
{
DisplayName = "Schedules";
StartDate = [login to view URL](-6);
EndDate = [login to view URL];
GroupDataCollection = new ObservableCollection<GroupData>()
{
// here is the combo box
[login to view URL]()
, new GroupData("Criterria"
, [login to view URL](StartDate,EndDate,(s, e) => { StartDate = s; EndDate = e; RefreshData(); })
, [login to view URL](UnitChanged)
, [login to view URL]("Assessment", "Assessment", "Select Assessment to show.", _assessmentType, (type) => { AssessmentType = type; })
)
};