几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量

几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量 (http://www.dimcax.com/hust/index.php)
-   ObjectARX(C++) (http://www.dimcax.com/hust/forumdisplay.php?f=34)
-   -   【转帖】与初学者共享程序 (http://www.dimcax.com/hust/showthread.php?t=7084)

yang686526 2009-04-16 07:16 PM

【转帖】与初学者共享程序
 
与初学者共享程序
与初学者共享程序
与初学者共享程序
#include "stdafx.h"
#include "stdarx.h"
// this is command 'setscale'
void zysetscale()
{
// todo: implement the command
int rc;
ads_real sf;
ads_name sname;
ads_matrix matrix;
acedprompt("\nselect enties to scale (transfrom)");
rc=acedssget(null,null,null,null,sname);

ident_init(matrix);
for(int i=0;i<3;i++)
{
matrix[i][i]=sf;
}
acedinitget(rsg_nonull+rsg_noneg+rsg_nozero,null);
acedgetreal("\ntransformation scale factor: ",&sf);
rc=acedxformss(sname,matrix);
acedssfree(sname);
}
谢谢楼主,也在初学arx,共勉!
autocad批量打印高效解决方案——autowiseplot. www.awpsoft.com/cn


所有的时间均为北京时间。 现在的时间是 01:30 AM.