Uniface User Forum

 View Only
  Thread closed by the administrator, not accepting new replies.
  • 1.  Uniface 9: Get current ASN file name

    ROCKETEER
    Posted 11-19-2018 11:34
    No replies, thread closed.

    Get current ASN file name

    Author: fearandir@gmail.com (fearandir)

    HI all (again) . We are having some issues involving our uniface configuration enviroment. In our organization we have several development and testing enviroments . Users are free to customize these enviroments. So assignment files name can be/be named different for each user. Do exist a way to get the current ASN filename at runtime? I checked the documentation and found $settings, that retrieves the sections content of a ASN file, but not the name of the ASN file! Thanks, Sergio.



  • 2.  RE: Uniface 9: Get current ASN file name

    ROCKETEER
    Posted 11-19-2018 11:34
    No replies, thread closed.

    Hi Sergio, To resolve your issue, you can add a logical in yours asn with the name of the asn file. I have that in my application. [LOGICALS] asn=C:\...\myasn.asn Regards, Antoine


    Author: apicaud (antoine.picaud@free.fr)


  • 3.  RE: Uniface 9: Get current ASN file name

    ROCKETEER
    Posted 11-19-2018 11:34
    No replies, thread closed.

    That only works if you can trust the users who are changing the asn files to change the logical... 


    Author: Iain Sharp (i.sharp@pcisystems.co.uk)


  • 4.  RE: Uniface 9: Get current ASN file name

    ROCKETEER
    Posted 11-19-2018 11:34
    No replies, thread closed.
    Iain Sharp said That only works if you can trust the users who are changing the asn files to change the logical... 

    Yes. i am really skeptical. If is not featuring, i will create a service that evaluates the logical assignments and if it is not defined, i will assign the default ASN name that is used on production environment and will generate a trace line or log or message or something...   Regards


    Author: fearandir (fearandir@gmail.com)


  • 5.  RE: Uniface 9: Get current ASN file name

    ROCKETEER
    Posted 11-19-2018 11:34
    No replies, thread closed.

    Here's something from the UFO section:

    $1 = $processinfo("cmdline") ; e.g. $1 = ""C:\Program Files (x86)\Uniface\Uniface 9.6.06\common\bin\uniface.exe" /adm="C:\Program Files (x86)\Uniface\Uniface 9.6.06\uniface\adm" /asn=app123.asn appshell

    Please note that this will only work (AFAIK) when using at least Uniface version 9.6.06 plus patch X602 (or higher). And in case the user will provide a different ASN file using the Command Line Dialog Box (that is shown when using "?" on the command line) then the above statement will not show this. Although, I guess it is rather unlikely that something like this would happen often in the field. Also, this particular statement is currently undocumented (and therefore unsupported). So there is the risk that it may be changed or removed in future Uniface versions without notice. Hope this helps. Regards, Daniel


    Author: diseli (daniel.iseli@uniface.com)