[Done] Option to include image file data within compiled exe
Moderators: Dorian (MJT support), JRL
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
From the Dialog topic of the help file:
"Images and Buttons can reference bitmap files, or bitmap data embedded in the script. To import bitmap data into the script use Tools/Import Bitmap Data in the editor. The bitmap data will appear below a label at the end of the script. Reference the label name in the Image/Button declaration of the dialog block in place of the filename."
If that isn't clear:
Dialog>MyDialog
.. bla bla
Image=BITMAP_DATA,10,10,200,200
EndDialog>MyDialog
bla bla
BITMAP_DATA:
71838543423487239487......
Import the bitmap and you will see the data appear at the end of the script beneath a label. Use that label name in place of the filename in your dialog definition.
"Images and Buttons can reference bitmap files, or bitmap data embedded in the script. To import bitmap data into the script use Tools/Import Bitmap Data in the editor. The bitmap data will appear below a label at the end of the script. Reference the label name in the Image/Button declaration of the dialog block in place of the filename."
If that isn't clear:
Dialog>MyDialog
.. bla bla
Image=BITMAP_DATA,10,10,200,200
EndDialog>MyDialog
bla bla
BITMAP_DATA:
71838543423487239487......
Import the bitmap and you will see the data appear at the end of the script beneath a label. Use that label name in place of the filename in your dialog definition.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
Rain,
From Dialog help:
Thank you for continuous improvements and outstanding support. I've been an administrator for 20 years and I've dealt with many software packages and software developers. You are unquestionably the most creative, the most cooperative and the most responsive individual I have ever had the pleasure to have worked with. This addition is another fine example of those qualities.
Thank you,
Dick
From Dialog help:
Marcus,Images and Buttons can reference bitmap files, or bitmap data embedded in the script. To import bitmap data into the script use Tools/Import Bitmap Data in the editor. The bitmap data will appear below a label at the end of the script. Reference the label name in the Image/Button declaration of the dialog block in place of the filename.
Thank you for continuous improvements and outstanding support. I've been an administrator for 20 years and I've dealt with many software packages and software developers. You are unquestionably the most creative, the most cooperative and the most responsive individual I have ever had the pleasure to have worked with. This addition is another fine example of those qualities.
Thank you,
Dick
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
>One more question, this option only works with bitmaps,
>correct?
Correct. That's why the option is "Import Bitmap Data".
If you have JPEGs you want imported, convert them to bitmaps first. Then import.
>correct?
Correct. That's why the option is "Import Bitmap Data".
If you have JPEGs you want imported, convert them to bitmaps first. Then import.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
-
- Junior Coder
- Posts: 24
- Joined: Mon Nov 01, 2004 1:30 pm
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
Try scrolling up the thread a bit. There's an example 5 posts back.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
-
- Junior Coder
- Posts: 24
- Joined: Mon Nov 01, 2004 1:30 pm
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
Erm, not sure how to make it any clearer. Try this:
Used a very small image here to avoid too much text on the forum.
Code: Select all
Dialog>Dialog1
Caption=Dialog1
Width=164
Height=177
Top=191
Left=111
Image=S_DATA,24,24,105,105
EndDialog>Dialog1
Show>Dialog1,r
S_DATA:
424D7A010000000000003600000028000000090000000900000001002000000000004401000000000000000000000000000000000000D1767200D57C7400D9867600D88E7600DB8E7600DB937700DD95780080E0E00040A0E000D1767200D57C7400D9867600D88E7600D88E7600DB937700DB93770080E0E00080E0E000D27A7200D7847000D9897600D88E7600D88E7600DB937700DB937700DD957800DE997900D27A7200D8847500D9897600D88E7600D88E7600DB937700DB937700DD957800DE997900D0786B00D9897600D88E7600D88E7600DB937700DB937700DB937700DD957800DE997900CF6F5B00D7847000DB937700DD957800DD957800DD957800DE997900DF9D7A00DF9D7A00CA5E4800DC856500DB937700DF9D7A00E1A07B00E2A17D00E3A47D00E5A68000E5A68000984E0000CC635000DC856500DE997900E3A47D00E5A68000E8AB8500E7AC8A00E9B08B00984E0000984E0000CA5E4800D87D5E00DB937700E1A07B00E5A68000E5A68700E5A68700
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
To do it yourself:
1. Create a dialog with an image compont
2. paste it into a new script
3. add the Show> command so that it will show
4. Use Tools/Import Bitmap Data and import a bitmap file
5. You will see the bitmap data appear at end of script beneath a label
6. In place of the filename in the Image= declaration in the dialog put the name of this label.
1. Create a dialog with an image compont
2. paste it into a new script
3. add the Show> command so that it will show
4. Use Tools/Import Bitmap Data and import a bitmap file
5. You will see the bitmap data appear at end of script beneath a label
6. In place of the filename in the Image= declaration in the dialog put the name of this label.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
You do have 9.1 don't you? This won't work with any thing less than that. This is new functionality introduced with version 9.1.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
-
- Junior Coder
- Posts: 24
- Joined: Mon Nov 01, 2004 1:30 pm
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
In my last example the label was S_DATA, yes. The label is derived from the bitmap's file name. mypicture.bmp would make a label called MYPICTURE_DATA
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
-
- Junior Coder
- Posts: 24
- Joined: Mon Nov 01, 2004 1:30 pm
-
- Junior Coder
- Posts: 24
- Joined: Mon Nov 01, 2004 1:30 pm
I tried to use this new feature with the image function FindImagePos, and it returned a -1 as the number found. So I assume this means the image functions don't work with the embedded bitmaps. If this is the case, are you planning on adding this feature to the image processing functions? This would be extremely useful.