× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



The details subfile will no doubt be under 100 items?

In that event, it might make sense to first fill an array with the data, and then fill the subfile from the array.

Then create a exfmt loop where the subfile is read, compared to the array itself, and a new array made from the new data, including any provisions you want to make for added returns, or whatever. Then, copy the new array to the original array and totally reload the subfile with the new information. It will run very quickly; certainly sub-second.



On 3/28/2012 1:36 PM, Michael Schutte wrote:
I was wondering if anyone has attempted to actively insert new records into
a subfile? What I'm trying to accomplish is when a customer returns an
item, I want them the company to supply a reason code for the return. Now
the customer could have ordered two of the same item and returned both of
them for two different reasons. I figured, I would first bring up the
order, have the company select the quantity being returned, then on the
next screen, list all of the items they selected, giving them the ability
to enter a reason code and the quantity being returned for that reason. If
they enter a quantity that is less than what was selected on the first
screen then I want to pop in a new subfile record below it so that they can
enter another reason code. Does that make sense?

So on the first screen, the user will enter in a 1 to select the item and
then be taken to another screen.

Option:1=Select

O Item Qty
*1* 69374 * 3*
*1* 69375 * 2*
*
*
*
*
Item Qty Reason
69374 * 3* * *
69375 * 2* _____
*
*
*
*
Lets say that item 69374, the company puts a 1 in the Qty column. When
they leave the field, I would like to add a new record to the subfile right
below it. So that it would look like.

Item Qty Reason
69374 * 1* * *
69374 * 2* * *
69375 * 2* _____


I have my thoughts... I'd imagine that there is a DDS keyword that will
trigger the return back to the program and then I'll need to reload the
subfile adding the new record when needed. But I would need to save the
relative record number so that the cursor is returned back to where the
user was at. When returning back to the program, I could insert records
into a qtemp file of what the user entered, compare the quantity to what
the user originally entered. If it doesn't match, then insert a new record
to the qtemp file with the remainder. Then reload the subfile with the
qtemp file.

I envision this being a LOAD ALL Subfile.

Any suggestions. Tried googling but didn't really find anything relevant.
If my screen layouts didn't come across correctly, copy it to notepad with
font being courier new.

Thank you,
Michael Schutte


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.