Paul6558915
Posts: 0
Joined: Wed Jan 08, 2014 10:50 am

Can we Automtically Change the screen size of the app?

Hi,

Code: Select all

             We’ve registered to your account and we tried to create an app through one screen size specifically at 640x960 because we were thinking that making it at a bigger size would then be easier to resize it to smaller ones. Our concern is that since we are building an app for all types of screen sizes, we tried to test it through the appbuilder test and changed the screen sizes to 480x800, 400x800, 320x480, and 240x320. Somehow, it didn’t change especially the image, it never changed its pixels that would fit in smaller sizes. Even if we change the orientation from portrait to landscape. 

             So what we would like to know, is there a setting wherein that once we created an app, it automatically adjust the size in smaller device? or do we need to create different components for each size in the same project? Or do we have to create another project for another specific size? We’d like to know this now cause we don’t want to like make much effort already and in the end realize that we need to start all over again because the setting or adjustments were supposedly be done in the beginning.
Kateryna Grynko
Posts: 0
Joined: Thu Nov 15, 2012 9:13 am

Can we Automtically Change the screen size of the app?

Hi Paul,

You an change component size using Resize event. Please add this code:preAppery("componentName").css("width", widthValue);
Appery("componentName").css("height", heightValue);/preWhere 'componentName' is a component name,
'widthValue' and 'heightValue' are values you need.

Paul6558915
Posts: 0
Joined: Wed Jan 08, 2014 10:50 am

Can we Automtically Change the screen size of the app?

Hi,

Is the code to be placed in the CSS folder? because i can't open mine.

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

Can we Automtically Change the screen size of the app?

Hi Paul -- I think Katya had in mind here to place it on event with Action: Run JavaScript.

Paul6558915
Posts: 0
Joined: Wed Jan 08, 2014 10:50 am

Can we Automtically Change the screen size of the app?

hm.. how can i edit the javascript properties? cause i also can't open the javascript folder. I did what you said with the event, then action set to Run javascript. it has a blank property.

i tried adding properties for widthValue and heightValue through the property bar on the right side, then went to events tab, selected Resize; proceeded to setting the action to set property. Somehow I thought this would have been correct if the value fields were set properly. but where? But, i'm no expert with this, it was just a thought, what i did might be wrong. But if it was correct, hopefully I was able to guide a little to what would be the next thing to do. hehe

Paul6558915
Posts: 0
Joined: Wed Jan 08, 2014 10:50 am

Can we Automtically Change the screen size of the app?

I see, Thanks Illya! but what do you mean by component name? the defalut name like "Image" or the common name? Because i tried using the common name, the image didn't change once i tested it. i did vice versa, and still did not change, i set my values to fit in a 320x480 screen size

Paul6558915
Posts: 0
Joined: Wed Jan 08, 2014 10:50 am

Can we Automtically Change the screen size of the app?

This is what i did, Image

and it didn't change Image

The common name is Hapsay_image.

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

Can we Automtically Change the screen size of the app?

Paul - can you give us the public link? -- I will take a look.

Return to “Issues”