如下结构的脚本,我想在switch下的脚本执行完毕之后能返回到初始选择阶段再次选择,请问如何做到?
“1,xxxx”
“2,xxxx”
“3,xxxx”
$answer=read-host “Please enter which function you want to use”
function a{…}
function b{…}
function c{…}
switch($answer){
‘1’{a}
‘2’{b}
‘3’{c}
}
0 Answers
如下结构的脚本,我想在switch下的脚本执行完毕之后能返回到初始选择阶段再次选择,请问如何做到?
“1,xxxx”
“2,xxxx”
“3,xxxx”
$answer=read-host “Please enter which function you want to use”
function a{…}
function b{…}
function c{…}
switch($answer){
‘1’{a}
‘2’{b}
‘3’{c}
}