Button on PO screen to launch custom EDD application

SOLVED

Working to create a custom button on X3, v6 PO screen to launch a custom application to send the PO via EDD.  We've created a button but upon selecting it X3 just spins and never produces the external application.  Any thoughts out there or anybody done something similar?  I'll have our programmer provide more details if needed,  thanks!

  • 0 in reply to Delamater
    We've successfully executed our button while displaying a text box, but as we try to yield a webpage that links into our external application we can't seem to generate it. We are on v6, the webclient version, not sure if that makes a difference. Can you direct me to the location where we can review the permissions?

    Below is the statement we've added to the SPEPOH processing.
    Subprog CL_ZPRINT(VALEUR)
    Variable Char VALEUR()
    #System CHAINE = '#@"C:\Test\Test.exe"'
    #Local Integer YN : YN = 2 :# By default points on Yes
    #Call OUINON(“Do you want to continue?”, YN) From GESECRAN
    Callui RETOUR = "" With "UIAction="+chr$(1)+"OpenFile",
    & "UILocalDir="+chr$(1) + "HTTP",
    & "UILocalFile="+chr$(1) + "google.com",
    & "UIAdxPubSubFile=" + chr$(1) +"1"
    End
  • 0 in reply to Bryan Mulder
    Some progress on this one. We are able to return a webpage but we can't seem to pass a specific webpage, we are directed towards http://0.0.0.0/ as we select the button.
  • 0 in reply to Bryan Mulder
    verified answer
    we just found a webpage that assisted in achieving the PO button to yield a webpage, thanks!
  • 0 in reply to Bryan Mulder
    verified answer
    On version 6 you can use the following code to launch a google browser. This works on my system. Your code looks like it should work. Perhaps remove that UIAdxPubSubFile and follow this example directly and see if google will even open first. If it does, then we can take a look a bit further. If it doesn't, then perhaps you are being blocked in some way?

    Anyways, here's the code and my approach:

    Callui RETVALUE="" With "UIAction=" + chr$(1) + "OpenFile",
    & "UILocalDir=" + chr$(1) + "HTTPS",
    & "UILocalFile=" + chr$(1) + "www.google.com"


    To do this, I simply did the following:
    1. Add a new button to your screen
    - Data type = "A"
    - Input = Enter
    - Mandatory = No
    - Graphic Object = Icon
    - Default value - I gave it 102, but you can use something else

    2. Parameters for this button are
    - Type = Click
    - ACtion = SPE
    - Execution = Interactive
    - Deactivation = None

    3. In my SPE I put the code above

    4. Globally validate the window
    - Launch GESAWI
    - Bring up your window record
    - At the top press the global validation button


    Then when you launch the screen you can launch the browser.

    Just a note, CALLUI is deprecated in the newer style programming, so when you get to that point you'll need to alter your coding.



    Hope this helps.

    Bob
  • 0 in reply to Delamater
    Looks like we crossed updates there. So you are good then? If so, I'll mark this issue closed.

    Glad you have it working.
  • 0 in reply to Delamater
    yup, all good, thanks Bob. We do plan to upgrade to product update 9 or 10 in 2017, sounds like we may need to revamp then. thanks again!
  • 0 in reply to Bryan Mulder
    One issue has popped up. The button works great for our normal PO creation. But when attempting to create PO's from the subcontract screen an error pops up with the below details instead of generating a PO:

    errn='10'
    errp='@MSCTEST>TRT/W0POH0$adx
    errl='205'
    errm='st_val : Type incompatibility'

    I've isolated this to be generating from the button, not the code in the SPE. Any thoughts on this one?
  • 0 in reply to Delamater

    Is it possible to use CallUI to pull an html file I have created on the server?