EvotecIT / PSWinDocumentation

PowerShell Module that creates Word/Excel/SQL documentation from Active Directory (AD), AWS, Office 365 and others. It's a work in progress!
MIT License
251 stars 39 forks source link

Not working? #2

Closed jeremyjenkins5 closed 6 years ago

jeremyjenkins5 commented 6 years ago

I installed based on the information here: https://evotec.xyz/hub/scripts/pswindocumentation-powershell-module/

However when I run: Start-ActiveDirectoryDocumentation -CompanyName 'Evotec' -FilePath $FilePath -OpenDocument Nothing seems to happen.

Here is what I've done:

  1. Downloaded and Imported PSWriteWord Import-Module PSWriteWord

  2. Downloaded and Imported PSWinDocumentation Import-Module PSWinDocumentation

  3. Downloaded and Installed Windows RSAT tools

  4. Installed the two modules from 1. and 2.

    Install-Module PSWriteWord -Force
    Install-Module PSWinDocumentation -Force

Did I miss a step somewhere? Thanks!

PrzemyslawKlys commented 6 years ago

$FilePath defined? You need to provide $FilePath = C:\Users\UserName\Desktop\somedoc.docx ?

Otherwise I need error you get?

jeremyjenkins5 commented 6 years ago

Yes, I defined $FilePath to match the example. Screenshot of the error I get.

screen shot 2018-08-02 at 1 20 44 pm

PrzemyslawKlys commented 6 years ago

You have to type all of that

Import-Module PSWInDocumentation
Import-Module PSWriteWord
Import-Module ActiveDirectory

$FilePath = "$Env:USERPROFILE\Desktop\PSWriteWord-Example-Report.docx"

Start-ActiveDirectoryDocumentation -CompanyName 'Your Company' -FilePath $FilePath -OpenDocument -Verbose

Or run this as .ps1

jeremyjenkins5 commented 6 years ago

Alright, that worked! I'm embarrassed it was so simple. Thanks for the help!

PrzemyslawKlys commented 6 years ago

No problem. Happens. Actually it should work without it as long as I would define this module properly. But it's an alpha so it requires Import-Module explicitly.