spikeman24
MIS
Hi
I have a vbscript file that includes some functions and that generates a text file as seen below. The next step in my automation quest is to perform a secondary task/command/function of all URL’s containing Using the example below I would need to run the command on 6 URL’s (the command does not need to run on the first primary URL)
I've been reading about arrays and was wondering how to create a dynamic array for all the site URL's (- the first one) in my text file then may excute the command for every line within the array.
----------------------------------------------------------------------------------
<Sites Count="7">
<Site Url=" Owner="LAB1\fred.sa" />
<Site Url=" Owner="ITN\bob" SecondaryOwner=" ITN\jack" />
<Site Url=" Owner=" ITN\jill" />
<Site Url=" Owner=" ITN\bart" SecondaryOwner=" ITN\maggie" />
<Site Url=" Owner=" ITN\homer" SecondaryOwner=" ITN\mo" />
<Site Url=" Owner="ITN\maggie" SecondaryOwner=" ITN\homer" />
<Site Url=" Owner="ITN\lisa" SecondaryOwner=" ITN\maggie" />
</Sites>
----------------------------------------------------------------------------------
I’m new to vbscripting, so any help with this would be greatly appreciated. Also I'm not sure if I have explained myself as best as I can, let me know if I should start again.
Kind Regards
Herschel
I have a vbscript file that includes some functions and that generates a text file as seen below. The next step in my automation quest is to perform a secondary task/command/function of all URL’s containing Using the example below I would need to run the command on 6 URL’s (the command does not need to run on the first primary URL)
I've been reading about arrays and was wondering how to create a dynamic array for all the site URL's (- the first one) in my text file then may excute the command for every line within the array.
----------------------------------------------------------------------------------
<Sites Count="7">
<Site Url=" Owner="LAB1\fred.sa" />
<Site Url=" Owner="ITN\bob" SecondaryOwner=" ITN\jack" />
<Site Url=" Owner=" ITN\jill" />
<Site Url=" Owner=" ITN\bart" SecondaryOwner=" ITN\maggie" />
<Site Url=" Owner=" ITN\homer" SecondaryOwner=" ITN\mo" />
<Site Url=" Owner="ITN\maggie" SecondaryOwner=" ITN\homer" />
<Site Url=" Owner="ITN\lisa" SecondaryOwner=" ITN\maggie" />
</Sites>
----------------------------------------------------------------------------------
I’m new to vbscripting, so any help with this would be greatly appreciated. Also I'm not sure if I have explained myself as best as I can, let me know if I should start again.
Kind Regards
Herschel