Jump to content

Adding pictures to Program Stop.


Recommended Posts

When you add a picture to a Program Stop, it pops up a picture at the stop. However, if you save the program to a different name the Program Stop loses the picture link.

I use dates as a suffix to my programs for revision control, it is not uncommon to save a program with a new date suffix.

Is there a way to maintain the picture links?

Link to comment
https://qualityforum.zeiss.com/topic/23775-adding-pictures-to-program-stop/
Share on other sites

Where are you saving the picture?  If you are saving it inside the program folder it might that the file address is no longer valid you could try making a dedicated fold of pictures.  Alternatively, you could use a BAT file to make a picture popup when you open a program.  A super simple one I use all the time is    start "" "file address\picture.jpeg".  If you save that as inspection_post_load.bat and drop that in the program folder that will open a photo first thing when the program is opened.

BAT file location.jpg

BAT Format.jpg

  • Like! 2

The path being reported as invalid, is valid.

This leads me to believe there is something else that retains the original path and uses the "#pathOfFile:" as a text place holder.

The only way to fix it right now is to edit each feature that has a picture associated to it, and that's quite a few. It would be time consuming.

 

This is the text in the "inspection" file I am editing. (Blue=Path, Red=File name).

#OMTecProgStop 
#comment: '' 
#'container$' 'container' 
#settings: 
#(
#OMSettings) 
#definitions: 
#(
#OMParameters 
#'container$' 'container' 
#recalculate: true 
#dict: 
#(
#Dictionary) 
#parameters: '') 
#text: 'Insert best fit Gage Pin (Ø.125).' 
#pathOfFile: 'C:\Inspections\56683-3_B_Op40-50_2 of 2_05-09-2024\935 .1562-.1577 Pins.PNG') 
 

Edited

You have to change the entry in the inspset and autoruninf file, too.

These are labeled by #progStopUserInfo.

For instance, you have a picture C:\Temp\test.JPG, then you have to change in the inspection file (as you've already done)

#pathOfFile: 'C:\Temp\test.JPG')

as well

#progStopUserInfo ' ->' 'C:\Temp\test.JPG')

the inspset and autoruninf file.

  • Like! 1

I allways hated it, to work withe program stop. I realised it (works only when running from feature) with pcm: I have theoretical features where I need the pictures, in pre- or postparameters I have :

systemCall(getActualInspectionDir()+"\1.bat")
message("Weiter")

that calls a .bat, that calls the picture, like:

@ECHO OFF
"%~dp0\1.JPG"

works well from any folder

  • Like! 2
  • 2 weeks later...
×
×
  • Create New...