Explorer type application
-
i am trying to create a windows explorer type application in vc++.i am able to update the TreeView for the directory list. But i am unable to populate the ListView(right pane).i have listed the code below.. void CDirTreeDemoView::OnInitialUpdate() { CListView::OnInitialUpdate(); GetListCtrl ().InsertColumn (0, _T ("File Name"), LVCFMT_LEFT, 192); GetListCtrl ().InsertColumn (1, _T ("Size"), LVCFMT_RIGHT, 96); GetListCtrl ().InsertColumn (2, _T ("Last Modified"), LVCFMT_CENTER,128); } any help plz thanks
-
i am trying to create a windows explorer type application in vc++.i am able to update the TreeView for the directory list. But i am unable to populate the ListView(right pane).i have listed the code below.. void CDirTreeDemoView::OnInitialUpdate() { CListView::OnInitialUpdate(); GetListCtrl ().InsertColumn (0, _T ("File Name"), LVCFMT_LEFT, 192); GetListCtrl ().InsertColumn (1, _T ("Size"), LVCFMT_RIGHT, 96); GetListCtrl ().InsertColumn (2, _T ("Last Modified"), LVCFMT_CENTER,128); } any help plz thanks
BOOL CDirTreeDemoView::PreCreateWindow(CREATESTRUCT& cs) { cs.style |= LVS_EDITLABELS | LVS_REPORT; return CListView::PreCreateWindow(cs); } void CDirTreeDemoView::OnInitialUpdate() { CListView::OnInitialUpdate(); CListCtrl& refCtrl = GetListCtrl(); CMainFrame* pFrame = STATIC_DOWNCAST(CMainFrame, AfxGetMainWnd()); // insert columns refCtrl.InsertColumn(0, _T("File Name"), LVCFMT_LEFT, 192); refCtrl.InsertColumn(1, _T("Size"), LVCFMT_RIGHT, 96); refCtrl.InsertColumn(2, _T("Last Modified"), LVCFMT_CENTER, 128); DWORD dwExListStyles = LVS_EX_FULLROWSELECT; GetListCtrl().SetExtendedStyle(dwExListStyles); }
Maybe this will help P. -
i am trying to create a windows explorer type application in vc++.i am able to update the TreeView for the directory list. But i am unable to populate the ListView(right pane).i have listed the code below.. void CDirTreeDemoView::OnInitialUpdate() { CListView::OnInitialUpdate(); GetListCtrl ().InsertColumn (0, _T ("File Name"), LVCFMT_LEFT, 192); GetListCtrl ().InsertColumn (1, _T ("Size"), LVCFMT_RIGHT, 96); GetListCtrl ().InsertColumn (2, _T ("Last Modified"), LVCFMT_CENTER,128); } any help plz thanks
Nithyb wrote: But i am unable to populate the ListView Why? What problem(s) are you having?
"One must learn from the bite of the fire to leave it alone." - Native American Proverb