2023-02-22, 08:11:03
Hi Willa
> Sorry I seem to have missed your question, so my reply is a bit slower than usual.
Comparing the support offered for other products, the support you provide for AntView is lightning fast. Bravo Wila !
>NavigateWithWebResourceRequestSync
NavigateWithWebResourceRequestSync gives me the opportunity to clean-up my code by removing a lot of timers and the functions they call, asynchronously.
I use AntView activex control, in dBase 2019, to send electronic invoices (xml string) and now this can be done with only 3 lines of code (the server response is a json string).
form.AntView1.nativeObject.NavigateWithWebResourceRequestSync( uri, "POST", xmlString, "Content-Type: application/xml" )
rJsonString = new string()
form.AntViewDocument1.RequestCurrentTextSync( rJsonString )
Very, very simple. Thanks you.
>RunAnonymousFunctionSync
In another project, I use RunAnonymousFunctionSync as often as possible, but I failed when the function had to call another custom function that is defined in the same string.
Example:
// jsString
(p1, p2) => {
a = customFunction1( p1 ) ;
b = customFunction2( p2 ) ;
return a + b ;
}
function customFunction1(x) {
return x ;
}
function customFunction2(y) {
return y ;
}
AntView activex control integrates very well with dBase 2019, parameters can be passed easily
//dbase code, {myVar1, myVar2} is a literal array (1 dimension , 2 elements )
vRet = new string()
form.AntViewDocument1.RunAnonymousFunctionSync(anyIntValue, {myVar1, myVar2}, jsString, vRet)
If there is no additional function declaration in the jsString, the execution succeeds, otherwise it fails.
For these situations I use:
form.AntView1.nativeObject.ExecuteScript(jsString)
// jsString
p1 = "value of myVar1";
p2 = "value of myVar2";
a = customFunction1( p1 ) ;
b = customFunction2( p2 ) ;
function customFunction1(x) {
return x ;
}
function customFunction2(y) {
return y ;
}
That's why I would like there to be a SYNC variant of the ExecuteScript method.
Thanks you
Vasile
> Sorry I seem to have missed your question, so my reply is a bit slower than usual.
Comparing the support offered for other products, the support you provide for AntView is lightning fast. Bravo Wila !
>NavigateWithWebResourceRequestSync
NavigateWithWebResourceRequestSync gives me the opportunity to clean-up my code by removing a lot of timers and the functions they call, asynchronously.
I use AntView activex control, in dBase 2019, to send electronic invoices (xml string) and now this can be done with only 3 lines of code (the server response is a json string).
form.AntView1.nativeObject.NavigateWithWebResourceRequestSync( uri, "POST", xmlString, "Content-Type: application/xml" )
rJsonString = new string()
form.AntViewDocument1.RequestCurrentTextSync( rJsonString )
Very, very simple. Thanks you.
>RunAnonymousFunctionSync
In another project, I use RunAnonymousFunctionSync as often as possible, but I failed when the function had to call another custom function that is defined in the same string.
Example:
// jsString
(p1, p2) => {
a = customFunction1( p1 ) ;
b = customFunction2( p2 ) ;
return a + b ;
}
function customFunction1(x) {
return x ;
}
function customFunction2(y) {
return y ;
}
AntView activex control integrates very well with dBase 2019, parameters can be passed easily
//dbase code, {myVar1, myVar2} is a literal array (1 dimension , 2 elements )
vRet = new string()
form.AntViewDocument1.RunAnonymousFunctionSync(anyIntValue, {myVar1, myVar2}, jsString, vRet)
If there is no additional function declaration in the jsString, the execution succeeds, otherwise it fails.
For these situations I use:
form.AntView1.nativeObject.ExecuteScript(jsString)
// jsString
p1 = "value of myVar1";
p2 = "value of myVar2";
a = customFunction1( p1 ) ;
b = customFunction2( p2 ) ;
function customFunction1(x) {
return x ;
}
function customFunction2(y) {
return y ;
}
That's why I would like there to be a SYNC variant of the ExecuteScript method.
Thanks you
Vasile