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

toggling data entry options

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

    toggling data entry options

    I have an invoice database that I use for photography. I've been trying to figure out a way to install a toggle in two fields. For instance, in the date field, I'd like it to ask if I want to enter todays date, or not. And I'd like it to ask me if I'm charging sales tax or not. Any idea how I can do this?

    TIA

    Paul.

    #2
    many ways

    Paul,

    It sound like what you need is a Dialog box that opens on the Filed OnArrive event. The dialog box will have two buttons, and the choice of the buttons will drive two separate events.

    See if attached helps.

    Mike W
    Mike W
    __________________________
    "I rebel in at least small things to express to the world that I have not completely surrendered"

    Comment


      #3
      Creating a 'button' in A4V7 (or 8)

      Paul,

      If A4, we have to write scripts to simulate what you call toggles (as well as scripts for the actions when one of the buttons are clicked) - they can look like a dialog with some number of buttons.

      You'll have to write four keystroke scripts and two dialog scripts. There will be a keystroke script for each action on each of the two dialog scripts.
      For the date field, you would have a dialog script that asks something like 'Entry todays date?' and it would have two choices - 'Yes' and 'No'. If 'Yes' is selected, the appropriate keystroke script will play; if 'No' is selected, the script appropriate for that choice will play. The 'Yes' keystroke script will enter the current days date and skip to the next field; for 'No', the date field would get focus so that you could enter the appropriate date.

      Same logic applies to the sales tax field.

      I have found it easier to write the individual keystroke scripts first and then write the dialog script that calls the appropriate keystroke scripts. You could think of this as bottom-up design.

      Hope this helps.

      Dave
      Dave Jampole
      www.customalpha.com

      Women and cats will do whatever they want. The sooner men and dogs realize that, the happier they will be.

      Comment


        #4
        Thanks Mike and Dave. I'll look into writing scripts. I have a couple questions. First, I open the database that Mike sent, and nothing happens when I enter a new record, no boxes pop up. Are they supposed to? In other words, how to I instruct the DB to run the script? Do I load that in the field rules?

        On another note, I feel like a dope, but when I was looking at the sample DB that Mike sent, I opened the options (F2) and noticed that Alt-D will put the date in, it works on my invoice as well so that button is no longer necessary. I just need to get something worked out so I can select whether or not to charge sales tax.

        Thanks,

        Paul.

        Comment


          #5
          Paul,

          Originally posted by Paul Udstrand
          ...In other words, how to I instruct the DB to run the script? Do I load that in the field rules?Paul.
          In the field rules for the field - if you want something to happen when you enter the field, you'd use the Enter trigger; to have the action occur when you exit the field, use the Exit trigger. The trigger script is simply a script that triggers (or runs) the script that does the action. It is really simplier than it sounds.

          Dave
          Dave Jampole
          www.customalpha.com

          Women and cats will do whatever they want. The sooner men and dogs realize that, the happier they will be.

          Comment


            #6
            Push the Button

            Originally posted by Paul Udstrand
            First, I open the database that Mike sent, and nothing happens when I enter a new record, no boxes pop up. Are they supposed to? In other words, how to I instruct the DB to run the script? Do I load that in the field rules?
            Paul,

            That would be to push the Button marked "Push to Start Sequence".

            Mike W
            Mike W
            __________________________
            "I rebel in at least small things to express to the world that I have not completely surrendered"

            Comment


              #7
              You may want to add a field to your database called SALESTAX as a 1 character field. The values will be Y or N. If you put a Y in the field, you will calculate the sales tax. If you put a N inthe field, you will not calculate the sales tax. This might be easier than writing scripts.

              Comment


                #8
                Originally posted by Mike Wilson
                Paul,

                That would be to push the Button marked "Push to Start Sequence".

                Mike W
                I don't see any "push to start sequence" buttons. Let me go back, I'm using alpha 4, version 7. one of the DB files you sent is an alpha 5 database. Now I also have alpha 5 version 4.5, but when I open the buttons DB or Buttonnames DB in A5, I don't see any buttons there either.

                Sorry if I'm being dense about this.

                Paul.

                Comment


                  #9
                  Version

                  Paul,

                  The example I sent is A5v7. It might be that is what the issue is. I downloaded the zip and checked it on my end and is seems complete. Maybe someone else with A5v5 or higher can check it.

                  Mike W
                  Mike W
                  __________________________
                  "I rebel in at least small things to express to the world that I have not completely surrendered"

                  Comment


                    #10
                    Mike,

                    Paul is running Alpha 4 V7, so a proposed solution for ANY version of Alpha Five would not be relevant.

                    Dave
                    Dave Jampole
                    www.customalpha.com

                    Women and cats will do whatever they want. The sooner men and dogs realize that, the happier they will be.

                    Comment


                      #11
                      Originally posted by davej
                      Mike,

                      Paul is running Alpha 4 V7, so a proposed solution for ANY version of Alpha Five would not be relevant.

                      Dave
                      Dave,
                      Thanks for the heads up. For my sake, could you please let me know how you came to the knowledge this was the case so i might in the future be aware of such and hheed to efforts of talking Greek to a China man?

                      Mike W
                      Mike W
                      __________________________
                      "I rebel in at least small things to express to the world that I have not completely surrendered"

                      Comment


                        #12
                        Toggling data entry options

                        Mike,

                        The forum under which the question is asked is a good hint - although not foolproof. Paul also uses a few Alpha Four specific terms - 'db' and 'script' - again that's not foolproof; it is easy to mix A4 terminology when talking about A5 and vice versa.

                        And your concern about talking Greek to a China man is a concern we would all be well advised to heed. It is natural to phrase what we offer to others in terms that are relevant to us. A thought to keep in mind is something I read in one of the textbooks I taught from - 'if the only tool you have in yuour toolbox is a hammer, all the problems you face look like nails'. Kinda' cryptic, but a good thought to remember.

                        Dave

                        P.S. Keep offering help on the messageboard - it is, in my opinion, one of the strongest points about Alpha.
                        Dave Jampole
                        www.customalpha.com

                        Women and cats will do whatever they want. The sooner men and dogs realize that, the happier they will be.

                        Comment


                          #13
                          Originally posted by Gary Smith
                          You may want to add a field to your database called SALESTAX as a 1 character field. The values will be Y or N. If you put a Y in the field, you will calculate the sales tax. If you put a N inthe field, you will not calculate the sales tax. This might be easier than writing scripts.
                          Gary,

                          This is an interesting idea, I had considered it but couldn't figure out how to make it work. How do I set up one field, the "tax" field, so that it doesn't calculate unless another field ( the salestax field) authorizes it? How do I link these fields?

                          Dave,

                          The exit/enter trigger options are not available to put the scripts in because this is a calculated field not a user entered field. It's calculated because it takes a sub total and calculates a .065 sales tax. The sales tax and sub total are then added in a Total field. Maybe what I need to do is focus on the total field and not the tax field. Maybe I can take Gary's idea and figure out a way to tell the "total" when and when not to add the sales tax.

                          In the meantime my quick and dirty fix has been to copy the database and simply delete the tax field, so now I have two invoice databases, one for taxed transactions and one for not tax transactions.

                          There's got to be a way to make this work though. Thanks for all your help, I'll look through my manuals and see if I can figure the details of how to make some of these suggestions work.

                          Paul.

                          Comment


                            #14
                            Paul,

                            You can put the script in the Exit trigger of the field just prior to the sales tax field. If the response is 'Yes', set the tax rate at its normal rate; if the response is 'No' set the tax rate at '0'. That way, the calculation always occurs, but with a rate of 0, there is effectively no tax accessed.

                            Dave
                            Dave Jampole
                            www.customalpha.com

                            Women and cats will do whatever they want. The sooner men and dogs realize that, the happier they will be.

                            Comment


                              #15
                              Originally posted by davej
                              Paul,

                              You can put the script in the Exit trigger of the field just prior to the sales tax field. If the response is 'Yes', set the tax rate at its normal rate; if the response is 'No' set the tax rate at '0'. That way, the calculation always occurs, but with a rate of 0, there is effectively no tax accessed.

                              Dave
                              Sweet. Now all I have to do is figure what this script you speak of should be and I'll be on my way.

                              Thanks.

                              Paul.

                              Comment

                              Working...
                              X