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

Help Aligning entry boxes on a Dialog

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

  • Help Aligning entry boxes on a Dialog

    I've been going around in circles (metaphorically speaking) trying to align the "Type-in" boxes on the following Dialog Script. Everything else works as expected.

    The Dialog Script:

    Code:
    'Date Created: 01-Jan-2007 05:11:52 PM
    'Last Updated: 23-Sep-2007 01:37:41 PM
    'Created By  : Graham Wickens
    'Updated By  : Graham Wickens
    on error goto error_routine
    ' Set Variables
    DIM Mode as C
    DIM Choice as C
    DIM Order as n = 1
    DIM Qry AS P
    DIM Tbl AS P
    DIM Var_Prod_list_rl_def AS C
    DIM Var_Civ_Fleet as C = ""
    DIM Var_Mil_Fleet as C = ""
    DIM Var_Air_fleet as C = ""
    DIM Var_Cou_Fleet as C = ""
    DIM Var_bas_fleet as c = ""
    DIM Var_prod_list as c = ""
    DIM Var_icao_code as c = ""
    DIM Var_Full_name as c = ""
    DIM VarC_result as C
    DIM Var_Mil_Fleet_rl_def as C
    DIM Var_Civ_Fleet_rl_def as C
    DIM Var_Cou_Fleet_rl_def as C
    DIM Var_Air_Fleet_rl_def as C
    DIM Var_bas_fleet_rl_def as c
    DIM Var_ICAO_Code_rl_def as c
    DIM Var_Full_Name_rl_def as c
    ' Listbox parameters when mode = "Airline" and choice = "ICAO_Code"
    Var_Icao_Code_rl_def = "k=appendix_c,{keylist_build(\"H=.025,1:10[Icao],2:25[Operator]\",''+Icao,left(''+Icao,10),left(''+Operator,25))}{isnotblank(\"Icao\")}"
    ' Listbox parameters when mode = "Airline" and choice = "Full Operator Name"
    Var_Full_Name_rl_def = "k=appendix_c,{keylist_build(\"H=.025,1:25[Operator],2:10[Icao]\",''+Unique,left(''+Operator,25),left(''+Icao,25))}{}"
    ' Listbox parameters when mode = "Production" selected
    Var_Prod_list_rl_def = "k=aircraft_type,{keylist_build(\"H=.025,1:25[C2]\",''+Type_code,left(''+Aircraft_type,36))}{generic}"
    ' Listbox parameters when mode = "Military" selected
    Var_Mil_Fleet_rl_def = "k=appendix_c,{keylist_build('H=.025,1:35[Operator],2:18[Country]',''+Unique,left(''+Operator,35),left(''+Country,18))}{C1 = 'M'}"
    ' Listbox parameters when mode = "Register" selected
    Var_Civ_Fleet_rl_def = "k=appendix_c,{keylist_build('H=.025,1:35[Operator],2:6[Icao]',''+Icao,left(''+Operator,35),left(''+Icao,6))}{isnotblank('Icao')}"
    ' Listbox parameters when mode = "Country" selected
    Var_Cou_Fleet_rl_def = "k=prefix,{keylist_build('H=.025,1:25[Country],2:8[Prefix]',''+Name12,left(''+Country,25),left(''+Prefix,8))}{Usage_c = .t.}"
    ' Listbox parameters when mode = "Airline" selected
    Var_Air_Fleet_rl_def = "k=appendix_c,{keylist_build('H=.025,1:35[Operator],2:4[Icao]',''+ut(unique),left(''+Operator,35),left(''+Icao,6))}{isnotblank('Icao')}"
    ' Listbox parameters when mode = "Location" selected
    Var_Bas_Fleet_rl_def = "k=base_details,{keylist_build('H=.025,1:25[Location],2:18[Region],3:25[Country]',''+Unique,left(''+Base,25),left(''+Region_n,18),left(''+Country,25))}{}"
    ' Dialog Box
    mode="Airline" 'Default
    varC_result = ui_dlg_box( "Fleet Listing", <<%dlg%
    {font=MS Sans Serif,8,b}Choose:{font=MS Sans Serif,8,n};
    (mode:Airline)
    (mode:Military)
    (mode:Country)
    (mode:Register)
    (mode:Production)
    (mode:Location);
    {line=1,0};
    {font=MS Sans Serif,8,b}Select From List:{font=MS Sans Serif,8,n};
    {Comment=Record List Combo Box to use if Mode is 'Airline'}
    {condition=mode="Airline"}
    {region}
    (choice={ICAO Code,Full Operator Name})
    {Comment=Use if Choice is ICAO Code}
    {condition=choice="ICAO Code".and.mode="Airline"}
    {start_pos}
    | [%@Var_Icao_Code_rl_def%.10Var_ICAO_Code];
    {Comment=Use if choice is Full Name}
    {Condition=choice="Full Operator Name".and.mode="Airline"}
    {start_pos}
    | [%@Var_Full_Name_rl_def%.40Var_Full_name];
    {endregion};
    {Comment=Record List Combo Box to use if Mode is 'Military'}
    {condition=mode="Military"}
    {start_pos}
    {region}
    Unit: | [%@Var_Mil_Fleet_rl_def%.40Var_Mil_Fleet];
    {endregion}
    {Comment=Record List Combo Box to use if Mode is 'Country'}
    {condition=mode="Country"}
    {start_pos}
    {region}
    Country: | [%@Var_Cou_Fleet_rl_def%.25Var_Cou_Fleet];
    {endregion}
    {Comment=Record List Combo Box for 'Location'}
    {condition=mode="Location"}
    {start_pos}
    {region}
    Location:| [%@Var_Bas_Fleet_rl_def%.25Var_bas_Fleet];
    {endregion}
    {Comment=Record List Combo Box to use if Mode is 'Register'}
    {condition=mode="Register"}
    {start_pos}
    {region}
    Country: | [%@Var_Cou_Fleet_rl_def%.25Var_Cou_Fleet];
    {endregion}
    {Comment=Record List Combo Box for 'Production'}
    {condition=mode="Production"}
    {start_pos}
    {region}
    Aircraft Type: | [%@var_Prod_list_rl_def%.40Var_Prod_list];
    {condition=Var_Prod_list<>""}
    {start_pos}
    {region}
    (order={MSN,Line No,Reg,Original Id});
    {endregion}
    {endregion}
    {Condition=.t.}
    {line=1,0};
    <*15OK> <15Cancel>
    %dlg%)
    IF varC_result = "ok" THEN
    	tbl = table.current()
    	tbl.query_detach_all()
    	SELECT
    		CASE mode = "Airline"
    			query.filter = "op_unique = " + quote( alltrim( Var_Air_Fleet ) )
    			query.order  = "reg"
    		CASE mode = "Production"
    		   query.filter = "type_code = " + quote( alltrim( Var_Prod_list ) )
    	 		query.order  = selectlist(order,"sortmsn+line_no","line_no+sortmsn","Reg","Origin_id")
    		CASE mode = "Military"
    			query.filter = "op_unique = " + quote( alltrim( Var_Mil_fleet ) ) + " .and. c1 = 'M'"
    			query.order  = "reg"
    		CASE mode = "Country"
    			query.filter = "country   = " + quote( alltrim( Var_Cou_Fleet ) ) + " .and. c1 = 'M' .and. status = 'C'"
    			query.order  = "reg"
    		CASE mode = "Register"
    			query.filter = "country   = " + quote( alltrim( Var_Cou_Fleet ) ) + " .and. c1 = 'C'"
    			query.order  = "reg"
    		CASE mode = "Location"
    			query.filter = "b_unique  = " + quote( alltrim( Var_Bas_Fleet ) )
    			query.order  = "reg"
    		CASE else
    			ui_msg_box("Fleet Listing","Invalid Parameters",UI_STOP_SYMBOL+UI_ATTENTION_SYMBOL)
    			end
    		END SELECT
    	query.options = "M"
    	qry = tbl.query_create()
    tbl.fetch_first()
    topparent.refresh_layout()
    END IF
    end 
    error_routine:
    err_msg = error_text_get(error_code_get())
    script = error_script_get()
    line = error_line_number_get()
    ui_msg_box("Error",err_msg+" error occured at line "+alltrim(str(line,4,0))+" in Script "+alltrim(script))
    With reference to the attached PDF File with all the various different displays of the Dialog.

    Figures 2 and 3

    How do I get the two entry boxes in the same place (ie where the "ICAO_Code" box is on Figure 2)?

    Figures 4,5,6,7

    How do I get each entry box onto the line below "Select From List"?
    --
    Support your local Search and Rescue Unit, Get Lost!

    www.westrowops.co.uk

  • #2
    Re: Help Aligning entry boxes on a Dialog

    I have realised that I have sent the wrong picture for Figure 6, so here is a new pdf with all the correct pictures.
    --
    Support your local Search and Rescue Unit, Get Lost!

    www.westrowops.co.uk

    Comment


    • #3
      Re: Help Aligning entry boxes on a Dialog

      this driving mad, after eight hours of playing around with the "Using the {col} and {row} commands" example in help, I getting very frustrated with this, if you see a PC in orbit over the UK, you will know its mine.

      a much simplified dialog box, where I get one bit right then change something and it all goes egg-shapped again!

      Code:
      ui_dlg_box("Testing",<<%dlg%
      {region}
      {col1}{frame=2,2}{row1}
      (Mode:Airline)
      (Mode:Military)
      (Mode:Country)
      (Mode:Register)
      (Mode:Production)
      (Mode:Location)
      {endrow1}{endcol1}
      {endregion}
      {comment=Airline Chosen}
      {condition=mode="Airline"}
      {region}
      {col1}{row3}
      (choice={Icao Code,Full Operator Name})
      [12,15DummyEntry1]
      {endrow3}{endcol1}{endregion};
      {comment=Production Chosen}
      {condition=mode="Production"}
      {region}{col1}{row3}
      (order={MSN,Line No,Reg,Original ID})
      Aircraft Type: [12,15DummyEntryProduction];
      {endrow3}{endcol1}{endregion};
      {comment=Miltary Chosen}
      {condition=mode="Military"}
      {region}{col1}{row3}
      Unit: [12,15DummyEntryMilitary]
      {endrow3}{endregion};
      {comments=Country Chosen}
      {condition=mode="country"}
      {region}{col1}{row3}
      Title: [12,15DummyEntryCountry]
      {endrow3}{endregion};
      {comment=Register Chosen}
      {condition=mode="Register"}
      {region}{col1}{row3}
      Country: [12,15DummyEntryRegister]
      {endrow3}{endcol1}{endregion};
      {comment=Location Chosen}
      {condition=mode="Location"}
      {region}{col1}{row3}
      Location: [12,15DummyEntryLocation]
      {endrow3}{endcol1}{endregion};
      {endregion}
      {condition=.t.}
      %dlg%)
      --
      Support your local Search and Rescue Unit, Get Lost!

      www.westrowops.co.uk

      Comment


      • #4
        Re: Help Aligning entry boxes on a Dialog

        Noob reply = I get that line lined up wrong if I miss a ;. I don't know what the proper way to break lines but I always break on {endregion}; and leave the line before it without a break ;. Just me. But that line and box looks like what I run into when I misplace or don't place a ;. Thanks

        Comment


        • #5
          Re: Help Aligning entry boxes on a Dialog

          I fixed it to do what you want. but you should use {condition_begin} and {condition_end} to signify what is conditional, especially if it's nested inside of another conditional. And Don't line break inside a condition area, unless the conditionally viewed materials is multi-lined. Line break at the end of the complete Conditional statement...I'm working a lot with Xdialog these days and have run into these types of over-lapping and such.

          Code:
          mode="Airline" 'Default
          varC_result = ui_dlg_box( "Fleet Listing", <<%dlg%
          {font=MS Sans Serif,8,b}Choose:{font=MS Sans Serif,8,n};
          
          {region}
          (mode:Airline)
          (mode:Military)
          (mode:Country)
          (mode:Register)
          (mode:Production)
          (mode:Location)
          {endregion};
          
          {line=1,0};
          
          {font=MS Sans Serif,8,b}Select From List:{font=MS Sans Serif,8,n};
          {condition_begin=(mode="Airline")}
          {region}
          (choice={ICAO Code,Full Operator Name}) |
          
          {condition_begin=(choice="ICAO Code".and.mode="Airline")}
          {region}
          | [%@Var_Icao_Code_rl_def%.10Var_ICAO_Code]
          {endregion}
          
          {Condition=choice="Full Operator Name".and.mode="Airline"}
          {start_pos}
          {region}
          | [%@Var_Full_Name_rl_def%.40Var_Full_name]
          {endregion}
          
          {condition_end}
          {endregion}
          
          {condition=mode="Military"}
          {start_pos}
          {region}
          Unit: | [%@Var_Mil_Fleet_rl_def%.40Var_Mil_Fleet]
          {endregion}
          
          {condition=mode="Country"}
          {start_pos}
          {region}
          Country: | [%@Var_Cou_Fleet_rl_def%.25Var_Cou_Fleet]
          {endregion}
          
          {condition=mode="Location"}
          {start_pos}
          {region}
          Location: | [%@Var_Bas_Fleet_rl_def%.25Var_bas_Fleet]
          {endregion}
          
          {condition=(mode="Register")}
          {start_pos}
          {region}
          Country: | [%@Var_Cou_Fleet_rl_def%.25Var_Cou_Fleet]
          {endregion}
          
          {condition=(mode="Production")}
          {start_pos}
          {region}
          Aircraft Type: | [%@var_Prod_list_rl_def%.40Var_Prod_list];
          
          {condition_begin=(Var_Prod_list<>"")}
          | (order={MSN,Line No,Reg,Original Id});
          {endregion}
          
          {condition_end}
          {endregion}
          
          {condition_end};
          
          {line=1,0};
          <*15OK> <15Cancel>
          %dlg%)
          Last edited by warmexxus; 09-24-2007, 06:28 PM. Reason: Fixed my version of Production Sub-Conditional, I think this is what you meant...I don't have anything to load as values.sorr

          Comment


          • #6
            Re: Help Aligning entry boxes on a Dialog

            I've thought I had got the script to put everything in the correct place by using{Start_pos}, the secret being not to use {start_pos} for the first instance.I assume that sets the starting position for any following use of {start_pos}.

            Code:
            ui_dlg_box("Testing",<<%dlg%
            {region}
            (Mode:Airline)
            (Mode:Military)
            (Mode:Country)
            (Mode:Register)
            (Mode:Production)
            (Mode:Location);
            {line=1,1};
            {condition=mode="Airline"}
            Airline: (choice={Icao Code,Full Operator Name})
            {condition=mode="Airline".and.choice="Icao Code"}
            ICAO: [3,12DummyEntryIcaoCode]
            {condition=mode="Airline".and.choice="Full Operator Name"}
            Full Name: [20,15DummyEntryFullName] 
            {condition=mode="Production"}
            {start_pos}
            Aircraft Type: [12,15DummyEntryProduction]  (order={MSN,Line No,Reg,Original ID})  
            {condition=mode="Military"}
            {start_pos}
            Unit: [12,15DummyEntryMilitary]
            {condition=mode="country"}
            {start_pos}
            Title: [12,15DummyEntryCountry]
            {condition=mode="Register"}
            {start_pos}
            Country: [12,15DummyEntryRegister]
            {condition=mode="Location"}
            {start_pos}
            Location: [12,15DummyEntryLocation]
            {condition=.t.}
            {endregion}
            %dlg%)
            with reference to the script highlighted in red, when I select from the radio box "Choice" I cannot get the two subsequent boxes (when selected) to be positioned in the same place on the dialog as each other, one always follows the other?

            any suggestions as to how to correct this?
            --
            Support your local Search and Rescue Unit, Get Lost!

            www.westrowops.co.uk

            Comment


            • #7
              Re: Help Aligning entry boxes on a Dialog

              As far as I've come with Dialog, I always start a conditional area with {region} and {endregion}...I read it somewhere that's how to handle conditional areas. So each conditional (Choice) should be in it's own region, conditioned to show when condition = .T. For Me personally I use {condition_begin} and {condition_end} to "Nest" Conditional areas within other conditionals...this should be similar to what you want. I haven't tested it, just edited your code in the comment box...

              Originally posted by Graham Wickens View Post
              I've thought I had got the script to put everything in the correct place by using{Start_pos}, the secret being not to use {start_pos} for the first instance.I assume that sets the starting position for any following use of {start_pos}.

              Code:
              ui_dlg_box("Testing",<<%dlg%
              {region}
              (Mode:Airline)
              (Mode:Military)
              (Mode:Country)
              (Mode:Register)
              (Mode:Production)
              (Mode:Location);
              {line=1,1};
              
              {condition=mode="Airline"}
              {region}
              Airline: (choice={Icao Code,Full Operator Name})
              {endregion}
              
              {condition_begin=(mode="Airline".and.choice="Icao Code")}
              {region}
              ICAO: [3,12DummyEntryIcaoCode]
              {endregion}
              
              {condition=(mode="Airline".and.choice="Full Operator Name")}
              {start_pos}
              {region}
              Full Name: [20,15DummyEntryFullName] 
              {endregion}
              {condition_end}
              
              {condition=mode="Production"}
              {start_pos}
              Aircraft Type: [12,15DummyEntryProduction]  (order={MSN,Line No,Reg,Original ID})  
              {condition=mode="Military"}
              {start_pos}
              Unit: [12,15DummyEntryMilitary]
              {condition=mode="country"}
              {start_pos}
              Title: [12,15DummyEntryCountry]
              {condition=mode="Register"}
              {start_pos}
              Country: [12,15DummyEntryRegister]
              {condition=mode="Location"}
              {start_pos}
              Location: [12,15DummyEntryLocation]
              {condition=.t.}
              {endregion}
              %dlg%)
              with reference to the script highlighted in red, when I select from the radio box "Choice" I cannot get the two subsequent boxes (when selected) to be positioned in the same place on the dialog as each other, one always follows the other?

              any suggestions as to how to correct this?

              Comment


              • #8
                Re: Help Aligning entry boxes on a Dialog

                No, that does not work either, it still uses the original {Start_pos}. the choice "ICAO CODE" is correct but choice "Full Operator Name" is blatted over the radio box
                --
                Support your local Search and Rescue Unit, Get Lost!

                www.westrowops.co.uk

                Comment


                • #9
                  Re: Help Aligning entry boxes on a Dialog

                  Hahaha... I'll try this again, this time I tested it. The best I could do, I tried to comment my progression, but after a while I stopped commenting. Try to follow how I separated the regions and also how I spaced out the conditional areas so I could understand it better. I did have to column break to make IAC box NEXT to the choices. And Condition_start and Condition_End help me to understand conditional areas placed within other conditional areas.... good luck, respond back asap... :) good night...

                  Code:
                  FUNCTION Test_Box as V()
                  ui_dlg_box("Testing",<<%dlg%
                  {region}
                  (Mode:Airline)
                  (Mode:Military)
                  (Mode:Country)
                  (Mode:Register)
                  (Mode:Production)
                  (Mode:Location);
                  
                  {line=1,1};
                  
                  {comment=This is where the first condition begins, for airline "options"}
                  {condition_begin=mode="Airline"}
                  {region}
                  Airline: (choice={Icao Code,Full Operator Name})|
                  {comment=The Column Break above will place the next region NEXT to the choices!}
                  {comment=So logically, the second conditional is NEXT to the choices.}
                  
                  {comment=Now, new condition inside of Airline Condition}
                  {condition_begin=(mode="Airline".and.choice="Icao Code")}
                  {region}
                  ICAO: [3,12DummyEntryIcaoCode]
                  {endregion}
                  
                  {comment=\{start_pos\} in this condition applies to the second conditional area}
                  {condition=(mode="Airline".and.choice="Full Operator Name")}
                  {start_pos}
                  {region}
                  Full Name: [20,15DummyEntryFullName] 
                  {endregion}
                  {endregion}
                  {condition_end}
                  
                  {comment=This Condition_End completes the Second Conditional Area, while the MAIN condition continues...}
                  {comment=Every REGION is conditioned.}
                  {endregion}
                  
                  {condition=mode="Production"}
                  {start_pos}
                  {region}
                  Aircraft Type: [12,15DummyEntryProduction]  (order={MSN,Line No,Reg,Original ID})
                  {endregion}
                  
                  {condition=mode="Military"}
                  {start_pos}
                  {region}
                  Unit: [12,15DummyEntryMilitary]
                  {endregion}
                  
                  {condition=mode="country"}
                  {start_pos}
                  {region}
                  Title: [12,15DummyEntryCountry]
                  {endregion}
                  
                  {condition=mode="Register"}
                  {start_pos}
                  {region}
                  Country: [12,15DummyEntryRegister]
                  {endregion}
                  
                  {condition=mode="Location"}
                  {start_pos}
                  {region}
                  Location: [12,15DummyEntryLocation]
                  {endregion}
                  
                  {condition_end}
                  %dlg%)
                  END FUNCTION
                  Originally posted by Graham Wickens View Post
                  No, that does not work either, it still uses the original {Start_pos}. the choice "ICAO CODE" is correct but choice "Full Operator Name" is blatted over the radio box

                  Comment


                  • #10
                    Re: Help Aligning entry boxes on a Dialog

                    Huh!


                    When I first copied the code into A5V7 it did not work, The airline choice worked just fine, but all the other options overwrote the Mode radio box!!

                    BUT

                    Somehow I managed to lose the closing curly bracket on the comments regarding the second conditional area (See below).

                    Code:
                    {comment=This Condition_End completes the Second Conditional Area, while the MAIN condition continues...}
                    {comment=Every REGION is conditioned.}

                    when I reran the script unknowingly without that curly bracket, all the options in the script were displayed perfectly :(

                    So what is happening here ???
                    --
                    Support your local Search and Rescue Unit, Get Lost!

                    www.westrowops.co.uk

                    Comment


                    • #11
                      Re: Help Aligning entry boxes on a Dialog

                      Extra {endregion} in there, this should work now...comments removed also.

                      Code:
                      'Date Created: 28-Sep-2007 10:48:50 PM
                      'Last Updated: 28-Sep-2007 10:48:50 PM
                      'Created By  : Master
                      'Updated By  : Master
                      FUNCTION Test_Box as V()
                      ui_dlg_box("Testing",<<%dlg%
                      {region}
                      (Mode:Airline)
                      (Mode:Military)
                      (Mode:Country)
                      (Mode:Register)
                      (Mode:Production)
                      (Mode:Location);
                      
                      {line=1,1};
                      
                      {condition_begin=(mode="Airline")}
                      {region}
                      Airline: (choice={Icao Code,Full Operator Name})|
                      
                      {condition_begin=(mode="Airline".and.choice="Icao Code")}
                      {region}
                      ICAO: [3,12DummyEntryIcaoCode]
                      {endregion}
                      
                      {condition=(mode="Airline".and.choice="Full Operator Name")}
                      {start_pos}
                      {region}
                      Full Name: [20,15DummyEntryFullName] 
                      {endregion}
                      
                      {endregion}
                      {condition_end}
                      
                      {condition=mode="Production"}
                      {start_pos}
                      {region}
                      Aircraft Type: [12,15DummyEntryProduction]  (order={MSN,Line No,Reg,Original ID})
                      {endregion}
                      
                      {condition=mode="Military"}
                      {start_pos}
                      {region}
                      Unit: [12,15DummyEntryMilitary]
                      {endregion}
                      
                      {condition=mode="country"}
                      {start_pos}
                      {region}
                      Title: [12,15DummyEntryCountry]
                      {endregion}
                      
                      {condition=mode="Register"}
                      {start_pos}
                      {region}
                      Country: [12,15DummyEntryRegister]
                      {endregion}
                      
                      {condition=mode="Location"}
                      {start_pos}
                      {region}
                      Location: [12,15DummyEntryLocation]
                      {endregion}
                      
                      {condition_end}
                      %dlg%)
                      END FUNCTION

                      Comment


                      • #12
                        Re: Help Aligning entry boxes on a Dialog

                        Yup! that works, also throws up a bug in the script compiler.

                        Code:
                        {comment=This Condition_End completes the Second Conditional Area, while the MAIN condition continues...}
                        {comment=Every REGION is conditioned....
                        {endregion}
                        the compiler does not show an error for the missing } and ignores the { at the start of the {endregion} in the next line but thinks the Comment finishes at the } of the {endregion}. When I ran without the closing } on the comment it ignored the next {endregion} and as I said worked just fine.

                        I've sent in a bug report.
                        --
                        Support your local Search and Rescue Unit, Get Lost!

                        www.westrowops.co.uk

                        Comment


                        • #13
                          I knew it is an Old. I have revised this code. I hope, may be help to someone for {condition }.

                          Code:
                          vModeList = comma_to_crlf("Airline,Military,Country,Register,Production,Location")
                          mode="Airline" 'Default
                          
                          'removed {start_pos}
                          
                          varC_result = ui_dlg_box( "Fleet Listing", <<%dlg%
                          {removeleadingspaces}
                          {removecomments}
                          
                          {region}
                          {font=tahoma,9,b}Choose:{font=tahoma,9,n} [.15mode^=vModeList] or Radio buttons at here;
                          {endregion};
                          
                          {line=1,0};
                          
                          {region}
                          {font=tahoma,9,b}Select From List:{font=tahoma,9,n};
                          
                          {comment=This is where the first condition begins, for airline "options"}
                          
                          {condition_begin=mode="Airline"}
                          {region}
                          {region}
                          Airline: (choice={Icao Code,Full Operator Name})
                          {endregion}|{region}
                          {condition_begin=(mode="Airline".and.choice="Icao Code")} {region}
                          {sp=1}ICAO: [3,12DummyEntryIcaoCode]
                          {endregion}
                          {condition=(mode="Airline".and.choice="Full Operator Name")} {start_pos} {region}
                          {sp=1}Full Name: [20,15DummyEntryFullName]
                          {endregion} {condition_end}
                          {endregion};
                          {endregion} {condition=mode="Production"} {start_pos} {region} Aircraft Type: [12,15DummyEntryProduction] (order={MSN,Line No,Reg,Original ID}) {endregion} {condition=mode="Military"} {start_pos} {region} Unit: [12,15DummyEntryMilitary] {endregion} {condition=mode="country"} {start_pos} {region} Title: [12,15DummyEntryCountry] {endregion} {condition=mode="Register"} {start_pos} {region} Country: [12,15DummyEntryRegister] {endregion} {condition=mode="Location"} {start_pos} {region} Location: [12,15DummyEntryLocation] {endregion} {condition_end}; {endregion}; {line=1,0}; <*15OK> <15Cancel> %dlg%)

                          Comment

                          Working...
                          X