APPLICATION_​​QUERY slows down moveable hotspots

Home Forums Problems and solutions in GDL Informations from the environment APPLICATION_​QUERY slows down moveable hotspots

Viewing 5 reply threads
  • Author
    Posts
    • #18671
      Joachim Sühlo
      Participant

      I have 2 APPLICATION_QUERYs in Master Script for user image files.
      In 2D I have moveable hotspots which are extremly slow.
      I wondered what the reason was and found out that it where those APPLICATION_QUERYs.
      If I comment them out, hotspots move very fast.
      If I write “IF GLOB_FEEDBACK_MODE = 0” before the queries,
      the hotspots are moving a bit faster, but not as fast as normal.
      Is there any way to get the normal speed and keeping the queries in the script?

      GDL Object Developer
      b-prisma
      MAC OSx 10.12

    • #18672
      Péter Baksa
      Keymaster

      Hm, what are you doing with the result? If it is stored as an array in a parameter, you might still use it GLOB_FEEDBACK_MODE.

      What ArchiCADLibrary does is it calls the request in ARCHICAD_Library_Master (in subtype “Library Master”), which is only run when the library is loaded. The results are set with VALUES to a parameter. All libparts that have the same parameter get their values from the Library Master.

      Péter Baksa
      Library Platform, Software Engineer
      GRAPHISOFT SE

    • #18673
      Joachim Sühlo
      Participant

      The script part I use is:

      ! ———————————————————————- !
      ! ————— C u s t o m p i c t u r e f i l e r e q u e s t
      ! ———————————————————————- !

      IF GLOB_FEEDBACK_MODE = 0 THEN

      dim stCustomPicFiles[]
      bCustomPicFileExist = APPLICATION_QUERY (“LIBRARY_MANAGER”, “USER_IMAGE_FILES”, stCustomPicFiles)

      p_num = VARDIM1(stCustomPicFiles)

      DIM stCustomPicFiles_with_prefix[]
      si = 1
      int_num_prefix = STRLEN(str_prefix)

      IF (str_prefix # ” ” AND str_prefix # “”) THEN
      FOR i = 1 TO p_num
      IF STRSUB(stCustomPicFiles[i], 1, int_num_prefix) = str_prefix THEN
      stCustomPicFiles_with_prefix[si] = stCustomPicFiles[i]
      si = si + 1
      ENDIF
      NEXT i
      ELSE
      stCustomPicFiles_with_prefix = stCustomPicFiles
      ENDIF

      p_num = VARDIM1(stCustomPicFiles_with_prefix)

      ENDIF

      GDL Object Developer
      b-prisma
      MAC OSx 10.12

    • #18683
      Péter Baksa
      Keymaster

      Are you changing any parameter based on stCustomPicFiles_with_prefix? Is it used as VALUES?

      Péter Baksa
      Library Platform, Software Engineer
      GRAPHISOFT SE

    • #18684
      Joachim Sühlo
      Participant

      Yes:
      IF p_num > 0 THEN VALUES “str_bildwahl” stCustomPicFiles_with_prefix

      GDL Object Developer
      b-prisma
      MAC OSx 10.12

    • #18688
      Péter Baksa
      Keymaster

      I am not sure, maybe it is related to the VALUES command, but that is just a wild guess.
      Maybe you could try CUSTOM_POPUP_INFIELD in the UI script, then VALUES is not needed, and the UI script surely isn’t run in feedback mode.

      Péter Baksa
      Library Platform, Software Engineer
      GRAPHISOFT SE

Viewing 5 reply threads
  • The forum ‘Informations from the environment’ is closed to new topics and replies.