APPX is the Premier Development and Runtime Environment for Business Application Software
(Answer) (Category) FAQ's - APPX Software, Inc. : (Category) APPX Utility : (Category) APPX Development Environment : (Category) Data Dictionary :
Can I pass information into a FLEP?
Yes and No. The way you pass more information into a File Level Event Point (FLEP) is by adding more fields to the record buffer for that file.

For instance, if you need to pass in a POST TO HISTORY flag so that the FLEP knows if it should update the HISTORY file from this record. You would add this flag to the data dictionary for the file. It doesn't hurt to have it there and stored with the record. Doing so lets you know at a later date which records have been posted to history. Being part of the record makes it visible and obvious that the data element is there and needs to have a value for the FLEP code to execute properly. This is visible and passed regardless of when, how, and why the FLEP fires. By an APPX Process, an ILF Write, an AppxODBC Rewrite, etc. it doesn't matter.

The FLEPs that are associated with a file only share the file record buffer with the processes that trigger them. Additionally, the standard PASS and RECEIVE statements will not work to pass data in and out of FLEPs.

This is by design. There are a number of reason for this restriction.

1)Work field and file fields other than those in the FLEP record buffer used in a process are protected from being stepped on by any FLEP code that might fire during the running of that process.

2) FLEPs run as a separate process and don't always fire in a procedural fashion as a design might expect. They are event driven and fire anytime Appx reads, writes, rewrites, or deletes a record. There are times when Appx does this automatically for the designer. And also times when FLEPs are fired when there is no designer created process running. One example of this is when a AppxODBC connection manipulates data that is stored in an Appx database.

3)FLEPs were designed to provide a place to code data specific rules, not process specific rules. If there is code that is specific to a process, code it in that process, not in the FLEP.

Some customers have come up with creative ways to bypass this restriction such as creating a permanent disk file with OS process ID as the key to write data into that they can later read in the FLEP. This is not recommended as a general programming technique for the reasons listed above.

[Append to This Answer]
2004-Mar-16 1:47pm
Previous: (Answer) What is the scope of a FLEP?
Next: (Answer) How many times does Post-PCF Read FLEP fire?
This document is: http://board.appx.com/cgi-bin/fom.cgi?file=359
[Search] [Appearance]
This is a Faq-O-Matic 2.719.
Copyright 2003 by APPX Software, Inc. All rights reserved.