MERGE
Merges another drawing file into this one: its points, elements, variables, pages, library parts and layers become part of this drawing, still parametric. File › Import › Merge Drawing… does the same, choosing the file for you.
Syntax
MERGE "path"
| Argument | Meaning |
|---|---|
| path | The drawing file (.piq), in double quotes. Write each \ in it as \\. It may be a web address (http:// or https://). |
What comes in
- Points and elements keep what they are drawn on and what they follow. Each page's points go onto the page it is merged onto. Where that page already uses a point's number (or this drawing an element's), the merged one gets a new number, and everything merged that refers to it follows (P0, the origin, is shared; so are the corners P1 to P3 while both work them out the same way). A page made for a merged page has its points as they are.
- Variables (L, W and D among them) are added. One this drawing already has is shared if both define it the same way; otherwise the merged drawing's is renamed (W2, say), and everything merged uses the new name, so both drawings keep their sizes. Functions are treated the same way. The settings every drawing has (dimension sizes, the grid, the current layer …) stay this drawing's.
- Pages: a drawing of one page is merged onto the page you are working on. A drawing of several pages is merged onto the pages of the same names, which are made if this drawing doesn't have them (a page whose name is a library part's, or a 3D page's, is renamed).
- Library parts are added (one this drawing has already, the same drawing, is shared; a name that is taken is numbered), and parts placed by name follow. Layers this drawing's layer table doesn't have are added, as are notes this drawing doesn't have.
The Interactive window says what came in: how many elements and points, onto which pages, and which variables were added, shared or renamed.
Examples
MERGE "C:\\Drawings\\lid.piq"
Notes
The drawing must be in the same units as this one: open it, change its units, save it and merge it again. A file that isn't a drawing, or a statement in it that can't be added here, is refused with the reason, and nothing is merged. Undo takes out everything the merge added in one step.
To place a drawing as one piece that keeps its own variables, import it as a part instead (IMPORT).
What a merge brings in becomes this drawing's own, so a merge is never linked: the merged drawing's
linked pictures and library parts are kept in this drawing as they were last read, and its 3D pages'
linked models are named by their full paths. To follow another drawing as it changes, import it as a linked part
(IMPORT "lid.piq",[P4,P5],EMBEDDED=FALSE).
A relative path ("parts/lid.piq", with / or \\ between folders) is read from the drawing's own folder (a
drawing not saved yet reads it from the app's working folder). A drawing opened from a file asks before reading a file
outside its own folder, and can be opened without it: see Files a drawing reads.