|
創建個DELPHI腳本( O' i0 H4 I- Z3 D, h
1 |0 u( X" d) y+ ?2 k
Procedure RemoveCompID;
- ~# {. Q, r/ h3 uVar
- o+ m5 ^% K' O& s' I, e Component : IPCB_Component;0 C o9 ?, f6 ^: F/ L
ComponentIteratorHandle : IPCB_BoardIterator;
6 ^6 D V0 g4 K# tBegin9 d1 O) h5 l, t* _) e+ _
If PCBServer.GetCurrentPCBBoard = Nil Then Exit;) K# Q! [8 {) [$ P( S
ComponentIteratorHandle := PCBServer.GetCurrentPCBBoard.BoardIterator_Create;
. V# e5 e) m; ~" R7 _ ComponentIteratorHandle.AddFilter_ObjectSet(MkSet(eComponentObject));
& e: k- Z! Q% Q: t3 T0 l ComponentIteratorHandle.AddFilter_LayerSet(AllLayers);
' d7 x( g: l2 D2 g' }! V ComponentIteratorHandle.AddFilter_Method(eProcessAll);
* J/ C3 O& I% y6 Y Component := ComponentIteratorHandle.FirstPCBObject;
/ h2 u1 x2 B9 j& D. i While (Component <> Nil) Do/ \: R b) ], i+ A! k" X4 n* ~% E
Begin
8 V. G' Z. O, U9 N/ M* n Component.SourceUniqueId := '';
5 \/ q: \: a3 }7 B( X& Z Component := ComponentIteratorHandle.NextPCBObject;
8 {6 \. Z# R4 g1 }6 H End;
) r, r% H: \% E PCBServer.GetCurrentPCBBoard.BoardIterator_Destroy(ComponentIteratorHandle);
' w8 k) ?# N3 Z S4 W' ~+ g' }) bEnd; |
|