Announcement

Collapse
No announcement yet.

How to create global variables init procedure ?

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • How to create global variables init procedure ?

    Hello,

    I would like to know how to create a procedure which initialize global variables when I start my project.

    I try this but it doesn't work :

    - in project library I place a function which initialize variables from a parameter table in database
    - in my menu application , in OnApplicationInit I add a call of this function

    The error message is "Connection to database error " because there is no DB acces in menu application !!!
    If, I check my library in Application Library, I cannot save due to the same db error

    Thanks in advance

  • #2
    If you need access to the database then you need to use the onload event.
    Albert Drent
    aducom software netherlands
    scriptcase partner, reseller, support and (turn-key) development
    www.scriptcase.eu / www.scriptcase.nl

    Comment


    • #3
      Using a function call (located in a project library) in On Applicationinit, onexecute or onload in MENU application , the message is "Connection or database access profile undefined", because in MENU application there is no SQL connection.

      How to add it or how to do it in an another way

      Thanks

      Comment


      • #4
        If you have a default application in your menu you could declare your vars there. I useually do that in my logon page.
        Albert Drent
        aducom software netherlands
        scriptcase partner, reseller, support and (turn-key) development
        www.scriptcase.eu / www.scriptcase.nl

        Comment


        • #5
          Ok, I see what you mean !!

          I'll try it but I think this solution will be resolve my problem

          Thank you

          Comment

          Working...
          X