Article View: borland.public.cppbuilder.nativeapi
Article #15825Re: Run program against file
From: Ed Mulroy [TeamB]
Date: Sat, 14 Jun 2003 01:27
Date: Sat, 14 Jun 2003 01:27
44 lines
2988 bytes
2988 bytes
It sounds as if you did not select a file. If that is not it, then I do not know what the problem is. Take the exact code I gave you, copied from the message, everything between the dashed lines and save it in a file named TEMP.CPP Then run the command line bcc32 -WR -v temp Then run the program. Select a file by double clicking on it or by typing its name into the File Name box and clicking Ok. The selection dialog should look almost the same as if you did a File|Open|Browse in Internet Explorer except that the default directory selected is C:\Program FIles. In it you are expected to select a file just as you would were it Internet Explorer asking. If you are looking to select an output file, which has the feature that a file that does not yet exist can be specified then you will have to change one or more of the flags in the structure which is given to the GetOpenFileName function. Run the Windows help file, WIN32.HLP, and read about that file and about the OPENFILENAME structure that it uses. . Ed > cpp3003 wrote in message > news:3ee9dde6$1@newsgroups.borland.com... > > Thanks for the reply. I used the code below, but, I ran into a > problem. I haven't used api much, so, I am not sure if there > is more that I need to add or if I need to reposition something. > But, when I ran the .exe for this code, it dropped straight > through to the 'file selection error 00000001/0', then, when I > click the ok button it gives a box that says 'Selected File', > but no file name appears. > > How does the process look when it works correctly? Also, > will the process bring up a window to select a file, and, > invoke my program with that file name as an argument ? I > am also looking at a way to open an outfile which > shows a text report after my process completes. Can this > be done as an addition to the code below ?
Technical Details
Message-ID:
<3eea79f9$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-09!supernews.com!news.maxwell.syr.edu!out.nntp.be!propagator2-sterling!news-in.nuthinbutnews.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mailReferences:
<3ee8f082$1@newsgroups.borland.com> <3ee8fc5c@newsgroups.borland.com> <3ee9dde6$1@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10cc67,7bb2502e61022b33 X-Google-Attributes: gid10cc67,public X-Google-ArrivalTime: 2003-06-13 18:36:30 PST From: "Ed Mulroy [TeamB]" <ed@mulroyREMOVETHESECHARS.org> Newsgroups: borland.public.cppbuilder.nativeapi References: <3ee8f082$1@newsgroups.borland.com> <3ee8fc5c@newsgroups.borland.com> <3ee9dde6$1@newsgroups.borland.com> Subject: Re: Run program against file Date: Fri, 13 Jun 2003 21:27:11 -0400 Lines: 46 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 NNTP-Posting-Host: 24.74.175.102 Message-ID: <3eea79f9$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1055554041 24.74.175.102 (13 Jun 2003 18:27:21 -0700) X-Authenticated-User: edmulroy Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!sn-xit-09!supernews.com!news.maxwell.syr.edu!out.nntp.be!propagator2-sterling!news-in.nuthinbutnews.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mail