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

Xdialog help

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

    Xdialog help

    I am in the process of converting and A4 app to A5V7. I have discovered xdialog gives me a versatility and speedier way of doing a lot of the smaller things in day to day usage of the app. I want to be able to use xdialog as much as possible.

    I have attached a zip file containing an abbreviated copy of a table called insured.dbf and a text document that contains a script designed to get the insured id number for a specific record.

    The script was created by using the script genie then converting it to xbasic which has the xdialog portions in it also.

    At the end of the script, I have a little tester that tells me if I select a row in the list and click ok, it will give me the insured id variable I am looking for.

    Here is the problem:

    a) If I double click to select a record, it gets the correct InsuredID and sets it to a variable but, it does not close the xdialog. The selection and variable setting is done in a function declared before the xdialog box initializes.

    b) If I single click on the row in the list box and then press enter, I think I get the correct setting of the variable but again the xdialog box does not close.

    c) If I use the up or down arrows to select a record and then press enter like a keyboard data entry person, guess what? The xdialog box doesn't close.

    The only thing that works correctly every time is if I click on the ok button regardless of how the record was selected.

    Since this particular script will be used in many different situations, I need to be able to allow the user whichever way they do things to select the appropriate record. That means double clicking, single clicking and then clicking ok button (which works), using the up and down arrows to select the correct record and then pressing the enter key for those that don't like using mice during data entry.

    What I am asking is how to code so that the enter key will always be trapped for those using the keyboard and where the coding should be on the script and

    Secondly, how do I code so that double clicking will close the xdialog box and give me the variable I need? Also, where would I put that code?

    TIA
    My two cents worth :)

    Oran

    #2
    Re: Xdialog help

    Hi Oran,
    You can close an xdialog anytime and anywhere within the code section of your xdialog by not using a_dlg_button="" or if you decide to use a_dlg_button="" and still want to close the xdialog, then use UI_modeless_dlg_close("title name of your xdialog") to close the xdialog.
    an xdialog will also close if a button is defined but not trapped within the code section with IF a_dlg_button="MYBUTTONNAME" THEN when the button
    is pressed. If you have any more questions, I am willing to help you.

    RAWLINGS

    Comment


      #3
      Re: Xdialog help

      Hi,

      That's what I am trying to figure out. When I converted the script to xbasic, within the code section, it created event definitions. Each 'event' is a function (right click, click, double click, up and down arrows). Except for r click, each event sets the correct insuredid global variable correctly but does nothing as far as setting a_dlg_button value so there isn't anything to trigger the a_dlg_button to work except for clicking on the ok button.

      I am going on the assumption that the user will select the correct Insured by one of three ways . They will either use the mouse (click + ok button or double click) or they will use up and down arrows and then hit enter. I want to get the double click and up/down arrow + enter key to work. I can't seem to find a way for the double click to close the xdialog box. I have tried giving a_dlg_button a value, that didn't work. I have tried setting a quickie variable and then testing the variable to close the box, that didn't work either. Is it possible to use 'onrowdoubleclick' like you do with a browse? if so, how would I code it?

      Most of all, where is the correct place to put the coding? in the event? at the end of %code%? after the %code%?
      My two cents worth :)

      Oran

      Comment


        #4
        Re: Xdialog help

        Oran, you're asking questions that involve advanced features. Recommend you work your way through the xdialog tutorial, with particular emphasis on events before tackling this.

        -- tom

        Comment


          #5
          Re: Xdialog help

          Oran,

          Try this and see my notes in the code.

          Scott

          Comment


            #6
            Re: Xdialog help

            :) :) :) :)

            Scott,

            Thank you, thank you, thank you!!! It works, and now I know I can get the enter key portion to work also.
            My two cents worth :)

            Oran

            Comment


              #7
              Re: Xdialog help

              Sorry Scott, I missed the code under 'enter', it all works now. I have one comment tho, I didn't know that a modeless command could work within a modal box. Thanks again for the help, I have a much better understanding of that kind of box now.
              My two cents worth :)

              Oran

              Comment

              Working...
              X