Consultor Eletrônico



Kbase 15343: SmartFolders, System Resources, and Windows 3.X SE 4025
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   5/10/1998
SmartFolders, System Resources, and Windows 3.X SE 4025

SmartFolders and Windows 3.X

Please note that this problem is not an issue under Windows 95
due to the greatly increased system resources available on that
platform.

In the current implementation of SmartFolders it is possible to
exhaust system resources under the Microsoft Windows 3.1, 3.11,
and Windows for Workgroups environments.

The reason for this is that as the user clicks for the first time
from page to page in the SmartFolder, all of the objects for the
newly selected page are loaded into memory. Unfortunately, on
these MS-Windows environments there are only two (2) 64K chunks
of memory in which all "visual" objects are placed. It is very
easy to run out of these so-called "System Resources" even though
the Program Manager shows many megabytes of memory free.

One workaround to this problem is to implement the following
code fragment as a "local-change-page" method:


/*---------------------------------------------------------------
Purpose: Override standard ADM method
Notes:
---------------------------------------------------------------*/

DEFINE VARIABLE CurrentPage AS INTEGER NO-UNDO.

/* Code placed here will execute PRIOR to standard behavior. */

RUN get-attribute ('current-page').

ASSIGN CurrentPage = INTEGER(RETURN-VALUE).

/* Dispatch standard ADM method. */

RUN dispatch IN THIS-PROCEDURE ( INPUT 'change-page':U ) .

/* Code placed here will execute AFTER standard behavior. */
if prevPage ne 0 then do:
RUN delete-page IN THIS-PROCEDURE (prevPage).
end.
assign prevPage = currentPage.

END PROCEDURE.


NOTE: Do not forget to define the prevPage variable in the Definitions
section:

define prevPage as integer no-undo.

Progress Software Technical Support Note # 15343