Expiring Today—Celebrate National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

TOpenSaveDialog

Posted on 1997-11-19
2
Medium Priority
?
297 Views
Last Modified: 2013-12-26
I cannot seem to be able to manipulate the multiple files I select while using the common dialog <TOpenSaveDialog>.  I use the following code:
TOpenSaveDialog::TData *pWndwFileOpenData;
pWndwFileOpenData =
new TOpenSaveDialog::TData(OFN_PATHMUSTEXIST |
                           OFN_HIDEREADONLY  |
                           OFN_FILEMUSTEXIST |
                           OFN_ALLOWMULTISELECT,
      "Report Files(*.rep)|*.rep", 0, "", "REP");
enables me to set up the common dialog box in order to execute it.  But despite being able to execute it I cannot - or better yet do not understand how to use the multiple files that I selected from the open dialog box.

Please Help!!!  
0
Comment
Question by:yakhu
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 

Author Comment

by:yakhu
ID: 1299478
Edited text of question
0
 
LVL 3

Accepted Solution

by:
LucHoltkamp earned 200 total points
ID: 1299479
The TData structure does not contain any fields to put multiple in, so they all go in the one filename field. Since OWL usually simply wraps around the WIN32 API it's likely to be the same. Look in the Win32 online help for the OPENFILENAME struct. Under Flags/OFN_MULTISELECT and you'll read:

When this flag is set, the lpstrFile member points to a buffer containing the path to the current directory and all filenames in the selection. The first filename is separated from the path by a space. Each subsequent filename is separated by one space from the preceding filename. Note that for the new Explorer-style dialogs (dialogs that have the OFN_EXPLORER flag set), a single null character, \0, separates the filenames, and two null characters, \0\0, terminate the entire string.

I suppose you'll be able to find out the details (I've read somewhere that with OWL the filenames are separated by \0) and hope this helps.
.luc.
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction Knockoutjs (Knockout) is a JavaScript framework (Model View ViewModel or MVVM framework).   The main ideology behind Knockout is to control from JavaScript how a page looks whilst creating an engaging user experience in the least …
Styling your websites can become very complex. Here I'll show how SASS can help you better organize, maintain and reuse your CSS code.
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

718 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question