Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- clear
- Function Get-FileName($initialDirectory)
- {
- [System.Reflection.Assembly]::LoadWithPartialName("System.windows.forms") | Out-Null
- $OpenFileDialog = New-Object System.Windows.Forms.OpenFileDialog
- $OpenFileDialog.initialDirectory = $initialDirectory
- $OpenFileDialog.filter = "All files (*.*)| *.*"
- $OpenFileDialog.ShowDialog() | Out-Null
- $OpenFileDialog.filename
- } #end function Get-FileName
- # *** Entry Point to Script ***
- $Location = Convert-Path (Get-Location)
- $a = Get-Content(Get-FileName -initialDirectory $Location)
- $b = Get-Content(Get-FileName -initialDirectory $Location)
- Compare-Object -referenceObject $a -differenceObject $b | Format-Table | Out-File ($Location + "\Compared.txt")
Advertisement
Add Comment
Please, Sign In to add comment