Hi Bharadwaj
Symbols on the root schematic don't have a '\' in the name so it will fail on the split.
So either do a check (if instr(objComp.GetName(0),"\") <> 0 then) before the split or you can add the root schematic so it always is an array
DesignName = vdapp.GetActiveDesign()
RootName = Vdapp.GetProjectData().getiCDBDesignRootBlock(DesignName)
for ...
CompfullparthWithRoot = RootName & "\" & objComp.GetName(0)
tempsplittkk = Split(CompfullparthWithRoot, "\")