PC SOFT

ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Home | Sign in | English EN
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Configures the operating mode of the AWP context.
For more details on the available modes, see Managing AWP contexts.
Remark: If ConfigureAWPContext is not called, contexts are managed via cookies by default.
Caution: This function requires a good knowledge of WEBDEV.
Example
// Manage the context of a file on the server
// and transmit the identifier by cookie
ConfigureAWPContext(ctxDisk, ctxIDCookie)
Syntax
ConfigureAWPContext(<Content storage mode> [, <Identifier transmission mode>])
<Content storage mode>: Integer constant
Mode for storing the content of the context:
ctxCookieThe content is transmitted in a cookie (behavior compatible with version 11).
Caution: This constant must not be used to store sensitive data. Indeed, this information is stored "without being encrypted".
ctxDiskThe content of the context is saved in a file on the server.
<Identifier transmission mode>: Integer constant (optional)
Define the transmission mode of identifier (taken into account only if <Content storage mode> corresponds to the ctxDisk constant):
ctxIDCookieThe identifier is transmitted by a cookie.
ctxIDCookieURL
(default value)
The identifier is transmitted by cookies. If the cookies do not operate, the identifier is transmitted by the URL. When creating the context, the two modes are used because it is not possible to know whether the cookies will be accepted or not.
ctxIDUrlThe identifier is transmitted by the URL.
Remarks
  • It is recommended to use ConfigureAWPContext in the "Initializing" event of the project. Indeed, this mode cannot be modified once the session was started.
  • ConfigureAWPContext is taken into account in AWP mode only.
  • If ConfigureAWPContext is not called, contexts are managed via cookies by default.
  • Reminder: The initialization process of project is run whenever an Active WEBDEV Page is displayed.
  • If your project uses pre-launched sessions, this function must not be used in the project initialization event. This function must be used in the "Initializing the project after connection to the site" event.
  • For more details, see The dynamic Active WEBDEV Pages.
Component: wd270page.dll
Minimum version required
  • Version 12
Comments
Exemplo Looper manual no awp
https://windevdesenvolvimento.blogspot.com/2021/06/dicas-3355-windev-webdev-mobile-fazer.html
https://youtu.be/e8yvn_5syGQ
//Exemplo Looper manual no awp
// no projeto global // Initializing awp_Exemplo
ConfigureAWPContext(ctxDisk)
//na pagina looper co awp , no codigo da procedure pagina
garrMeu_looper_array is array of string
DeclareAWPContext(garrMeu_looper_array)
// initializing of btn looper (server)
LOOP_exemplo.DeleteAll()
FOR EACH sLinha OF garrMeu_looper_array
LOOP_exemplo.AddLine(sLinha)
END
// no click do btn looper server - ajax ativado
texto is string="Texto: "+TimeSys()
LOOP_exemplo.AddLine(texto)
ArrayAdd(garrMeu_looper_array,texto)
// botao fechar
CancelAWPContext(garrMeu_looper_array)
PageDisplay(PAGE_looper_com_sessao)

amarildo
15 Jun. 2021