Jump to content

inquire or prompt with an image


Recommended Posts

hi all,

I saw a nice function in another CMM programming software and would love to find out how to do it in Calypso.

basically adding images to Prompts. _see example below_

this can be inside an "inquire" or "message" command

I tried by adding a .bat file that opens the .jpg before prompt using "systemCallWithWait" but it doesn't look good and disappears too quickly

systemCallWithWait("C:\Users\kzolfaga\Desktop\Attachments\C3.bat")
Gage_ID = inquireNumber("input ID as per image")

**C3.bat contains the path and name of the image

I am sure there should be a better way to do this inside calypso 🙂

2532_0de4b90a72fda8918d875d906b901448.jpg
2532_e5ef6fc74e4afc02317001dcdf4c717a.jpg
Link to comment
https://qualityforum.zeiss.com/topic/12772-inquire-or-prompt-with-an-image/
Share on other sites

also wanted to add:

code in that other software would let me create my own prompt/message box _see example below_

I can specify size and location of text, input box, image and button

does calypso offer this option?

PROMPT/0,0,320,310,TITLE,'Gage Internal Diameter',BUTTON,200,10,50,15,'OK',1,BUTTON,260,10,50,15,'Cancel',0,PICTURE,10,35,300,250,'K:\NGOM\Common\Wenzel\DMIS\Fixture\ID.bmp',EDIT,95,10,75,15,ID_Diameter,False,TEXT,10,10,75,15,'Gage ID'

Please sign in to view this quote.

Calypso certainly has this capability

in automated tool changer, when you run "define holder location" using any XXT holder, there are prompt with images.

do you know how or where I can access this routine? i am sure someone smart in here can crack the code 😉

Please sign in to view this quote.

@ Norbert Bendl, thanks for taking an interest. i couldn't find MyVoice, can you direct me or provide a link? thanks


@ Eric Moberg, please come and join my exploit of internal Calypso routine 😉

I really believe this is really nice option to have when it come to creating interactive measurement plans.

Please sign in to view this quote.

you are awesome!

I managed to recreate this, only issue I seem not able to solve, is my image size
I can expand as wide as the image but can't control the height ❓

this is my code
response=executeCode("WinProcess shOneOEM: 'C:/Users/kzolfaga/Desktop/EnhancedMessage/message.exe TITLE,"Gage Internal Diameter" TEXT,"Gage ID",10,10 INPUT,70,10 BUTTON,"         OK         ",210,10 BUTTON,"       Cancle       ",300,10 IMAGE,C:/Users/kzolfaga/Desktop/EnhancedMessage/Height.bmp,10,50 SIZE,425,500"+"'")
2532_e967514e987116d8122750d66c9c0413.jpg
2532_3f858827940c3714d7bec8b62a5b9137.jpg
I re-worked this a bit, since I can imagine how this can be pretty useful.

You can have as many inputs, images, dropdowns, buttons and checkboxes you wish now. (Lists are limited to 1) And the respone is even easier to take care of, without any string splitting. It's also returned in a specific, logic order. (buttons, inputs, dropdowns, checkboxes and list)
114_123898cd652a29019ee89459792509de.png
114_19785bdb251e8df3c423435eed770cb4.png
There's a text-file explaining the functions in the attached 7z-file. But here is a line that use all functions, and creates the prompt above:
executeCode("WinProcess shOneOEM: '%desktop%\msg\dist\message.exe SIZE,580,300 IMAGE,%desktop%\msg\pic.png,10,190 FORCED TITLE,"Example title" TIMEOUT,120 TEXT,"Write something",5,10 TEXT,"Write some more here",5,50 INPUT,150,10 INPUT,150,50 BUTTON,OK,5,100 BUTTON,CANCEL,90,100, DROPD,("Choose type";Staropramen;Guinness;Corona;"Any cheep beer will do!"),5,130 LIST,("+qm()+myList+qm()+"),350,5 CHECK,"Tick here if you are cool",180,103 CHECK,"Or here if you suck",180,123 ' ").asArrayOfLines
Example list:
myList="Choise number 1"
for i = 2 to 20
	myList=myList+";Choise number "+i
next i

*edit - Found a bug, fixed it.

Please sign in to view this quote.

seems you like a challenge 🙂

-latest i tried i could only load one image, having multiple image gives the chance to demonstrate options
- even better if you could make images clickable

you have already done more than i ever imagined and i am thankful for it.

keep up the good work

Please sign in to view this quote.


I just used these to create a programing wizard. 😃

basically at the beginning of my parametric program, I check for parameter file and if it doesn't exist it will go through this wizard that walks you step by step and write values to a parameter file and at the end deletes all the junk and reads the parameter file and runs.

2532_00c4a884a8f93a43622ef8c19da39cfd.jpg
2532_dba0843d2a941496c81c3797759a705b.jpg
2532_0484e2672297737c4b391d6e1bfaf56f.jpg
2532_ba0cc3a0129d2151c5876ff1460708d4.jpg
Yeah, go nuts!

I only use it for a "automated" sequential subsequent evaluation (what a sentence...) that alters filter between the evaluations.
114_8273657328c672f280a27710dfa89683.png
I start a new job on monday, so I won't spend my last days implementing stuff that the rest can't figure out. (I've aldready done that for 10 years... 🤣 )

Please sign in to view this quote.

Nah, I'll be a Metrology method manager, but I don't really know what I'll actually be doing. I'll figure it's somthing like a Senior Developer combined with project management. And that your words and recommendations no longer is a preferred way, it's now the law 🤣
×
×
  • Create New...