Access – Organizational Charts

Organizational Chart

Once again, looking to provide clients with better features within my Access applications, I turned my attention to creating Organizational Charts.

In this instance, I used Google Charts, but as with all web driven solution there are a multitude of other libraries to choose from, it’s just a question of finding the one that makes you happy, or creating your own!  Here are a few I came across while exploring creating Org. Charts should you ever wish to see what else may be possible:

 

Here are a few screenshots to show you a little of what the demo has to offer.

Access - Organizational Chart - SimpleAccess - Organizational Chart - AdvancedWhat’s also nice here is that you can output the Org. Chart to a normal web browser to easily share it out with others, print (since we can’t use it in Access reports – see Limitations below).

I hope this will prove useful to some of you out there!

Limitations

The current limitation is the fact that the WebBrowser control cannot be used in continuous forms, nor reports. I’m hopeful that whenever the new WebBrowser control gets released that we will finally be able to get around that limitation. Fingers crossed.

One things that I have done though, is build out a form and then inserted that into the report to manage to get it to display visually in a report, but printing still omits the WebBrowser rendering. So if your report is only viewed on a screen, this can be an effective workaround.

Setup & Usage

Disclaimer/Notes:

If you do not have Microsoft Access, simply download and install the freely available runtime version (this permits running MS Access databases, but not modifying their design):

Microsoft Access 2010 Runtime
Microsoft Access 2013 Runtime
Microsoft Access 2016 Runtime
Microsoft 365 Access Runtime

All code samples, download samples, links, ... on this site are provided 'AS IS'.

In no event will Devhut.net or CARDA Consultants Inc. be liable to the client/end-user or any third party for any damages, including any lost profits, lost savings or other incidental, consequential or special damages arising out of the operation of or inability to operate the software which CARDA Consultants Inc. has provided, even if CARDA Consultants Inc. has been advised of the possibility of such damages.

Download a Demo Database

Feel free to download a 100% unlocked demo copy by using the link provided below:

Download “Access - Organizational Charts” Google-OrgChart.zip – Downloaded 7036 times – 40.68 KB

Version History

Version Date Changes
V1.000 2022-06-13 Initial Public Release

Other References on the Subject

9 responses on “Access – Organizational Charts

  1. Robert Simard

    Dans ta deuxième capture d’écran, tu as ajouté des lignes (titres, tél et une ligne de séparation), est-ce que c’est une méthode du google.charts ou bien tu as utilisé des balises HTML ? , car elle n’apparaissent pas dans ton demo.

    Merci pour le partage !

  2. Mohsin

    Hi Daniel,

    Thanks for the great post, the demo is not functional and return Line: 2 Error: ‘google’ is undefined. Can you please check? One question, do you have any demo to try for the second screenshot you posted above?

    1. Daniel Pineault Post author

      No demo, it is all in the Google documentation, you can pass HTML to the API. You can customize the CSS as well, like with any HTML document.

      As for the error, you need to follow the suggestions on the WebBrowser page listed in the references. That specific error, I have only seen when there is no Internet connection. Regardless, the demo works perfectly, so it is a setup issue on your end.

  3. Raed Ajailat

    Daniel with all respect you didn’t answer the above 2 questions, while Your answers are vague and we cannot understand them
    we are not developers

    1- second screenshot, you added lines (titles, phone and a separator line) and they don’t appear in your demo, kindly can you add a new demo or write us the code
    2- the demo is not functional – Do we have to add Reference to the database , coz its also not working with me

    1. Daniel Pineault Post author

      The demo is fully functional, as is. Perhaps you haven’t set the browser emulation? Just a guess.

      As for the screenshot, it is simply a question of passing the proper HTML to the org chart. So you can create HTML span, use tags like
      to make multiple lines, etc… Look over the demos on Google sites, it give various demonstrations on how some of this can be formatted, but it really just comes down to building HTML content and passing it to the function to display.

      I’ll see if I can perhaps put together a video in the coming week or two.

  4. raed ajailat

    I find how to add Title to the chart under the Employee name
    just Change : sText = sText & ![EmployeeName] To :
    sText = sText & “” & ![EmployeeName] & “” & “” & Nz(![Title]) & “”

    Hope this will help

  5. raed ajailat

    Sorry , this is the code :

    sText = sText & “” & ![EmployeeName] & “” & “” & Nz(![Title]) & “”

    1. Daniel Pineault Post author

      Just a question of building HTML. You can use all the standard tags: ‘strong’, ’em’, ‘u’ …. use ‘br’ to split content on multiple lines…. You can use styles, define classes … The sky is the limit.