Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations KootK on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

File format creation 1

Status
Not open for further replies.

rxpartha

Mechanical
Apr 6, 2005
34
Hey group,
I have a assembly with around 50 instances in the family table and I want to generate various file formats to be send to the customer (.igs, .neu, .stp) so will I have to open and do a save as for each and every 50 instances, so it will be 150 times I will be doing this procedure (50 times for each file format) or is there any way that this can be done easily without my intervention (say automated). If there is a solution for me, this Friday would be a great way to start weekend....Any ideas or views.....thanks, Raj.
 
Replies continue below

Recommended for you

My questions is WHY? Once they have the data in one format, how many do they really need?



"Wildfires are dangerous, hard to control, and economically catastrophic."
"Fixed in the next release" should replace "Product First" as the PTC slogan.

Ben Loosli
CAD/CAM System Analyst
Ingersoll-Rand
 
Ok see we send out IGS for manufacturing and we needed to have .stp (as its more suitable for solidworks) and .neu we store it in our database....But is there any way.....if so...that will be super....thanks, Raj.
 
no replies :-((((((.....or no solution for this issue....
 
raj,
It can be done.. you need to create a program that will write a trail file or a lengthy mapkey.. vb,vbs, maybe c
I faced the same problem needing dxf files of drawings.. I could use pro_batch to make the conversion but I needed all the instances as drawings first.. the tst file of the instances can give you the names.. so what you need if you want create a mapkey is to record the picks and then use that syntax ..changing the variable of the instance name in your text file that you are creating.
i did it to write a mapkey, you have to watch the length of the key there is a limit on how long one key can be, so then you have to chain them

Make sense??
 
ok I have created a MP to goto Family table then open the 1st instance and do save as into a .neu file, so how do make this to go thru the entire FT instances....I dont understand "changing the variable of the instance name in your text file" how do you create this text file or does it creates automatically....throw some light....pro_batch thing
I just noted that its under P>pro/e>>Bin>>Pro batch....
Thanks a lot, Raj.
 
you have to clone the mapkey using vb or something .. changing the instance name... if I had more time I could explain in detail...but unless you have a way to write a file based on values of another ... your stuck with the wrist exercise of loading the instances.. saving etc.. then pro_batch to make conversions to step/iges


got to get to work... I hate 2nd shift
 
I quickly tried this and it seemed to work with part files. I would imagine it could also work with assemblies. Try running Pro/BATCH. I know you can make *.igs and *.stp files, but I don't know if you can make *.neu files with it.

Manually make your batch file...Open the family table member and edit the table of instances. Copy the entire column of all instance names and paste them into a simple *.txt file and then manually concatenate the data to match the format "-iges -object directory filepath\" + "instance filename" + ".prt"
Example for iges:
-iges -object C:\Test_Pro_2001\Test\NEW_INST_1.PRT
-iges -object C:\Test_Pro_2001\Test\NEW_INST_2.PRT
-iges -object C:\Test_Pro_2001\Test\NEW_INST_3.PRT

This text file is your Pro/Batch file and you should be able to run it as needed.

You could also create a separate batch text file for the *.stp files.
Example for step:
-step -object C:\Test_Pro_2001\Test\NEW_INST_1.PRT
-step -object C:\Test_Pro_2001\Test\NEW_INST_2.PRT
-step -object C:\Test_Pro_2001\Test\NEW_INST_3.PRT

-Keith
 
Thanks first, as per you advise I created a txt file with the format given by you.
-iges -object P:\ProEngineer\Dummy_Models\ APL1250-250.PRT (this is the source location of my .prt file to be converted into IGES, just was trying only the 1st instance of the FT)

I saved this as .bat (test.bat) file under the pro/e>>bin folder then I ran the Pro_batch (MS-DOS Batch file) which opened up a dialogue box then I selected this test.bat file. I dint know how to run, There is an icon that says run file, when I clicked it says No Pro/Engineer to run Pro/BATCH. Also I tried right clicking on the object path in the Pro/BATCH dialogue box & it says choose action and gives a big list of different file formats, where I tried selecting IGS but nothing big happened. Also where does the created .IGES file get stored? This is the first time I trying out batch file.

Thanks again, Raj.
 
There is a help file "Suggested Technique for Using Pro/BATCH to Create a Plot File" on PTC website that may help.

In the space designated "Pro/Engineer Command:" type in the entire path to the location of proe2001.bat file.
For example,
C:\Program Files\proe2001\bin\proe2001.bat

The above path is for C:\ directory, but the proe2001.bat file does not need to be located in C: directory. I have been able to copy it to the desired working directory and launch pro/engineer command from there. You can also place a copy of any appropriate config.pro files in that directory.

After running, the output files should be in the folder where proe2001.bat is launched.

-Keith
 
So sorry, I incorrectly stated the above response (I have 8 month old triplets and I'm running on fumes because they're teething!!!)

I think the Pro/engineer command should always point to pro/e>>bin directory. Instead, you can copy the pro_batch.bat file and your test batch file to your P:\proengineer\dummy_models\ directory and launch and run pro_batch.bat from there.

-Keith
 
Yup I am able to run the Pro/E command successfully says running and then OK. But there is no IGES file being created. I saved my test.bat file in the same location of the source file to be converted to IGES. Then ran Pro/Batch and then typed in the Pro/E command as P:\ProEngineer\Dummy_Models\ test.bat and ran but did not give any IGES formats.

But when I checked the location no IGES files were was found. I checked the Pro/E webites too for the Suggested Technique for Using Pro/BATCH to Create a Plot File, I don’t know why itsn’t creating the IGES file….

Thanks, Raj.
 
Raj,

I believe the "Pro/e command" runs proe in the backround and should always point to the "proe2001.bat" file that launches pro from your proe loadpoint. This should not change and the proe2001.bat file should remain in its original directory location. I'm not sure exactly what to use for Wildfire.

1. Copy the file "pro_batch.bat" into your "dummy_models" directory. (I copy mine from Proe>>bin directory)
2. Open the same file "pro_batch.bat" from within your "dummy_models" directory.
3. Within the probatch dialog box, open your file "test.bat" (you might try renaming to "test.txt"). This file should also be in the same directory "dummy_models")
4. Set the Pro/e command to point to the batch file that launches ProE (in my case it is "C:\Program Files\proe2001\bin\proe2001.bat").
5. Start/run the task

You might check your proe>>bin directory for the .igs files. They may have been created in a different directory. You could even do a generic search for recent *.igs files in windows explorer. Also, Pro Batch outputs a pro_batch.log.1 file that would let you know if it worked correctly. Below is a sample output from pro_batch.log file

-iges -object C:\ep2\Test_Pro_2001\Test\NEW_INST_1.PRT
----- Result SUCCESS

I hope this helps...
-Keith
 
I'm curious this can be done even if the generic part hasn't been saved out as instance<x>.prt files?

They show up on the proe file open menu.. but they don't show at win explorer level. Does the generic has to be open?



 
I tested it without saving out each "instance.prt" file and it worked. It output 3 *.igs files and I then imported one .igs to validate it was successful.

We typically open our family table instances without initially opening the generic and we've never saved them out as instance .prt files. We have multiple text reference files that list each unique instance for each generic family table part and we'll just cut and paste the desired instance name directly into the file open dialog box (i.e. 4-40x250SHCS). ProE automatically finds it and opens it through the normal search path routines without the need to open the generic part "generic_shcscrew" and then select instance 4-40x250shcs from the list.
 
I am pretty sure that I am doing it correctly.

1. Copy the file "pro_batch.bat" into your "dummy_models" directory. (I copy mine from Proe>>bin directory)
2. Open the same file "pro_batch.bat" from within your "dummy_models" directory.
3. Within the probatch dialog box, open your file "test.bat" (you might try renaming to "test.txt"). This file should also be in the same directory "dummy_models")
4. I set the Pro/e command to point to the batch file that launches ProE (in my case it is "C:\ptc\proe2001\bin\pro_batch.bat").
5. Start/run the task


It runs but again no IGES file created, There should be come ther problem if I am not able to do after such a good explanation by you keith. I tried bothe BAT format & saving in txt. format but nothing fruitful.
 
Raj,

Everything looks okay, except, I think your step 4 proe command should actually point to the batch file that launches Proe...

C:\ptc\proe2001\bin\proe2001.bat

That may be the whole problem. If that doesn't work, you may just have to use brute force and open each instance...

I hope I didn't cause you too much confusion or extra problems. Good Luck.
-Keith
 
I am using Pro/E 2001 only,
but in my C:\ptc\proe2001\bin\ location I do not have that proe2001.bat but just have a pro_batch.bat, I dont know why but I really do appreciate your patience and gesture keith. Atleast I learnt today that there is a way to automate this file creation, I would have been sucessful if there was someone in my office to guide me here....I was just trying to make work simpler for my colleagues (though not a manager here, but a self-driven design engineer).....no giving up....will explore......

Thanks, Raj.
 
Keith ...great tip, I had always used the browser to pick my files.

Not sure if this is the problems for you or not Raj, I'm on r2001 also and instance name and part name have to follow this type of format
-step -object C:\proe2001|parts\a_big\NEW_INST_10<TBIG1>.prt
-step -object
C:\proe2001\parts\a_big\NEW_INST_11<TBIG1>.prt
-step -object
C:\proe2001\parts\a_big\NEW_INST_12<TBIG1>.prt

this wordwrap in the paste... but those are 3 different lines..
-step -object c:your path then instance name and part name in the <> then .prt.. tbig1 being my generic

i ran the batch file first as iges then replace all iges to step and ran those.. all the inst were inside the generic

worked great...too bad there is not a save as prt then you could blow out all your instances if needed








 
Status
Not open for further replies.

Part and Inventory Search

Sponsor