|
創建個DELPHI腳本' r* X n& h% w' [# D' ]
/ [, u4 F! S$ K% N# x5 b/ y# E
Procedure RemoveCompID;
& E: I. b k4 |7 @5 d6 j* [. IVar3 C! A0 S( ~; M
Component : IPCB_Component;# G* d' P7 Q5 e% W
ComponentIteratorHandle : IPCB_BoardIterator;& W& b$ }. ^1 _
Begin- R4 V* Y, ~1 l3 x; t8 K
If PCBServer.GetCurrentPCBBoard = Nil Then Exit;
# k; M. ~; n7 z+ _9 ]) ?( c ComponentIteratorHandle := PCBServer.GetCurrentPCBBoard.BoardIterator_Create;
+ b( r1 E% v8 G& m ComponentIteratorHandle.AddFilter_ObjectSet(MkSet(eComponentObject));2 H; i, ^4 g: E# f3 m+ A# x( R
ComponentIteratorHandle.AddFilter_LayerSet(AllLayers);' V5 A S/ x9 d y; ~ q
ComponentIteratorHandle.AddFilter_Method(eProcessAll);
- q7 n% n, g6 k4 F Component := ComponentIteratorHandle.FirstPCBObject;
' g E) O# ^+ W9 D* H While (Component <> Nil) Do
) {2 L* ~" B) B8 P7 J- W Begin
6 z5 g" S2 ^' I3 ^, K- R6 Q Component.SourceUniqueId := '';
: U/ l( K/ o+ n. Q Component := ComponentIteratorHandle.NextPCBObject;
]1 y7 O! c: L/ z/ @5 B End;
5 k3 M$ D4 b( p, G PCBServer.GetCurrentPCBBoard.BoardIterator_Destroy(ComponentIteratorHandle);* D1 T$ q: ~2 U2 R
End; |
|