Bentley Communities
Bentley Communities
  • Site
  • User
  • Site
  • Search
  • User
ProjectWise
  • Product Communities
ProjectWise
ProjectWise PowerShell Extensions Forum Export / search in Local Doument Organizer dashboard
    • Sign In

    • State Verified Answer
    • Replies 2 replies
    • Subscribers 66 subscribers
    • Views 277 views
    • Users 0 members are here
    • Export
    • PWPowerShell
    • ProjectWise

    Export / search in Local Doument Organizer dashboard

    Dániel Lehoczky
    Offline Dániel Lehoczky 11 months ago

    Hi,

    I am dealing with a long list of exported and locked documents, in which I need to make selections based on keywords in Export folder / Export comment file properties.

    Is there a way to search in Local Document Organizer dashboard, or alternatively export a list of file properties from here?

    • Sign in to reply
    • Cancel

    Top Replies

    • Kevin van Haaren
      Offline Kevin van Haaren Wed, Oct 26 2022 3:17 PM +1 verified
      Unfortunately no. Programmatically you have to go to the audit trail to get the info. I built a quicky test. First I created a saved search to show me files I had exported. Then I could do: $pwDocs…
    • Kevin van Haaren
      +1 Offline Kevin van Haaren Wed, Oct 26 2022 3:17 PM

      Unfortunately no. Programmatically you have to go to the audit trail to get the info.

      I built a quicky test. First I created a saved search to show me files I had exported. Then I could do:

      $pwDocs = Get-PWDocumentsBySearch -SearchName 'path\to\workarea\searchname' -Personal
      ForEach ($pwd in $pwDocs) {
          # get last export action
          $at = $pwd | Get-PWDocumentAuditTrailRecords | Where Action -eq 'Document Export' | Sort Action_Time -Descending
          if ($at.count -gt 0) {
              $at = $at[0]
          }
          
          # Get export node and export path
          ($expNode,$expPath) = ($at.Text_Param).Split('|',2)
      }
      

      the get last export action gets the Document Export audit trail records for the document, it then sorts them newest to last and if there are more than 1, discards all but the most current

      Then inside that record the node the file was exported on and the path it was exported to are in the Text_Param property. The split divides them into two entries at the first | and assigns them to the appropriate variables.

       

      Answer Verified By: Dániel Lehoczky 

      • Cancel
      • Vote Up +1 Vote Down
      • Sign in to reply
      • Reject Answer
      • Cancel
    • Dániel Lehoczky
      0 Offline Dániel Lehoczky Thu, Oct 27 2022 6:27 AM in reply to Kevin van Haaren

      Thank you Kevin!

      • Cancel
      • Vote Up 0 Vote Down
      • Sign in to reply
      • Verify Answer
      • Cancel

    Communities
    • Home
    • Getting Started
    • Community Central
    • Products
    • Support
    • Secure File Upload
    • Feedback
    Support and Services
    • Home
    • Product Support
    • Downloads
    • Subscription Services Portal
    Training and Learning
    • Home
    • About Bentley Institute
    • My Learning History
    • Reference Books
    Social Media
    •    LinkedIn
    •    Facebook
    •    Twitter
    •    YouTube
    •    RSS Feed
    •    Email

    © 2023 Bentley Systems, Incorporated  |  Contact Us  |  Privacy |  Terms of Use  |  Cookies