Exclusively for TechExams members for Infosec Boot Camps starting before April 30, 2026
ECHO "-------------------------------------------" >> "%userprofile%\Desktop\shares.txt" ECHO %computername% >> "%userprofile%\Desktop\shares.txt" ECHO "-------------------------------------------" >> "%userprofile%\Desktop\shares.txt" NET SHARE >> "%userprofile%\Desktop\shares.txt" ECHO "-------------------------------------------" >> "%userprofile%\Desktop\shares.txt"
jetdynamics wrote: » @HeroPsycho We dont need to specify the server just all the computers thats plug into the network, Maybe you have another idea just for the computer by using certain IP range? Thanks guys for taking time to answer my questions , I really appreciate the help.
[string]$subnet = "192.168.1." $StartHosts = 100 $EndHost = 200 for($i = $StartHost; $i -le $EndHost; $i++) { $ComputerName = $subnet+$i #Body of script. }
$ips = 2..254 | %{"192.168.1." + $_}
RobertKaucher wrote: » @Hero - Thanks for almost always teaching me something cool in PoSh with your posts!
Exclusively for TechExam members. Applies to boot camps starting before April 30, 2026.