Hi John, Here is the code from a method I use called Photo_Rotate:
//This method rotates a picture. While it will rotate the picture to //any angle, this method is really expecting it to rotate 90˚, 180˚, //or 270˚. C_PICTURE($1;$gPicture) C_REAL($2;$rDegrees) //Expects 90, 180, or 270 C_PICTURE($0) $gPicture:=$1 $rDegrees:=$2 C_LONGINT($lWidth;$lHeight) C_TEXT($svgRef;$imageRef) PICTURE PROPERTIES($gPicture;$lWidth;$lHeight) $svgRef:=SVG_New ($lWidth;$lHeight) $imageRef:=SVG_New_embedded_image ($svgRef;$gPicture;0;0;".jpeg") If (($rDegrees=90) | ($rDegrees=270)) SVG_SET_TRANSFORM_ROTATE ($imageRef;$rDegrees;($lHeight/2);($lWidth/2)) SVG_SET_TRANSFORM_TRANSLATE ($imageRef;(($lHeight-$lWidth)/2);(($lWidth-$lHeight)/2)) DOM SET XML ATTRIBUTE($svgRef;"height";String($lWidth);"width";String($lHeight)) Else //180 SVG_SET_TRANSFORM_ROTATE ($imageRef;$rDegrees;($lWidth/2);($lHeight/2)) End if $0:=SVG_Export_to_picture ($svgRef) SVG_CLEAR ($svgRef) HTH. -- Cannon.Smith Synergy Farm Solutions Inc. Aetna, AB Canada <can...@synergyfarmsolutions.com> <www.synergyfarmsolutions.com> > On Jun 22, 2019, at 3:34 PM, JOHN BAUGHMAN via 4D_Tech <4d_tech@lists.4d.com> > wrote: > > If not 4D commands, what is the quickest and easiest way to rotate a picture > in a picture variable? Anyone got code they could share? ********************************************************************** 4D Internet Users Group (4D iNUG) Archive: http://lists.4d.com/archives.html Options: https://lists.4d.com/mailman/options/4d_tech Unsub: mailto:4d_tech-unsubscr...@lists.4d.com **********************************************************************