Page 1 of 1

PostPosted: Mon Aug 07, 2006 4:50 am
by Jacques Lioret
Hello Pietro,
Yes, it is not very easy, but you can convert from imperial system to metric:
ml --> LF : 1 Foot = 0.3048 m.
m2 --> SF : 1 sqf = 0.0929 m2
m3 --> CF : 1 Cu.foot = 0.0283 m3

SF --> m2 : 1 sqf = 0.0929 m2
CF --> m3 : 1 Cu.foot = 0.0283 m3
PD --> Kg : 1 Pound = 0.4536 kg
Ton --> T. : 1 Ton = 1.016 Tonnes
GL --> L. : 1 gallon = 4.546 litres
LY --> ml : 1 LY = 0.9144 m.
SY --> m2 : 1 sqY = 9 sqF = 0.8361 m2
CY --> m3 : 1 Cu.yard = 27 cu.Feet = 0.7646 m3
Enjoy your vacations :lol: .
Regards

Jacques Lioret
ABACAD

PostPosted: Mon Aug 07, 2006 7:40 am
by rod_walker
Hi,
when using dcal you only need to convert 'real' values. The getdist routine automatically handles the conversions.
Regards,
Rod Walker

PostPosted: Mon Aug 07, 2006 10:27 am
by Paul Nida
I am not a programmer, but from a strictly CAD user I am strictly against the 1 unit =1unit approach that ACAD uses. Whereas 1 unit can be 1mm, 1 foot or 1 mile. This is one of the things I don't like about ACAD. I prefer it the way DCAD does it. Where 1" = 1" and 1' = 1'. Everything is real dimensions, not some fabricated thing.

PostPosted: Tue Aug 08, 2006 4:05 am
by Jacques Lioret
Hello Pietro,
The old DCAL'macro Samples/WRITE was very useful for me to understand how DataCAD save entities'coordinates.
DataCAD don't save lengths, surfaces, volumes, but only the position of each end-point or vertex of entties, in X, Y and Z.
Then each part of the program and the macros calculate the real dimension in the unit you are using, depending the system, metric or imperial.
You should try the macro WRITE.
When I wrote my program Architip, a sort of BIM program, which, if linked to DataCAD, can extract all materials quantities either in meters or in feet, using the 1/32 foot.
You can download an evaluation version on my web site [www.abacad.fr].
Regards

Jacques Lioret
ABACAD

PostPosted: Tue Aug 08, 2006 2:07 pm
by devinder
1 Unit = 1/32 inch in DataCAD.

If you want to change the distance readout then you can set the value scaletype in Savevar to one of the following
0 -> Architecutal
1 -> Engineering
2 -> Decimal feet
3 -> metric mt.
4 -> inch fractions
5 -> inch decimal
6 -> cm
7 -> mm
8 -> mt cm mm

ToDis returns string value based on the scaletype.

Dcal Units

PostPosted: Wed Aug 16, 2006 7:42 am
by rod_walker
Hi Pietro,
sorry I was not very clear. Going from memory.
In a program I wrote to place batens along a sloping rafter I set up my default sizes (spacing, batten width and depth etc) in my preferred units mm.

Code: Select allIf act = afirst then
 begin
  b.ptno:=1;
  b.state:=1;
  b.width:=75.0/metricconv; {dcal base unit =1/32 so convert mm)
 ...

75mm = approx 3inches. metricconv is defined in Uconstants.pas.
Now when I am getting user values I use getdis later in the program
Code: Select allIf act <> alsize then
 begin
  wrterr ('batten vers 1.0');
  case b.state of
 1:
  begin
 wrtlvl ('batten');
 lblsinit;
 lblset(2,'Width');
 etc. etc.
 lblset(20,'Exit);
 lblson;
 If b.ptno = 1 then
  begin

  { code here for getting rafter end points which I will skip for this discussion}

 2:
 begin
 wrtmsg('Enter Width');
 getdis(b.Width,b.getd,retval);
 end;


The point is I set up initial values in 1/32 by converting real number values. The user can be working in any of the dataCAD units. The getdis(.....) converts the user input to dcal units. So I don't need to worry about conversions.

Regards
Rod