My company now wants me to save each program after I run a part as a seperate part program. Is there a way to put some code at the end of each program that prompt for the file name and save it?
saveing each program after running
Collapse
X
-
Interesting idea, hope like heck you have a BIG hard drive. Of course, you can delete the CAD files OR, make a blank program that has nothing in it except the cad data, then simply do a CAD REFERENCE instead of an IGES impot (or whatever data format you use). The Cad reference method make a .CAD file that is only 1K in size, everytime, since it is really only a path direction telling Pcdmis where to look.
ANYWAY, if you write protect the program, when the operator closes the program, Pcdmis will NOT be able to write over the existing program and will prompt you for a new file name to save the program as (at least it used to do this).sigpic
Originally posted by AndersII've got one from September 2006 (bug ticket) which has finally been fixed in 2013. -
Yeah you can write a script to do it (xcopy). Or if we knew which version you are running you could write a macro (or use send keys in your script) to highlight all of the program in the edit window, then copy, then paste into a text file for saving. The macro one I am not totally sure about I don't use that function but I am just shooting ideas out.
Craig<internet bumper sticker goes here>Comment
-
You can also save printout to a .rtf (create a folder and save the runs there), in your print option you can assign your printout to the folder. It will sequence the runs and also date code. (just doesn't make sense to save a program different each time when there's really no change)
Just another option.
JoePC-DMIS CAD++ 3.7 from 4.2 MR1Comment
-
Question:
How do you want to save? Let's say the same operator runs 3 of the same parts one day then a different operator runs 1 that day and the next day the part needs to be run again. Do you want to save a copy after each execution, or only per operator or only per some predetermined time frame such as every 8 or 24 hours.
If it is per operator you could have the program issued and turned back in on a floppy like you would a gage or tool.<internet bumper sticker goes here>Comment
-
I'm going to ask the question no one has asked yet.
Do they want to save the actual program (could be opened and run)?
Do they just want a copy of the report saved?
Do they want a copy of the program saved that can not be run?
I think the first one is pointless. Sort of a backup each time you run but without deleting the previous backup - Could/would take up A LOT of space.
Second one is what I do. Seems to make more sense. Especially if you backup the program regularly.
Third one is possible but that also seems pointless. Just wasting space and adding to confusion IMNSHO.Comment
-
I think he wants traceability in case an alteration is made. This is common with CNC programs and required by some QMS.
Craig<internet bumper sticker goes here>Comment
-
In that case, I would suggest saving the file as a .rtf. The file would not be openable by pc-dmis and could not be run. I think this would save some space and also keep someone from opening and using a program saved after running rather than the "master". It would still be possible to go through the program line by line to ensure nothing was changed.Comment
-
I'm thinking along the same lines and others are concurring. Save into a .txt or something not easily edited like a .pdf. Saving the .prg will probably create more headache than problems solved. Although if he were to script it saving the .prg would be the least code. I see a problem with that though. If there is an alteration and the program is run and a script uses the xcopy function to make a copy of it I am thinking it will make a copy of the saved file and if the alteration is not saved at copy time it will not show. Another argument for a .txt, .rtf, or .pdf.
Craig<internet bumper sticker goes here>Comment
-
I am running 3.7 MR3 and the reason for saving is they want to be capable of recalling a individual program and possibly create new data from features measured or look at the data from a offline copy of PC-DMIS so each part ran will need to have its own program2013 MRI
B&S DEA Ghibli & GlobalComment
-
In that case you WILL need to save the program, that is the only way you will be able to do ANYTHING with the data at a later date. ALSO, the program will have to include the alignment. A program that recalls an external alignment will NOT work for this, since it will access the most current saved alignment. Your best bet would be to use the CAD REFERENCE for the file or the cad files will fill up your hard drive VERY quickly unless you go and delete them every time (or delete the from the 'working' master program).
As for saving, each run, the write protected method will work, but it will ONLY prompt you for a file name when you CLOSE the program. QUITTING will not prompt you. As for the other options, the file has to be saved before it can be copied, so I do not know how you can do it from INSIDE the program itself, unless the code INSIDE the program can do a save-as.sigpic
Originally posted by AndersII've got one from September 2006 (bug ticket) which has finally been fixed in 2013.Comment
-
VB Program that is launched at the end of the program that does a saveas using the date/time as the file name Suffix.Comment
-
Ah, so it would need to be able to be opened by pc-dmis. In that case you will have to save it as a .prg. I would suggest coming up with a naming scheme such that these saved runs will not be confused with the "master" program. I would make sure to save them in a clearly labeled seperate folder. I would name them something like program name-date run-sequential for the date (0511623-12-4-06-01)Comment
-
OK now that we know you need to save the prg. I wonder if you can write a macro that will Save as...or perhaps a macro that will export a cad (.stp, .dxf etc) file of your part. xcopy would be the easiest and you can use automation to save your part program. I guess you could try a script that will first automate to save your part program then create a copy of it. I see Save as can be done through automation but I have never done it and I do not know what your options are for naming. According to the documentation you get a dialog if there is no name already but if there is I do not know what it does.
Craig<internet bumper sticker goes here>Comment
Related Topics
Collapse
-
by bfire85I have an issue with one program on my Optiv 321.
The program is looped. It does one side of the part, then the operator flips over the...-
Channel: PC-DMIS for CMMs
04-21-2022, 08:19 AM -
-
by oddamI need to save each part program I run from now on. Currently I "save as" and serialize the program into a part folder. Problem with doing...
-
Channel: PC-DMIS for CMMs
09-25-2019, 02:06 PM -
-
by hammerI have been using the multiexec script from the wilcox web site that allows for saving a new part program with the sn on the end of the program name I...
-
Channel: PC-DMIS for CMMs
11-17-2010, 03:10 PM -
-
by hammerI use multi exec to label each program run with the program name and a Serial Number. My problem with this is that it will not allow the use of letters...
-
Channel: PC-DMIS for CMMs
12-22-2008, 11:53 AM -
-
by keegoCan this be done? Not just report data but hit data in the edit window?
-
Channel: PC-DMIS for CMMs
06-10-2009, 02:19 PM -
Comment