list in mfc
-
How can i access(by iterating)list in the file, which is supplied dynamically(browsing to select file using CFileDialog)during the execution in vc++(mfc) project?? kamalesh
-
How can i access(by iterating)list in the file, which is supplied dynamically(browsing to select file using CFileDialog)during the execution in vc++(mfc) project?? kamalesh
-
Use CFileDialog::GetPathName() to get the path of the file. Then open the file. Then read the data from the file.
ya i already used that.frm thre i can read only the 1st list.but iterating the list using Clist, it's not happening. can u tell me that? how to iterate in this file? kamalesh
-
ya i already used that.frm thre i can read only the 1st list.but iterating the list using Clist, it's not happening. can u tell me that? how to iterate in this file? kamalesh
If you set the
OFN_ALLOWMULTISELECT
flag for the dialog, you use the following code to iterate through the list of path names:CFileDialog dlg(...); // use appropriate settings if (dlg.DoModal() == IDOK) { POSITION pos = dlg.GetStartPosition(); while (NULL != pos) { CString newPath = dlg.GetNextPathName(pos); // do something with newPath }
Is that what you are trying to do? If you decide to become a software engineer, you are signing up to have a 1/2" piece of silicon tell you exactly how stupid you really are for 8 hours a day, 5 days a week Zac -- modified at 15:29 Wednesday 21st June, 2006 -
ya i already used that.frm thre i can read only the 1st list.but iterating the list using Clist, it's not happening. can u tell me that? how to iterate in this file? kamalesh
kamalesh82 wrote:
frm thre i can read only the 1st list
What list? Are you trying to read the contents of the selected file?
kamalesh82 wrote:
...but iterating the list using Clist...
How are you using
CList
?
"The largest fire starts but with the smallest spark." - David Crow
"Judge not by the eye but by the heart." - Native American Proverb
-
kamalesh82 wrote:
frm thre i can read only the 1st list
What list? Are you trying to read the contents of the selected file?
kamalesh82 wrote:
...but iterating the list using Clist...
How are you using
CList
?
"The largest fire starts but with the smallest spark." - David Crow
"Judge not by the eye but by the heart." - Native American Proverb
-
How can i access(by iterating)list in the file, which is supplied dynamically(browsing to select file using CFileDialog)during the execution in vc++(mfc) project?? kamalesh
if you want to read file and directory names with CListBox use
DlgDirList
_**
**_
whitesky