Javascript for Digital Dashboards

  • Javascript for Digital Dashboards

    Posted by Doug McLean on March 13, 2021 at 3:32 pm

    I have a collection of Dashboards that I use for my projects. They all have the same basic layout and have buttons for various places that I want to link too.
    Our folder structure is also set up in a consistent manner.
    Does anyone have any JavaScript that I can run to automatically set these links up so I don’t have to set up 10 hyperlinks every time I use one of my Dashboards?

    David Cutler replied 4 months, 2 weeks ago 6 Members · 14 Replies
  • 14 Replies
  • Andrew Veggian

    Member
    March 15, 2021 at 4:51 pm
    Points: 2,607
    Rank: UC2 Brainery Orange Belt UC2 Brainery Orange Belt Rank

    I have used JavaScript for making dashboards more dynamic, but I don’t know of a way to automate the creation of hyperlinks. I do have an idea that might work, but it depends on how your files are named. Are the files always named the same thing (Drawings.pdf, Specifications.pdf, etc.) or are they project-specific (ProjectName_Drawings.pdf, ProjectName_Specifications.pdf, etc.) or do they have random names every time?

  • Doug McLean

    Member
    March 24, 2021 at 5:02 pm
    Points: 6,599
    Rank: UC2 Brainery Purple Belt I UC2 Brainery Purple Belt I

    Yes, most of them are the same.

    They will go to a specific sub folder within our Estimate folder.

    Everything is consistent. Everything is all contained within the same parent folder.

    • David Cutler

      Member
      November 7, 2022 at 11:54 am
      Points: 16,793
      Rank: UC2 Brainery Advanced Blue Belt I UC2 Brainery Advanced Blue Belt I

      Looking back through some older threads and saw this one @Doug McLean (have to study history so I know where to get my hyperlinks from for @Vince ). Did you find a way to simplify this process? If not, perhaps some of those who have joined the Brainery since your original post might have some ideas.😎

      • Vince French

        Member
        November 7, 2022 at 12:15 pm
        Points: 8,115
        Rank: UC2 Brainery Purple Belt III UC2 Brainery Purple Belt III

        😅

      • Doug McLean

        Member
        November 7, 2022 at 1:38 pm
        Points: 6,599
        Rank: UC2 Brainery Purple Belt I UC2 Brainery Purple Belt I

        @lizlarsen is mulling this over as I understand it

        • Liz Larsen

          Member
          November 7, 2022 at 4:55 pm
          Points: 3,374
          Rank: UC2 Brainery Orange Belt I UC2 Brainery Orange Belt I

          I’m still working on it. My optimism fades, though.

          Any method I think of, there are security reasons for disabling JavaScripts ability to do it. Such as JavaScript being able to open folder leads to the possibility of inserting malicious code onto your computer.

          Like, I get it. But at the same time I’m frustrated because I have it planned out in my head and it would be possible if not for security reasons. Ugh.

  • Troy DeGroot

    Organizer
    November 7, 2022 at 4:28 pm
    Points: 16,618
    Rank: UC2 Brainery Advanced Blue Belt I UC2 Brainery Advanced Blue Belt I

    @Doug McLean What are you trying to automate? I’ve seen lots of digital dashboard strategies, here is what I’ve always done:

    1. Create a template project folder structure, Saved on your network.
    2. Save the Template Dashboard in the root directory of that project.
    3. Create all the links, and make sure all your links are set to Relative.
    4. When a new project comes in, make a duplicate where you save your project data, whether that’s a network location or Studio Project. All the paths should remain if you move the entire thing together.

    I saw a video a year ago using javascript to turn layers on/off on a dashboard. I didn’t really understand why they took that approach. It’s a lot easier to create several pages that look different, than to script hiding things on one page.

    I’d love to hear what ideas you guys picked up from @mechave presentation. Digital Dashboards are one of my favorite things to do in Bluebeam.

    • Liz Larsen

      Member
      November 7, 2022 at 4:57 pm
      Points: 3,374
      Rank: UC2 Brainery Orange Belt I UC2 Brainery Orange Belt I

      Coincidentally, my newest video (debuting tomorrow!) goes over a dashboard that uses JavaScript to hide and show layers.

      And you’ll see exactly why JavaScript was used here, rather than creating a bunch of similar pages.

      (P.S. if anyone needs help adding JavaScript to their dashboards, come see me)

      • Troy DeGroot

        Organizer
        November 7, 2022 at 5:11 pm
        Points: 16,618
        Rank: UC2 Brainery Advanced Blue Belt I UC2 Brainery Advanced Blue Belt I

        You might convince me @lizlarsen we’ll see. 🤣

        • Liz Larsen

          Member
          November 7, 2022 at 5:18 pm
          Points: 3,374
          Rank: UC2 Brainery Orange Belt I UC2 Brainery Orange Belt I
    • Doug McLean

      Member
      November 7, 2022 at 5:26 pm
      Points: 6,599
      Rank: UC2 Brainery Purple Belt I UC2 Brainery Purple Belt I

      the folder structure is set, that’s not the issue, its the location of that folder structure within our Jobs/ Estimating Drive.
      Every project has a different starting location, which is the main problem really, even being on SharePoint.
      It would just be nice to not have to set up those initial links.

  • Troy DeGroot

    Organizer
    November 7, 2022 at 9:22 pm
    Points: 16,618
    Rank: UC2 Brainery Advanced Blue Belt I UC2 Brainery Advanced Blue Belt I

    I’m really pulling at straws here, but if you go to the Hyperlink Panel you could Edit Action and paste the Root folder into the front of the path…. For each one… I know….

    Maybe there could be a script for that @lizlarsen

    • Liz Larsen

      Member
      November 8, 2022 at 7:27 am
      Points: 3,374
      Rank: UC2 Brainery Orange Belt I UC2 Brainery Orange Belt I

      This is exactly one of the things I’m looking at.

      With writing JavaScript in Bluebeam, there’s the eternal questions of:

      • Does my code not work because I wrote it wrong?
      • or
      • Does my code not work because it’s not possible?

      With such limited documentation available for what I’m doing, I have no idea if I should continue down some pathways in an attempt to fix my code, or if that will be a fruitless endevour.

      • David Cutler

        Member
        November 8, 2022 at 7:45 am
        Points: 16,793
        Rank: UC2 Brainery Advanced Blue Belt I UC2 Brainery Advanced Blue Belt I

        Perhaps the question needs to be “what do I need to break to make this work?” @lizlarsen 😎