Hi Team i am trying to create a folders using the power shell comand i have saved the below script in a text file and then i use the read text file activity and save the output in a variable
using the below scipt
Specify the path
$path = “C:\”
Specify the folder name
$folderName = “NewFolder”
Combine the path and folder name
$fullPath = Join-Path -Path $path -ChildPath $folderName
Check if the folder already exists
if(Test-Path -Path $fullPath)
{
Write-Output “Folder $fullPath already exists.”
}
else
{
# Create a new folder
New-Item -ItemType Directory -Path $fullPath
Write-Output “Folder $fullPath has been created.”
}
In the “command text” i save the varaiable which i created in the read text activity
What shoud be the Input and parameters in this case?
i have ticked the “isScript” box.
whats should be the PowerShellVaraiables and TypeArgument