2

My script call many other script and i need know each fullname (for log info).

but the same command doesn't work in Powershell_ISE

2

This code are avaible in Powershell_ISE and in script.ps1 file

function Get-ScriptFullName () { 
    if($hostinvocation -ne $null) {
        $hostinvocation.MyCommand.path
    } else {
        $script:MyInvocation.MyCommand.path
    }
}
| improve this answer | |

Not the answer you're looking for? Browse other questions tagged or ask your own question.