Continue to Site

Welcome to MCAD Central

Join our MCAD Central community forums, the largest resource for MCAD (Mechanical Computer-Aided Design) professionals, including files, forums, jobs, articles, calendar, and more.

pprint in ncl file

lslattery

New member
Hi All,


I'm new to pro/nc but I have a ?


When inserting a pprint using the


cl insert >cmd edit>pprint


I enter the text say 2" from part


What is inserted into the ncl file is


PPRINT / 2" from part


The issue is our controllers does not like the /


How do I get pro not to place the / after the PPRINT
 
The problrm is not within Pro/e but in the "Gpost" software that you are posting the file with. To strip the "/" from the output, all you have to do is create or modify the "FIL" file that belongs to this post.


To do this, pick "Applications"on the top toolbar in the Pro/e manufacturing window. Then select "NC Post Processor". When the "Option File Generator" windows opens, select the post that you want to modify, and pick "OPEN". On the left side of this window, pick "Advanced" and "FIL Editor". This will open up an existing FIL file or create one if none exists. Locate a macro for PPRINT. If there is no macro for "PPRINT", copy all of the following text into it. If there already is a macro, only copywhat is between the "CIMFIL/ON,PPRINT" and "CIMFIL/OFF"lines. No need for the extra carriage returns.


$$ **********************************


$$ P P R I N T


$$ **********************************


CIMFIL/ON,PPRINT


COM=TEXT/CLW$$ Get the text from the CL record


COL=TEXT/'/'$$ Strip the '/' from the text


COLPOS=INDXF(COM,COL)


IF (COLPOS.NE.0) THEN $$ If '/' is found then do this


LEN=CANF(COM,1)


NMESS=TEXT/RANGE,COM,COLPOS+1,LEN


COM=TEXT/NMESS


ENDIF


PPRINT/COM $$ OUTPUT MODIFIED TEXT


CIMFIL/OFF
Edited by: appinmi
 
smiley1.gif
thanks for the fast and accurate response. tested late yesterday and it worked like a champ.
smiley1.gif
smiley1.gif
 

Sponsor

Articles From 3DCAD World

Back
Top