Jump to content

Nico_be

Member
  • Posts

    154
  • Joined

  • Last visited

Everything posted by Nico_be

  1. Hallo, Here is un script found on another site. This script place all symbol include in the file, in all folders, on the drawing. Marvelous to create after that a tablelist and edit directly in the table. But the script crashes at the end of the process!! is somebody could take a look at it and see the error? Pleeaase ! :crazy: PROCEDURE ShowAllSymbols; {?1999 Graphsoft, Inc.} {The traverseSymbolList procedure was developed by Craig Hollinshead.} VAR numFolders, numNestedFolders, numSymbols : INTEGER; messageString : STRING; OK : BOOLEAN; NewPtSize : INTEGER; OldPtSize : INTEGER; SelectedObj : HANDLE; TheSymbolName : STRING; SymFolderName : STRING; TheSymDef : HANDLE; SymDef2 : HANDLE; ChangeAllLines : BOOLEAN; CurrLayer : HANDLE; X,Y : REAL; XSpacing, YSpacing : REAL; NumAcross : INTEGER; StartX,StartY : REAL; LayerNames : ARRAY[0..200] OF STRING; Index : INTEGER; {=============================================================================} PROCEDURE TraverseSymbol(theSym:Handle); VAR symObjClass : STRING; origLineWt : INTEGER; symName : STRING; symInstance : HANDLE; sX1,sX2,sY1,sY2 : REAL; BEGIN symName := GetSDName(theSym); symName := GetName(theSym); Symbol(symName,X,Y,0); symInstance := LNewObj; GetBBox(symInstance,sX1,sY1,sX2,sY2); TextFace([bold]); TextOrigin(sX1,sY2-1); BeginText; symName EndText; X := X + XSpacing; IF (X > (StartX + (NumAcross * XSpacing))) THEN BEGIN X := StartX; Y := StartY - YSpacing; END; Message(concat('The Sym#',Num2Str(0,numSymbols),' is - ',symName)); END; {PROCEDURE TraverseSymbol} {==============================================================} PROCEDURE traverseSymbolList (itemHdl:HANDLE); BEGIN WHILE (itemHdl <> NIL) DO BEGIN CASE GetType (itemHdl) OF 16:BEGIN TraverseSymbol(itemHdl); numSymbols := numSymbols + 1; END; 92:BEGIN SymFolderName := GetName(itemHdl); numFolders := numFolders + 1; numNestedFolders := numNestedFolders + 1; LayerNames[numFolders] := SymFolderName; Layer(SymFolderName); X := StartX; Y := StartY; TraverseSymbolList (FInFolder (itemHdl)); END; END; {CASE GetType (itemHdl)} itemHdl := NextObj (itemHdl); END; {WHILE (itemHdl <> NIL)} IF numNestedFolders > 0 THEN numNestedFolders := numNestedFolders - 1; END; {PROCEDURE traverseSymbolList} {==============================================================} BEGIN {*/// Main program ///*} XSpacing := DistDialog('Enter Horizontal Spacing Distance:',''); YSpacing := DistDialog('Enter Vertical Spacing Distance:',''); NumAcross := IntDialog('Enter the number of symbols per row',''); Message('Click on top left corner of the grid'); GetPt(StartX,StartY); CurrLayer := ActLayer; numFolders := 0; numNestedFolders := 0; numSymbols := 0; X := StartX; Y := StartY; LayerNames[0] := GetLName(ActLayer); IF FSymDef <> NIL THEN TraverseSymbolList (FSymDef); Index := 0; Layer(LayerNames[index]); WHILE (FInLayer(ActLayer) = NIL) DO BEGIN Index := Index + 1; Layer(LayerNames[index]); END; SetLayerOptions(1); Redraw; ClrMessage; END; {PROCEDURE ShowAllSymbols} RUN (ShowAllSymbols); Thanks!! jab
  2. Hallo, Here is un script found on another site. This script place all symbol include in the file, in all folders, on the drawing. Marvelous to create after that a tablelist and edit directly in the table. But the script crashes at the end of the process!! is somebody could take a look at it and see the error? Pleeaase ! :crazy: PROCEDURE ShowAllSymbols; {?1999 Graphsoft, Inc.} {The traverseSymbolList procedure was developed by Craig Hollinshead.} VAR numFolders, numNestedFolders, numSymbols : INTEGER; messageString : STRING; OK : BOOLEAN; NewPtSize : INTEGER; OldPtSize : INTEGER; SelectedObj : HANDLE; TheSymbolName : STRING; SymFolderName : STRING; TheSymDef : HANDLE; SymDef2 : HANDLE; ChangeAllLines : BOOLEAN; CurrLayer : HANDLE; X,Y : REAL; XSpacing, YSpacing : REAL; NumAcross : INTEGER; StartX,StartY : REAL; LayerNames : ARRAY[0..200] OF STRING; Index : INTEGER; {=============================================================================} PROCEDURE TraverseSymbol(theSym:Handle); VAR symObjClass : STRING; origLineWt : INTEGER; symName : STRING; symInstance : HANDLE; sX1,sX2,sY1,sY2 : REAL; BEGIN symName := GetSDName(theSym); symName := GetName(theSym); Symbol(symName,X,Y,0); symInstance := LNewObj; GetBBox(symInstance,sX1,sY1,sX2,sY2); TextFace([bold]); TextOrigin(sX1,sY2-1); BeginText; symName EndText; X := X + XSpacing; IF (X > (StartX + (NumAcross * XSpacing))) THEN BEGIN X := StartX; Y := StartY - YSpacing; END; Message(concat('The Sym#',Num2Str(0,numSymbols),' is - ',symName)); END; {PROCEDURE TraverseSymbol} {==============================================================} PROCEDURE traverseSymbolList (itemHdl:HANDLE); BEGIN WHILE (itemHdl <> NIL) DO BEGIN CASE GetType (itemHdl) OF 16:BEGIN TraverseSymbol(itemHdl); numSymbols := numSymbols + 1; END; 92:BEGIN SymFolderName := GetName(itemHdl); numFolders := numFolders + 1; numNestedFolders := numNestedFolders + 1; LayerNames[numFolders] := SymFolderName; Layer(SymFolderName); X := StartX; Y := StartY; TraverseSymbolList (FInFolder (itemHdl)); END; END; {CASE GetType (itemHdl)} itemHdl := NextObj (itemHdl); END; {WHILE (itemHdl <> NIL)} IF numNestedFolders > 0 THEN numNestedFolders := numNestedFolders - 1; END; {PROCEDURE traverseSymbolList} {==============================================================} BEGIN {*/// Main program ///*} XSpacing := DistDialog('Enter Horizontal Spacing Distance:',''); YSpacing := DistDialog('Enter Vertical Spacing Distance:',''); NumAcross := IntDialog('Enter the number of symbols per row',''); Message('Click on top left corner of the grid'); GetPt(StartX,StartY); CurrLayer := ActLayer; numFolders := 0; numNestedFolders := 0; numSymbols := 0; X := StartX; Y := StartY; LayerNames[0] := GetLName(ActLayer); IF FSymDef <> NIL THEN TraverseSymbolList (FSymDef); Index := 0; Layer(LayerNames[index]); WHILE (FInLayer(ActLayer) = NIL) DO BEGIN Index := Index + 1; Layer(LayerNames[index]); END; SetLayerOptions(1); Redraw; ClrMessage; END; {PROCEDURE ShowAllSymbols} RUN (ShowAllSymbols); Thanks!! jab
  3. search for "vwplant.usr" on your hard drive and replace it by the files on your backup.. The file on your backup is probably bigger than the original.
  4. Yes this is possible but you have to edit the template in the database with FilemakerPro... I do it with an evaluation version of filemakerPro dowloaded on the web...
×
×
  • Create New...