Page 1 of 1

IMPORTAN PROBLEM WITH DIMENSIONS

Posted: 24 Jan 2014, 18:10
by jose_olalla
Hello.
I am creating a dxf following the examples of your "AddEnttities" demo file. (I use delphi XE2 and VCL Export 9.1.5)
I have many work realized with dimension and I just discover a serious error with my "dimensions" on de dxf file.

If use your example function to create one vertically dimension:

Code: Select all

function TForm1.AddDimension: TsgDXFDimension;
begin
  Result := TsgDXFDimension.Create;
  Result.DefPoint := MakeFPoint(30,200,0);
  Result.LinDefPoint1 := MakeFPoint(100,100,0);
  Result.LinDefPoint2 := MakeFPoint(100,200,0);
  Result.TextOffset := 5;
  Result.Style := FCADFile.Converter.DimensionStyleByName('TEST');
  Result.Layer := FCADFile.Converter.LayerByName(cnstLayerName);
  if not AddEntityToLayout(Result) then
  begin
    Result.Free;
    Result := nil;
  end;
end;

Please try to reproduce the error as follows:
0- Introduce this values shown above to generate a vertical dimension.
1- Compile->Run "AddEntities Demo" and click "Picture 4"
2- Save de DXF file.
3- Open de file with autocad. The dimension is OK but... select all the entities and move it.
The dimensions disappear!!
¿?

The same effect occurs if you move only one point of the dimension.

I need ugent help!

EDIT
Can some one send me a little example of how to make a vertically dimension?
I'm so confused. I think I used wrong the DefPoint definition...
Result.DefPoint?
Result.LinDefPoint1?
Result.LinDefPoint2?
What is the meaning of each point definition?
Please.

Re: IMPORTAN PROBLEM WITH DIMENSIONS

Posted: 27 Jan 2014, 17:10
by support
Hello!

Please specify the rotation and dimension flag 0 for the created dimension:

Code: Select all

  Result := TsgDXFDimension.Create;
  Result.DefPoint := MakeFPoint(30,200,0);
  Result.LinDefPoint1 := MakeFPoint(100,100,0);
  Result.LinDefPoint2 := MakeFPoint(100,200,0);
  Result.Flags := 0;
  Result.Angle := 90;
  Result.TextOffset := 5;
//....
AutoCAD will proccess such dimension as a rotated dimension. The dimension won't be distorted when edited in AutoCAD.

Alexander.

Re: IMPORTAN PROBLEM WITH DIMENSIONS

Posted: 17 Feb 2014, 16:06
by jose_olalla
Thanks so much.