k, nicely put.
your syntax is from version 3 but really nicely done script indeed.
you have done it all?
anyways... I'd suggest something like (I did something similar with my lates groupmapper before got fired
):
Code:
Function ConnectGroupDrives()
If not Exist($FileLocation + "\shares.ini") exit 1 endif
$AllGroups=split(readprofilestring($FileLocation + "\shares.ini","",""),chr(10))
For each $group in $AllGroups
If ingroup($group)
For $x = 1 to 10
$DriveDefinition = ReadProfileString($FileLocation + "\shares.ini", $group, "drive" + $x)
If $DriveDefinition<>""
ConnectShare($DriveDefinition)
EndIf
Next
EndIf
Next
EndFunction
what I would also consider is to change your ini to something like:
[groupName]
S="\\server\share"
then you don't need that much splitting and editing the ini is easier for all.
also, the code can be simplified.
_________________________
!download
KiXnet