on button click -> load image

For questions about using Classic.

Post » Sun Jan 06, 2008 1:49 pm

Hi all i am creating a program to enable to you to easily create smilies (aka emoticons) and the only image plugin is the "Image Manipulator" and there is no option to allow users a dialog to select an image to load into it, you have to ad the image in the event editor :(
B
3
S
2
G
5
Posts: 301
Reputation: 2,302

Post » Sun Jan 06, 2008 2:21 pm

Common dialog has a file selector you can use with it I think.

Tim
B
2
G
5
Posts: 26
Reputation: 1,302

Post » Sun Jan 06, 2008 2:29 pm

Ah ha! I suppose i should have looked deeper, been a while since i used any tool such as this!

Although now i have this error (this is when i try to get the image manipulator to load an image from the select file in the dialog box):
B
3
S
2
G
5
Posts: 301
Reputation: 2,302

Post » Sun Jan 06, 2008 2:31 pm

It looks like it supports multiple selection, so the parameter would be the file index you want to retrieve.

Add 0 or 1 as a parameter, and see if it returns the correct path.

Tim
B
2
G
5
Posts: 26
Reputation: 1,302

Post » Sun Jan 06, 2008 2:33 pm

Selected the image i posted ealier, 1 as a paremeter loaded nothing, 0 as a parameter crashed the application test.
B
3
S
2
G
5
Posts: 301
Reputation: 2,302

Post » Mon Jan 07, 2008 10:51 am

Bump! Help would be great...
B
3
S
2
G
5
Posts: 301
Reputation: 2,302

Post » Mon Jan 07, 2008 1:13 pm

CommonDialog.SelectedFile(1) works for me here, try putting it in a text object. Is this a bug in the image object then?
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,580

Post » Mon Jan 07, 2008 11:11 pm

Must be a bug in the image object, 1 does nothing, 0 crashes it.
B
3
S
2
G
5
Posts: 301
Reputation: 2,302

Post » Tue Jan 08, 2008 12:04 am

I think it only supports BMP files for loading. Are you trying to load a PNG or JPG? If so, that wouldn't work. Maybe I can add support for other formats in a later version.
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,580

Post » Tue Jan 08, 2008 10:59 am

Oh right, that will be why, support for other files is a MUST, bmp are horrible and huge in file size usually compared to others!

Plus if you do want to support other OS's in future it is even more of a must.

Please include at least jpg in the next version.
B
3
S
2
G
5
Posts: 301
Reputation: 2,302

Next

Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 3 guests