高级会员
注册日期: 06-11
帖子: 14579
精华: 1
现金: 224494 标准币
资产: 234494 标准币
|
【转帖】paper size name
paper size name
paper size name
hi there
i have created a new layout and have done setting of layout's paper size through wizard.the paper size name is set at dxf code 4 of the layout object and while saving this drawing;the papersize name is set as canonical name by oddblayout using the function setcanonicalname(...).
now when i open the drawing and try to retrive the papersize;i get the value as "user613" or "user8212"....i do it by function "getcanonicalname()"....but my purpose is to retrieve the actual papersize name being set while saving the drawing.
i tried to use "getlocalename(....)" but it returns blank.
can anyone please suggest to retrieve the exact papersize name from the drawing.
odstring strcanonicalmedianame = podlayout->getcanonicalmedianame();
odstring strlocalemedianame=pplotsettingsvalidator->getlocalemedianame((oddbplotsettings*)podlayout,0 );
i used the above code but it doesnt work.
hello,
could you please attach some example files ?
attachment for papersize name
hello sir...
there is nothing specific in example...just create a new layout in autocad using "layoutwizard" command and set the plot configuration as "hp designjet 450c (d/a1) by hp" and paper size as "legal(8.5 * 14 in) ".
save the drawing as test.dxf.
the paper size name is set at dxf code 4.but if you try to check it in dxf file;the name is set as "user265" which is the canonical name.my requirement is to retrieve the exact paper size which is "legal(8.5 * 14 in)".
below is teh snippet from dxf file and attached is teh dxf file itself.
acdbplotsettings
1
2
hp designjet 450c (d/a1) by hp
4
user265
attached files (41.1 kb, 1 views)
hello,
colud you please test your file with mfcapp... load it, select file/page setup. page setup dialog containes paper size field (center of the left side) and canonical paper name in the lower left coner.
i didn't use your printer device for test, but hp designjet 500 24+hpgl2 card with user257. mfcapp returns custom 8.5 x 11 in paper for me as paper size, not user257.
did you check return value for get**** functions?
hello sir
if u change the paper size of layout1 or layout2(the default layouts);it gives the correct paper size name.but if a new layout is created;it gives user257 or something like that.
did u create a new layout and checked it.
regarding "odamfcapp.exe" ; it also returns the same "user257". regarding the get..functions;i have attached the functions in my first post and the functions dont work propwrly.please check
sorry, i cannot reproduce it yet. i uses toolkit 2.5.1. i load your file, create new layout via menu, got valid results. could you please publish the small test code to reproduce defect... in mfcapp.
ps:
i have downloaded hp driver and your printer driver is installed in my system.
hi,
have you any news...
|