Lync Environment Report

This package of PowerShell scripts will gather data on a Lync deployment environment and store it into an XML data file. You can also create Microsoft Word reports and Microsoft Visio network diagrams based upon the data gathered.

 
 
 
 
 
4.8 Star
(37)
9,114 times
Add to favorites
Lync
8/27/2015
E-mail Twitter del.icio.us Digg Facebook
Sign in to ask a question


  • Qurey
    1 Posts | Last post April 12, 2017
    • Can it collect environmental information about the Telephony infrastructure along with the SFB/LYNC Infrastructure
      
      
  • Diagram not working
    5 Posts | Last post February 21, 2017
    • New-LyncEnvDiagram.ps1 : Exception setting "Formula":
      Any solutions wor this?
    • I found the solution to this Problem! Search the script for RGB( and HSL(, then replace the kommas (,) in the parentheses with semicolons.
      
      i. e. RGB(255,255,255) is replaced with RGB(255;255;255)
    • Unfortunately this seems to be because of language localization issues within Visio. With the EN-US version you have to use a , as the separator but other languages seem to require the ;
      
      I have changed the Error Action Preference to Continue so that the script will complete the Visio diagram, it will not however apply the background color to the site container.
    • I also encountered this problem with the latest version of the script, so I tested a bit. If you change the code to e.g. $shpLegendBG.Cells("FillForeGnd").FormulaU (instead of .Formula) in front of every RGB or HSL value. Changing the value from commas to semicolons didn´t work for me.
      
      
    • Gerrit Deike, thanks for the solution: "i. e. RGB(255,255,255) is replaced with RGB(255;255;255)"! It's working for New-LyncEnvDiagram.ps1!
      
  • 3 Errors by running the script
    1 Posts | Last post November 07, 2016
    • 
      Thanks for the script.
      I am trying to run the Visio, it runs with some errors but returns blank visio pages.
      
      1)	In C:\Desktop\Topology Builder\Lync Env Report 
      v5.4_Test1\New-LyncEnvDiagram.ps1:94 line:23 
      
      +     $global:LyncConfig = Import-Clixml "$global:LyncDataXmlFileName"
      +                          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          + CategoryInfo          : OpenError: (:) [Import-Clixml], FileNotFoundException
          + FullyQualifiedErrorId : FileOpenFailu-re,Microsoft.PowerShell.Commands.ImportClixmlCommand 
      
      
      2)	File not found.
      In C:\ Desktop\Topology Builder\Lync Env Report 
      v5.4_Test1\New-LyncEnvDiagram.ps1:148 line:2
      +     $global:colLyncStencils = $VisioApplication.Documents.Add("$Visio ...
      +     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          + CategoryInfo          : OperationStopped: (:) [], COMException
          + FullyQualifiedErrorId : System.Runtime.InteropServices.COMException
       
      3)	You cannot call a method on a null-valued expression.
      In C:\Desktop\Topology Builder\Lync Env Report 
      v5.4_Test1\New-LyncEnvDiagram.ps1:151 line:2
      +     $global:VisioStencils = @{
      +     ~~~~~~~~~~~~~~~~~~~~~~~~~~
          + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
          + FullyQualifiedErrorId : InvokeMethodOnNull 
      
      
      
      It would be great if someone could help me.
      
      Regards,
      frhling
      
      
  • error with multiple policy sections
    1 Posts | Last post August 17, 2016
    • Hi, first a compliment for this great script. It's very usefull.
      If I want to generate an excel report with multiple policy sections I get this error:
      Creating CpsConfiguration policy sheet.
      Exception calling "Add" with "5" argument(s): "A table cannot overlap another table."
      At C:\Tools\Lync Env Report v5.4\New-LyncEnvWorkbookLight.ps1:208 char:3
      +         $objList = $script:CurrentWorkSheet.ListObjects.Add([Microsoft.Office.Interop. ...
      +    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
          + FullyQualifiedErrorId : ComMethodTargetInvocation
      
      The property 'TableStyle' cannot be found on this object. Verify that the property exists and can be set.
      At C:\Tools\Lync Env Report v5.4\New-LyncEnvWorkbookLight.ps1:209 char:3
      +         $objList.TableStyle = "TableStyleMedium20"
      +         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
          + FullyQualifiedErrorId : PropertyNotFound
      
      Any idea how to resolve this issue?
      Regards,
      Mike
  • Visio Generation
    2 Posts | Last post July 12, 2016
    • I am trying to run the Visio generation, it runs but returns blank visio pages.
      It also generates a lot of error messages, examples:
      
      You cannot call a method on a null-valued expression.
      At F:\Downloads\Lync Env Report v5.4\New-LyncEnvDiagram.ps1:295 char:2
      +     $shpLegendBG.Cells("Char.Size").Formula = "16 pt"
      +     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
          + FullyQualifiedErrorId : InvokeMethodOnNull
      
      You cannot call a method on a null-valued expression.
      At F:\Downloads\Lync Env Report v5.4\New-LyncEnvDiagram.ps1:296 char:2
      +     $shpLegendBG.Cells("TextDirection").Formula = 0
      +     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
          + FullyQualifiedErrorId : InvokeMethodOnNull
      
      Property 'Text' cannot be found on this object; make sure it exists and is settable.
      At F:\Downloads\Lync Env Report v5.4\New-LyncEnvDiagram.ps1:297 char:2
      +     $shpLegendBG.Text = $LegendText
      +     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
          + FullyQualifiedErrorId : PropertyNotFound
    • download the Visio "OfficeSymbols_2012and2014" from MS site and re-run the script again,mine works.
  • Visio Issue
    1 Posts | Last post May 10, 2016
    • Is there a fix for this
      You cannot call a method on a null-valued expression.
      At C:\Lync\Lync Env Report v5.4\New-LyncEnvDiagram.ps1:343 char:2
      +     $CurrentStencil.CellsU("LeftMargin").Formula = "0.1 in."
      +     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
          + FullyQualifiedErrorId : InvokeMethodOnNull
      
      
  • I'm getting below error while running .\New-LyncEnvDiagram.ps1
    2 Posts | Last post April 21, 2016
    • **Unable to locate specified file.**
      Opening file picker for data file selection
      OK
      Importing Lync data file to
      *** Starting Time: 07/03/2015 22:22:38 ***
      Creating diagram: C:\Users\xhclsganeshr\Desktop\Script\Lync\Master config\root.localLync_Env_Data-0703150330.vsd
      Creating new instance of Visio to work with.
      New-Object : Cannot load COM type Visio.Application.
      At C:\Users\xhclsganeshr\Desktop\Script\Lync\Script\New-LyncEnvDiagram.ps1:109 char:39
      +     $global:VisioApplication = New-Object <<<<  -ComObject "Visio.Application"
          + CategoryInfo          : InvalidType: (:) [New-Object], PSArgumentException
          + FullyQualifiedErrorId : CannotLoadComObjectType,Microsoft.PowerShell.Commands.NewObjectCommand
      
      Creating new Visio document.
      You cannot call a method on a null-valued expression.
      At C:\Users\xhclsganeshr\Desktop\Script\Lync\Script\New-LyncEnvDiagram.ps1:114 char:57
      +     $global:VisioDocument = $VisioApplication.Documents.Add <<<< ("NETW_U.VST")
          + CategoryInfo          : InvalidOperation: (Add:String) [], RuntimeException
          + FullyQualifiedErrorId : InvokeMethodOnNull
      
      Adding pages to work with.
      You cannot call a method on a null-valued expression.
      At C:\Users\xhclsganeshr\Desktop\Script\Lync\Script\New-LyncEnvDiagram.ps1:117 char:38
      +     $global:VisioPage = $VisioPages.Item <<<< (1)
          + CategoryInfo          : InvalidOperation: (Item:String) [], RuntimeException
          + FullyQualifiedErrorId : InvokeMethodOnNull
      
    • Did you ever get a resolution to this problem?
  • Diagram without any connection
    1 Posts | Last post February 15, 2016
    • Thanks for the script.
      
      Exception calling "get_Cells" with "1" argument(s): "
      
      Unexpected end of file."
      At C:\Lync\New-LyncEnvDiagram.ps1:491 char:15
      +     $SiteBG.Cells <<<< ("LineGradientDir").Formula = "0"
          + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
          + FullyQualifiedErrorId : DotNetMethodException
       
      Exception calling "get_Cells" with "1" argument(s): "
      
      Unexpected end of file."
      At C:\Lync\New-LyncEnvDiagram.ps1:492 char:15
      +     $SiteBG.Cells <<<< ("FillGradientAngle").Formula = "30 deg"
          + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
          + FullyQualifiedErrorId : DotNetMethodException
       
      Exception calling "get_Cells" with "1" argument(s): "
      
      Unexpected end of file."
      At C:\Lync\New-LyncEnvDiagram.ps1:493 char:15
      +     $SiteBG.Cells <<<< ("RotateGradientWithShape").Formula = "TRUE"
          + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
          + FullyQualifiedErrorId : DotNetMethodException
       
      Exception calling "get_Cells" with "1" argument(s): "
      
      Unexpected end of file."
      At C:\Lync\New-LyncEnvDiagram.ps1:494 char:15
      +     $SiteBG.Cells <<<< ("LineGradientAngle").Formula = "90 deg"
          + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
          + FullyQualifiedErrorId : DotNetMethodException
       
      Exception calling "get_Cells" with "1" argument(s): "
      
      Unexpected end of file."
      At C:\Lync\New-LyncEnvDiagram.ps1:495 char:15
      +     $SiteBG.Cells <<<< ("LineGradientEnabled").Formula = "FALSE"
          + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
          + FullyQualifiedErrorId : DotNetMethodException
       
      Exception calling "get_Cells" with "1" argument(s): "
      
  • Visio Diagram Not Working
    2 Posts | Last post June 09, 2015
    • Has anyone got the visio diagram to work correctly?  I am getting the following errors
      
      Adding internal background for site ABC.
      Exception setting "Formula": "
      #NAME?"
      At C:\Downloads\Lync Env Report v5.3\New-LyncEnvDiagram.ps1:448 char:42
      +     $SiteBG.Cells("Prop.width").Formula ="$($SiteWidth) in"
      +                                             ~~~~~~~~~~
          + CategoryInfo          : NotSpecified: (:) [], SetValueInvocationException
          + FullyQualifiedErrorId : ExceptionWhenSetting
      
      Done.
      Adding DMZ background for site ABC.
      Exception setting "Formula": "
      #NAME?"
      At C:\Downloads\Lync Env Report v5.3\New-LyncEnvDiagram.ps1:544 char:42
      +     $DmzBG.Cells("Prop.width").Formula = "$($SiteWidth) in"
      +                                             ~~~~~~~~~~
          + CategoryInfo          : NotSpecified: (:) [], SetValueInvocationException
          + FullyQualifiedErrorId : ExceptionWhenSetting
    • Ok so I resolved this by adding extra lines in the script by declaring the following variable: $SiteWidth = 6 under the functions Add-SiteBG and Add-SiteDMZBG
      
  • Missing Style?
    3 Posts | Last post May 19, 2015
    • 
      Creating PrivacyConfiguration policy table.
      Exception setting "Style": "Item with specified name does not exist."
      At C:\temp\New-LyncEnvReport.ps1:418 char:2
      +     $NewTable.Style = $script:TableStyleName
      +     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          + CategoryInfo          : NotSpecified: (:) [], SetValueInvocationException
          + FullyQualifiedErrorId : CatchFromBaseAdapterSetValueTI
      
      Im checking and it seems "Grid Table 4 - Accent 1" doesnt exist in word 2010... where did you get this? and is there another alternative?
    • I fixed it .. simply changed it to ="Light Grid - Accent 1"
    • Where did u get the name "Light Grid - Accent1" from? I am trying to get this to work with a German version of Word 2010 but i cant find the german expressions for the table style.
1 - 10 of 28 Items