Jump to content

dirlep

Member
  • Posts

    5
  • Joined

  • Last visited

Reputation

0 Neutral

Personal Information

  • Location
    Europe, Belgium, Oostende
  1. dirlep

    linelength

    Hi there, Is there a way to put the length (as text) of one or more lines next to the lines? GetLine exists but not GetLineLength, so it seems. thanks in advance. dirlep
  2. Hi, Is there anyone who can help me with the following script. The VS-error wants a BEGIN instead of RUN. It is a trialscript and doesn't have any meaning but it shows me what is possible. thanks in advance, Dirlep Here it comes : procedure MyDialog; FUNCTION Define_MyDialog : INTEGER; VAR id: LONGINT; BEGIN id := CreateLayout('puntjes zetten',TRUE,'Doe maar', 'effe wachten'); CreateStaticText(id,4,'Geef X1:',-1); CreateEditReal(id,5,4,0,10); CreateStaticText(id,6,'Geef y1:',-1); CreateEditReal(id,7,4,0,10); SetFirstLayoutItem(id,4); SetRightItem(id,4,5,0,0); SetRightItem(id,5,6,0,0); SetRightItem(id,6,7,0,0); { perform final control alignment and adjustment } AlignItemEdge(id,4,1,1001,0); AlignItemEdge(id,8,1,1001,0); SetHelpString(1,'Voert het gevraagde uit.'); SetHelpString(2,'stop en sluit.'); SetHelpString(4,'beetje uitleg nodig?'); SetHelpString(5,'amaai.'); Define_MyDialog := id; END; PROCEDURE Drive_MyDialog(VAR item:LONGINT; data:LONGINT); VAR x,y,y1,x1:REAL; id: LONGINT; result : LONGINT; BEGIN DSelectAll; GetPt(x, y); {bepaald het invoegpunt} SetOrigin (x,y); locus(x,y); PushAttrs; PenFore(255); PenBack(0); PenPat(2); PenSize(14); PenPat(2); Marker(0, 0.125000, 15); NameClass('beton sier'); Poly(1,0 , 0,1 ,0,12 ,x1,y1, 1,0 , 4,0 , 1,0 ); PopAttrs; SetOriginAbsolute(0,0); dselectall; result := RunLayoutDialog(id,Drive_MyDialog); END; RUN(MyDialog);
  3. Raymond, Hi I've tried it out and it works just like I want it. So thanks a lot for the help and the quick respons. Dirlep.
  4. Hy there, Is there anyone who can show me how to reduce the numbers after decimals in the results on screen. Thanks. ---The script I use is (partially from the manual): PROCEDURE Vertexbepaling; VAR obj :HANDLE; vertexNum :INTEGER; X, Y :REAL; vertexType :INTEGER; arcRadius :REAL; BEGIN obj := FSActLayer; FOR vertexNum := 1 TO GetVertNum(obj) DO BEGIN GetPolylineVertex(obj, vertexNum, X, Y, vertexType, arcRadius); TextOrigin(X+5, Y+5); CreateText(Concat(' ', vertexNum, ' / X: ', X, ' / Y: ', Y)); END; END; RUN(Vertexbepaling);
  5. Anyone, I'm at a dead end here. My scripts used to work with PtDialog to determine my 'X' and 'Y' co?rdinates. In order to let the script draw a line or an polygone MoveTo(0,1);LineTo(x1,1); or Poly(0,0,200,0,200,15,0,15,0,0); , I just let the script ask repeatedly every X and Y value needed. This could come out rather annoying, I could have up to 5 PtDialogs popping up in that same script. I now discoverd the better kind of Dialog, dialogID := CreateLayout , where I can ask in just one Dialog field more X and Y values. but to let de Line and Polygone rules react to de input it seems that I need some other type of line. Is there anyone who can put me on the right track, keeping in mind that I'm not a programmer, more like a novice who teaches himself the wonder of VWscripting. Thanks.
×
×
  • Create New...