Alpha Software Mobile Development Tools:   Alpha Anywhere    |   Alpha TransForm subscribe to our YouTube Channel  Follow Us on LinkedIn  Follow Us on Twitter  Follow Us on Facebook

Announcement

Collapse

The Alpha Software Forum Participation Guidelines

The Alpha Software Forum is a free forum created for Alpha Software Developer Community to ask for help, exchange ideas, and share solutions. Alpha Software strives to create an environment where all members of the community can feel safe to participate. In order to ensure the Alpha Software Forum is a place where all feel welcome, forum participants are expected to behave as follows:
  • Be professional in your conduct
  • Be kind to others
  • Be constructive when giving feedback
  • Be open to new ideas and suggestions
  • Stay on topic


Be sure all comments and threads you post are respectful. Posts that contain any of the following content will be considered a violation of your agreement as a member of the Alpha Software Forum Community and will be moderated:
  • Spam.
  • Vulgar language.
  • Quotes from private conversations without permission, including pricing and other sales related discussions.
  • Personal attacks, insults, or subtle put-downs.
  • Harassment, bullying, threatening, mocking, shaming, or deriding anyone.
  • Sexist, racist, homophobic, transphobic, ableist, or otherwise discriminatory jokes and language.
  • Sexually explicit or violent material, links, or language.
  • Pirated, hacked, or copyright-infringing material.
  • Encouraging of others to engage in the above behaviors.


If a thread or post is found to contain any of the content outlined above, a moderator may choose to take one of the following actions:
  • Remove the Post or Thread - the content is removed from the forum.
  • Place the User in Moderation - all posts and new threads must be approved by a moderator before they are posted.
  • Temporarily Ban the User - user is banned from forum for a period of time.
  • Permanently Ban the User - user is permanently banned from the forum.


Moderators may also rename posts and threads if they are too generic or do not property reflect the content.

Moderators may move threads if they have been posted in the incorrect forum.

Threads/Posts questioning specific moderator decisions or actions (such as "why was a user banned?") are not allowed and will be removed.

The owners of Alpha Software Corporation (Forum Owner) reserve the right to remove, edit, move, or close any thread for any reason; or ban any forum member without notice, reason, or explanation.

Community members are encouraged to click the "Report Post" icon in the lower left of a given post if they feel the post is in violation of the rules. This will alert the Moderators to take a look.

Alpha Software Corporation may amend the guidelines from time to time and may also vary the procedures it sets out where appropriate in a particular case. Your agreement to comply with the guidelines will be deemed agreement to any changes to it.



Bonus TIPS for Successful Posting

Try a Search First
It is highly recommended that a Search be done on your topic before posting, as many questions have been answered in prior posts. As with any search engine, the shorter the search term, the more "hits" will be returned, but the more specific the search term is, the greater the relevance of those "hits". Searching for "table" might well return every message on the board while "tablesum" would greatly restrict the number of messages returned.

When you do post
First, make sure you are posting your question in the correct forum. For example, if you post an issue regarding Desktop applications on the Mobile & Browser Applications board , not only will your question not be seen by the appropriate audience, it may also be removed or relocated.

The more detail you provide about your problem or question, the more likely someone is to understand your request and be able to help. A sample database with a minimum of records (and its support files, zipped together) will make it much easier to diagnose issues with your application. Screen shots of error messages are especially helpful.

When explaining how to reproduce your problem, please be as detailed as possible. Describe every step, click-by-click and keypress-by-keypress. Otherwise when others try to duplicate your problem, they may do something slightly different and end up with different results.

A note about attachments
You may only attach one file to each message. Attachment file size is limited to 2MB. If you need to include several files, you may do so by zipping them into a single archive.

If you forgot to attach your files to your post, please do NOT create a new thread. Instead, reply to your original message and attach the file there.

When attaching screen shots, it is best to attach an image file (.BMP, .JPG, .GIF, .PNG, etc.) or a zip file of several images, as opposed to a Word document containing the screen shots. Because Word documents are prone to viruses, many message board users will not open your Word file, therefore limiting their ability to help you.

Similarly, if you are uploading a zipped archive, you should simply create a .ZIP file and not a self-extracting .EXE as many users will not run your EXE file.
See more
See less

Screen resolution & sizing

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #16
    Re: Screen resolution & sizing

    G Gabriel - Mike C,

    Thanks to both of you for your thoughts.

    G Gabriel...I really like your thinking on this. What you appear to be saying is that I can add your script to the On Activate event ---not for every form--- but once within the autoexec event. This would create a universal fix without having to redefine all my forms, nor maintain all those additional forms in the future.

    An added benefit is that even if I had to add this script to each form's On Activate event, that wouldn't be any trouble to implement because your script seems to be generic in nature. Thus, I'm thinking that I could simply 'cut and paste' it to every form. If I read the script correctly, you're fetching the screen specs in the first line and then applying those specs to the form...whatever form it is.

    I sure hope this works. It would save me a lot of time and trouble. As a matter of fact, I'm not even sure that I could release an app for general distribution that could not accommodate variable screen specs.

    Anyway, I'll give it a shot later in the week and let you know how it goes.

    Thanks again,
    Tom

    Comment


      #17
      Re: Screen resolution & sizing

      Originally posted by [email protected] View Post
      If I read the script correctly, you're fetching the screen specs in the first line and then applying those specs to the form...whatever form it is.
      Correct.
      Now there is one downside to this:
      If you already have some other scripts in the OnActivate event of a form, it will be overwritten (not permanently).
      To get around that, you could first read those events then attach mine at the end. I will modify this function to do that..later..

      Comment


        #18
        Re: Screen resolution & sizing

        G Gabriel,

        I found some spare time and tested your script in my autoexec file in the Code area. I already had a script there, so I put yours behind it. Other than a minor syntax error (right paren on the next to last line) it did not produce an error.

        However, I tested the script by changing my screen resolution from 1280x1024 to 1024x768, leaving the text size at Medium (in Windows 7). I was hoping that your script would put the form in the center of the screen but it did not do that. In fact, it didn't seem to have any impact on the form at all and so, when I went to the larger res (10x7), the form got larger and traveled to the southeast corner of the screen and about 10% of the form was chopped off.

        I must have done something wrong, but I can't figure it out. All I really want the script to do is put all forms in the center of the stage. Any thoughts?

        Thanks,
        Tom

        Comment


          #19
          Re: Screen resolution & sizing

          The script is not meant to center the form but rather resize it according to the screen resolution.
          The forms are anchored at the top left of the screen. So, when you change the size,
          the right lower corner will moves to Florida, or New Jersey depending on which way the wind is blowing
          and which way you tell it to go. But if you wish to move Seattle further inland, you can add few more
          lines to my script to adjust the left & top dimensions of the form. And leave the fonts alone.

          Comment


            #20
            Re: Screen resolution & sizing

            I'm thinking that you mean I would make a list of all the possible screen resolutions and then test each one noting where I want the x and y coordinates to line up with the upper left hand corner of the form is concerned and then make x and y statements on your scripts for each one? Is that correct?

            Is it possible to have a generic "center" command embedded in the autoexec as Mike was talking about earlier?

            Comment


              #21
              Re: Screen resolution & sizing

              Originally posted by [email protected] View Post
              I'm thinking that you mean I would make a list of all the possible screen resolutions
              Not.
              Here is the idea:
              1-First you measure the screen resolution whether the user is using a standard,
              a custom resolution and whether the user is you or someone in Tanzania. It doesn't matter.

              2-Now that you have the screen resolution, we will translate that into inches. Let's say we
              come up with 24x12 inch.
              3-Now we will size the form down to say 20x10 or whatever size you think is suitable.
              The form size is relative to the screen size. So in a smaller screen, the size will be less.
              4-To center the form, we will adjust the left margin to half the difference between the screen
              size and the form size. So in this case, if the screen size is 24 wide and the form size is 20 inch
              wide, we will make the left margin for the form 2 inch. Do the same thing for the height, half the difference.
              So in my script you need to add few more lines to adjust the left margin and the top.

              Originally posted by [email protected] View Post
              Is it possible to have a generic "center" command embedded in the autoexec as Mike was talking about earlier?
              From the looks of it, the script runs when you open each form, i.e. you can add that to a script that opens the form.
              of each form. I don't think you could do that in v8 (mass update in autoexec) but can speak to v10. In the end, the script won't be much different.
              Last edited by G Gabriel; 08-23-2010, 05:45 PM.

              Comment


                #22
                Re: Screen resolution & sizing

                So, it will be something like this:
                Code:
                Function Form_Resize as V()
                v_DPI=ui_info(4)
                x=int((ui_info(0)-10)/v_DPI)
                y=int((ui_info(1)-10)/v_DPI)
                'Let's say we want the formsize to be 80% of the screen
                L=x*.4
                T=y*.4
                lst=a5_form_enum()
                for each foo in lst
                eval(foo+".code.OnActivate") = eval("SYS_ID_RESIZE("+foo+","+x+","+y+")"
                eval(foo+".left"=L
                eval(foo+".top"=T
                next
                End Function
                Last edited by G Gabriel; 08-23-2010, 05:47 PM.

                Comment


                  #23
                  Re: Screen resolution & sizing

                  Look into:
                  <FORM>.WINDOW_POSITION()
                  It might do exactly what you want with a lot less trouble.
                  You could incorporate it in the initial UDF.

                  Comment


                    #24
                    Re: Screen resolution &amp; sizing

                    I will look into the window_position() function. That sounds a lot closer to something that I could master.

                    A friend suggested I look at the examples within Alpha Sports and notice how the screens within are anchored. He also suggested that I don't maximize the forms and see what happens with that.

                    I'll check into all of these suggestions on Wednesday.

                    Thanks again for all your help.

                    Tom

                    Comment


                      #25
                      Re: Screen resolution &amp; sizing

                      Just so everyone knows, the only really clean way to resolve this issue is to simply change the borders of the background and set the form as close to the northwest corner as you can. As lower screen resolutions are introduced, the form moves towards the southeast corner, proportionally to the screen specs. However, a screen would have to fall below 800x600 res to fall off the screen and I can't imagine anyone actually still using a 640x480 res. If there is someone out there using that, I'll just have to pass on the sale.

                      I'll move all my forms (again), but this is the only way that I can see making the app usable for all screen resolutions and keeping it stable so I don't have to add a lot of backgtound code.

                      Comment


                        #26
                        Re: Screen resolution &amp; sizing

                        Originally posted by [email protected] View Post
                        Just so everyone knows, the only really clean way to resolve this issue is to simply change the borders of the background and set the form as close to the northwest corner as you can. As lower screen resolutions are introduced, the form moves towards the southeast corner, proportionally to the screen specs. However, a screen would have to fall below 800x600 res to fall off the screen and I can't imagine anyone actually still using a 640x480 res. If there is someone out there using that, I'll just have to pass on the sale.

                        I'll move all my forms (again), but this is the only way that I can see making the app usable for all screen resolutions and keeping it stable so I don't have to add a lot of backgtound code.
                        film at 11?
                        Al Buchholz
                        Bookwood Systems, LTD
                        Weekly QReportBuilder Webinars Thursday 1 pm CST

                        Occam's Razor - KISS
                        Normalize till it hurts - De-normalize till it works.
                        Advice offered and questions asked in the spirit of learning how to fish is better than someone giving you a fish.
                        When we triage a problem it is much easier to read sample systems than to read a mind.
                        "Make it as simple as possible, but not simpler."
                        Albert Einstein

                        http://www.iadn.com/images/media/iadn_member.png

                        Comment


                          #27
                          Re: Screen resolution &amp; sizing

                          Don't pass on that sale!
                          Tell them that 1280x1024 style flatscreen Monitor will "Greatly Reduce the Carbon Footprint".
                          Everything marketed today "reduces carbon footprint". Whether it works as advertised is beside the point.
                          Toliet paper is the latest. And it's shaded Green!
                          The first time I see a reduced carbon Tampon ad, the Go-Green TV goes Thru the Low Carbon window!
                          Soon we will have negative Carbon & that which grows Green will turn brown. That which is brown will turn green.
                          Maybe Making the A5v9 Green icon was to symbolize "Reduced Carbon" Software?

                          Originally posted by [email protected] View Post
                          Just so everyone knows, the only really clean way to resolve this issue is to simply change the borders of the background and set the form as close to the northwest corner as you can. As lower screen resolutions are introduced, the form moves towards the southeast corner, proportionally to the screen specs. However, a screen would have to fall below 800x600 res to fall off the screen and I can't imagine anyone actually still using a 640x480 res. If there is someone out there using that, I'll just have to pass on the sale.

                          I'll move all my forms (again), but this is the only way that I can see making the app usable for all screen resolutions and keeping it stable so I don't have to add a lot of backgtound code.
                          Last edited by SMARTII; 08-27-2010, 01:34 AM.
                          First Love

                          Comment

                          Working...
                          X