You can expand ..\frag to its full path with resolve-path:
PS > resolve-path ..\frag
Try to normalize the path using the combine() method:
[io.path]::Combine("fred\frog",(resolve-path ..\frag).path)
More Related Contents:
- Create objects with custom properties containing derived filesystem path information and export them to a CSV – calculated properties
- How can I make PowerShell handle [ or ] in file name well?
- String handling from Powershell script
- Powershell script to delete 15 days old .txt files [duplicate]
- How to create a zip archive with PowerShell?
- How to run an EXE file in PowerShell with parameters with spaces and quotes
- Fastest Way to get a uniquely index item from the property of an array
- PowerShell script to check an application that’s locking a file?
- PowerShell script runs when pasted into the PowerShell window, but not when run from shortcut
- Lambda Expression in Powershell
- save PSCredential in the file
- How do I write a PowerShell script that accepts pipeline input?
- How do I Start a job of a function i just defined?
- PowerShell: Unable to find type when using PS 5 classes
- Pass object[] into a function in PowerShell
- try, catch doesent seem to work
- Specifying *.xls filter in Get-ChildItem also returns *.xlsx results
- Inserting a date into SQL
- Prompt for user input in PowerShell
- Delete all files and folders but exclude a subfolder
- Start-Process with PowerShell.exe exhibits different behavior with embedded single quotes and double quotes
- How to split string by string in Powershell
- Powershell: Colon in commandlet parameters
- Why is $false -eq “” true?
- powershell function switch param with string array
- In Powershell what is the idiomatic way of converting a string to an int?
- PowerShell is missing the terminator: “
- Using PowerShell to remove lines from a text file if it contains a string
- How to execute a PowerShell script only before a web deploy Publish task in VS 2012?
- Powershell – Output Color for certain results