Set productDocument1 = CATIA.ActiveDocument
Set selection = productDocument1.Selection
Set visPropertySet = selection.VisProperties
Set product1 = productDocument1.Product
Set products1 = product1.Products
For i=1 to products1.Count
Set productI= products1.Item(i)
Set products1 = producti.Parent
selection.Add producti
Set visPropertySet = visPropertySet.Parent
visPropertySet.GetShow showstate
selection.Clear
If showstate <> 1 Then '隐藏为1
If not(Instr(products1.Item(i).PartNumber,strName)) Then
j=j+1
str = CStr(int(j))
if j<10 then
str = "0" & str
end if
Set iparameter1 = parameters1.CreateString("CATEGORIE", Cstr("BED"))
Set iparameter2 = parameters1.CreateString("REPERE", Cstr("101"))
end if
end if
Next
End Sub
这段代码怎样修改使隐藏的零件不添加属性!