News:

Official release of PxPlus 2025 Update 1 (version 22.10)  NOW available for download.

Main Menu

Recent posts

#51
Programming / Re: Working with External obje...
Last post by HendersonS - December 10, 2025, 12:06:23 PM
Mike, I tried doing it as you instructed, but I'm still getting the same error.

DEF OBJECT v,"*VARIANT"
v'val$="false"
v'type$="B"
PRINT v'val$
0
report'export(*v)
report'export(v) !also try this
Error #88: Invalid/unknown property name
Exception occurred (err/ret=2/0)

#52
Programming / Re: Working with External obje...
Last post by Mike King - December 09, 2025, 04:17:46 PM
Have you tried setting 'VAL$ of the *VARIANT object then changing its type?

->def object v,"*variant"
->v'val$="false"
->?v'val$
false
->print v'type$
S
->v'type$="B"
->print v'val
 0
->v'val$="true"
->print v'type$
S
->v'type$="B"
->print v'val$
-1
As per the docs, setting the type will cause the *VARIANT to properly convert the value.
#53
Programming / Re: Working with External obje...
Last post by HendersonS - December 09, 2025, 12:41:08 PM
Mike, thanks for your reply. Could you give me an example of how to pass a boolean value false because my attempts are receiving the same error?

We try:
DEF OBJECT V,"*VARIANT"
LET V'TYPE$="B"
LET V'VAL$="0"
! LET V'VAL$="FALSE" !ALSO TRY THIS
REPORT'EXPORT(*V)
!REPORT'EXPORT(V) ! also try this
#54
Programming / Re: Working with External obje...
Last post by Mike King - December 09, 2025, 10:58:24 AM
The routine may require that you explicitly pass a boolean.  If so you can likely define a *VARIANT object, set its type to boolean and value then pass that.

Here is some information on *VARIANT

https://manual.pvxplus.com/PXPLUS/Automation%20in%20PxPlus/PxPlus%20COM%20Interface%20Extensions/Overview.htm#variant
#55
Programming / Re: Working with External obje...
Last post by HendersonS - December 09, 2025, 10:44:29 AM
Devon, According to the documentation, I should send true or false. I even tested it with PowerShell and VB.NET, and it works by sending the parameter false, so the problem seems to be in how PXPlus sends the value to the method.
#56
Programming / Re: Working with External obje...
Last post by Devon Austen - December 09, 2025, 08:38:55 AM
You will have to look at the documentation for the COM object method you are trying to execute. Maybe the arg list is different then you expect?
#57
Programming / Re: ENV Function
Last post by Devon Austen - December 09, 2025, 08:37:06 AM
Here is the documentation for the *windx.utl program. AS Loren said you can use the *windx.utl;get_val to have the env() function run on the local/client machine.

https://manual.pvxplus.com?windx/windxutl.htm
#58
Programming / Re: ENV Function
Last post by Loren Doornek - December 08, 2025, 03:07:18 PM
Use a call to *windx.utl.  For example:

call"[wdx]*windx.utl;get_val","ENV(""SSI_BASE"")",VAL$
PRINT VAL$
#59
Programming / ENV Function
Last post by gmundt - December 08, 2025, 02:36:10 PM
Can the environment function be used to return environment information from a local machine when in client / server using WindX?

? env("SSI_BASE") returns "" because it is checking for the environment variable on the linux server, but I want to check it on my local PC.
#60
Programming / Re: Working with External obje...
Last post by HendersonS - December 08, 2025, 08:42:03 AM
Hi Koe, thanks for your help. Adding * to the constructor worked correctly.



Devon,about the other issue, i can confirm that this method exists. In fact, if we try it without arguments like report'export(), it works, but it displays a dialog box, and we don't want that, I have attached an image of what msg(-1) tells me, but it doesn't give me any indication of how to fix it or what might be causing the exception.