> For the complete documentation index, see [llms.txt](https://saveenr.gitbook.io/visiopowershell/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://saveenr.gitbook.io/visiopowershell/visiops_v3/technical-notes/use-visioautomation.md).

# Use VisioAutomation

Sometimes you may need to directly use types in the VisioAutomation assembly. The sample below shows you how to load it into your PowwerShell session

```
Set-StrictMode -Version 2
$ErrorActionPreference = "Stop"

import-module Visio

# Load the needed DLLs
$sc = Get-VisioScriptingClient
$sc.Assemblies | %{ Add-Type -Path $_ }

$p = New-Object VisioAutomation.Geometry.Point(1,2)
$r = New-Object VisioAutomation.Geometry.Rectangle(1,2,3,4)
$pinx_src = [VisioAutomation.ShapeSheet.SRCConstants]::XFormPinX
```
