Showing posts with label CMS. Show all posts
Showing posts with label CMS. Show all posts

Monday, 3 February 2025

ProjectWise from Bentley - extend with Powershell

ProjectWise from Bentley - Document Management Software

ProjectWise is a Document Management Solution (DMS) from Bentley.  Its key use case is supporting BIM.

Architecture:  It appears to have a pretty old architecture with the ability to "webify" the DMS.  

Integration: There are APIs and Power Connectors, but they are extremely limited and not developer-friendly. You can also extend the capability using PowerShell. Be warned: Bentley does not support this, but the ProjectWise community does help to solve the issue.

There are add-ins for office software (word, excel, pptx) and some CAD products to make the BIM process easier.

This post outlines how I have extended ProjectWise to build out a pre-populated folder structure using PowerShell.  I then wrap the PS code in an HTTP Azure HTTP-triggered function to call.

Connecting to ProjectWise using PowerShell Example 1:

PS> Import-Module pwps_dab
PS> New-PWLogin -BentleyIMS

Federated login for PS

Note: You need to already have Bentley's federation auth set up on the local machine running the "CONNECTION Client."

Machine running PS must use the CONNECTION Client from Bentley and the user will be prompted to login.

Connecting to ProjectWise using PowerShell Example 2:
Login using Federated identity without a popup to select the datasource

PS> Import-Module pwps_dab
PS> New-PWLogin -Datasource 'org-pw.bentley.com:Org Delivery' -BentleyIMS

Connecting to ProjectWise using PowerShell Example 3:
Login with a local account - No Federated account needed.

PS> $Password = ConvertTo-SecureString "passwrdxxx" -AsPlainText -Force
PS> $Cred = New-Object System.Management.Automation.PSCredential ("my_user_logical", $Password)
PS> New-PWLogin -Datasource 'org-pw.bentley.com:Org Delivery' -UserName $Cred.UserName -Password $Cred.Password

Below are two error codes that tell you if your datasource or login credentials are incorrect.

Example 3.  Error code: 32768 - Datasource not found.


Example 3, this item has the wrong credentials Error code: 58064.



Next: I want to run my ProjectWise (PWPS_DAB module) within a serverless function triggered by HTTP endpoints.  I've chosen Azure Functions using PowerShell.

Problem: PWPS_DAB requires headers, and no serverless function will support PowerShell modules that require interaction/headered calls. 
ERROR: The property 'ThreadOptions' cannot be found on this object. Verify that the property exists and can be set.
... ... ERROR: Failed to load pwps_dab module. Error: Could not load file or assembly 'System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'. The system cannot find the file specified.
 
Initial Hypothesis: There is no way around using PWPS_DAB as it does not support running in a headless mode.  Ouch, and i'm paying for this heavily :)

Possible Resolution: Run a VM or Docker container and expose the function via an HTTP endpoint.  It will be a mission, so i guess it docker. 


To Review: 
https://www.linkedin.com/pulse/understanding-bim-workflow-importance-microstation-yassir-el-yaqouby-ltinf/
https://www.linkedin.com/in/uday-singh-5b18a2155/recent-activity/all/
https://www.linkedin.com/pulse/bim-summary-day-1-introduction-what-building-modelling-uday-singh-d48xc/?trackingId=jVx9vtIRPnylCdD6UVE0ag%3D%3D

AutoDesk Revit

Revit 
https://www.linkedin.com/learning/bim-manager-managing-bim-360
https://www.linkedin.com/learning/search?keywords=Autodesk%20BIM%20360
AutoDesk Construction Cloud

Procore - Project/Construction Management 

https://www.linkedin.com/learning/search?keywords=BIM


Sunday, 1 July 2012

Azure Web Sites

Overview:  I love Azure.  There is just so much we can now do and a new feature released in June 1012.  The "web sites" function in Windows Azure (WA) are extremely flexible and this post shows how you can create a website using various templates in my case a Joomla CMS web site complete with a My SQL database.

There are a lot of options for using Azure web sites such as creating your own web sites in Visual Studio and uploading them to the Web Site role (all for free).  In this post I'm looking at leveraging a CMS to create a web site.  Windows Azure offers up to 10 free web site roles.  There are a lot of templates in the gallery so I feel this is a great place for design agencies and small business that need commercial web sites such as CMS, blogs ect.  They even have the WordPress template.

Steps to get Joomla working:
You will need a Windows Azure (WA) account, you get a free 90 day trial and if you hook your MSDN to it you get a decent amount of extra cloud computing hours thrown in. But for the 10 free "web sites" you don't use your cloud hours - it's free!

Once you are logged into the portal click the Add (+ button on the bottom left of the screen to add new services.  In this case select "Web Site" > "From Gallery" as show below.
Select the "CMS" tab and in my case I chose the "Joomla" template.
 Add the site name and login credentials as prompted (you can add a CName record later).
 The web site is created that backs onto my MySQL database.
Check the url and build your site.
Summary:  Web sites in Azure are easy, they are backed up by MS, there are tons of templates or build your own options, it free.  Microsoft is adding functionality and new services to Azure quickly and is easy to use.