This patch is in reference to RFE 1771904. The attached file demonstrates much of the capability of FileNameDialog.
You seem to have CSS turned off.
Please don't fill out this field.
Logged In: YES
1.) Would you add as a comment to this item a statement of contribution source similar to the following, in your words does not need to be verbatim:
The example program fileNameDialog_demo.rex is my original work. Lee Pendin (email@example.com)
(Sorry, don't remember your exact e-mail.)
2.) I've already done this, so you don't need to change the attached program. But, in the future would you put the standard ooRexx header on the file. You should either do that, or you would need to make a longer source contribution statement stating that you are releasing your original work under the terms of the Common Public License v1.0.
I'm talking about this header:
/ Copyright (c) 2007 Rexx Language Association. All rights reserved. /
/ This program and the accompanying materials are made available under /
/ the terms of the Common Public License v1.0 which accompanies this /
/ distribution. A copy is also available at the following address: /
/ http://www.oorexx.org/license.html /
/ Redistribution and use in source and binary forms, with or /
/ without modification, are permitted provided that the following /
/ conditions are met: /
3.) I would like to put samples contributed like this one into the incubator. That way anyone can access them now, prior to a release. Then, it would be cool if we could get some feedback on which samples are useful, and move the useful ones into the release product.
I'm going to do that with this one, and also your Excel examples.
4.) Do you mind if we rename this to fileNameDialog_demo.rex? (Just a capitalization thing.)
5.) I would lend great weight to including samples in the release product that had an accompanying ooRexxUnit test. The test unit would not need to prove that the example worked 100%.
As you may have read on one of the lists, what I would like to see is a test unit that launched the sample and asserted that the example did in fact execute. Any additional assertations that the example executed as expected would then be icing on the cake.
This is not a requirement at all for this patch. Just something I am throwing out. I may take this program and write one myself as an example of what I am thinking of along these lines.
Logged In: YES
1) The example program fileNameDialog_demo.rex is my original work. Lee Peedin (lee AT safedatausa DOT com)
2) Will do, had asked for clarification on this in the past, but not got a response
3) The incubator is fine for this and anything else I submit as a patch
4) Renaming is fine with me
Other: Mark, I still don't have a grasp of exactly how to use the TestUnit (I know, I'm "thick"). An example running this as a TestUnit would be greatly appreciated.
I am attaching a simple ooRexxTestUnit for this program. I tried to comment it to help understand the process.
Up until line 101 in the test unit is just boilerplate code. Rony has examples with the boilerplate code well commented. I took some un-needed stuff out along with a lot of comment to simplify things in that part of the file.
From line 101 down is the real test unit. It only has 1 test case, well commented. From line 190 down are helper functions and classes that can be re-used for Windows GUI test units and for the purpose of understanding the test case can be just thought of as black box code.
File Added: fileNameDialog_demo_simple.testUnit
Committed revision 670.
Lee thank you for your contribution.
I have placed the example program in the incubator, along with the sample ooRexxUnit test unit.
The files were place in the samples/ooDialog/public.routines sub-diretory of the incubator. The command to check out the entire incubator is:
svn co https://oorexx.svn.sourceforge.net/svnroot/oorexx/incubator <destination>
You can check out any sub-portion of the repository the same way by adding the sub-directories on to the command. For example (the following should be all one line, but will wrap) the command:
svn co https://oorexx.svn.sourceforge.net/svnroot/oorexx/incubator/samples/ooDialog/public.routines <dest>
will check out just the directory with the added files.
Replace test unit example
File Added: fileNameDialog_demo.testUnit
Committed revision 955.
Moved Lee's program from the incubator to the sample programs included with the distribution. Thanks Lee.