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

Conditional Look Up

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

    Conditional Look Up

    I am building a small app that keeps track of all my equipment on my home network including the IP Address. I want to assign the IP by Octet so I have a lookup table that lists all values from 0 to 255 and a Boolean column for each of the allowable home network ranges 10.#.#.#, 172.#.#.#, and 192.168.#.#. OK I first select the first octet and then based on that value only certain values are allowed for the second octet if 10 then all values from 0 to 255, if 172 the only 16 to 31 and if 192 then only 168 is allowed. Once I have selected all four of the octets I want the last field in the table to be generated/calculated by concatenating each of the octet fields to one string resulting in the assigned IP. eg: 10.25.34.3. Now my question. Can I do this (concatenation) with field rules? If so then how? I always end up with the same value in each record. Not the value that would be generated from that record.

    SvbHvman

    #2
    Re: Conditional Look Up

    Hi Larrin,

    Welcome to Alpha and sorry until now noone has replied on your request but I think the reason is that we do not know how to help you.
    You are creating an application and you want to save data.
    Not clear how you import that data. Entering (by hand) or do you need an importscript?
    Not clear in which format you have all that data now. Already in Alpha?
    Also what table / fields you want it in.
    What has to be checked/adepted/processed before? What do you mean with 'selected'? Yes you can concatenate misc fields in another field but is that what you want? or do you want to filter it to another table?

    When entering records you can use fieldrules to prevent entering unwanted data or guide users with entering their data correct.

    If you can tell what you want step by step we all can and will help you. As you can see there are more questions then answers.

    I invite you to make a new thread for each specific question if you have searched the messageboard because a lot of items have been discussed and are there illustrated with examples and explications. So be welcome.

    Ton
    Most things are simple but unfortunately only after the first time

    Comment


      #3
      Re: Conditional Look Up

      I guess I put too much information in the first post so let me narrow it down. I have two boxes to enter information --> [ 1 ].[ 2 ]. The first box can only have one of three values, 10, 172 or 192. Simple enough with a field rule. However, the second box data is limited by what the value in the first box is. For example:
      1. If box 1 contains 10 then the permissible values for box 2 are 0 to 255
      2. If box 1 contains 172 then the permissible values for box 2 are 16 to 31
      3. If box 1 contains 192 then the permissible value for box 2 is only 168


      How do I make a rule for box 2?

      Comment


        #4
        Re: Conditional Look Up

        Is your box a field in a record or an object on a form?

        1) You can make a 'simple list' with all possible combinations.
        or
        2) Take a look at the Alphasports example in the directory 'sample'.
        The fieldrules for table invoice_header use a conditional lookup.
        See attachment.
        Run the example to see or this is what you want.

        Ton
        Most things are simple but unfortunately only after the first time

        Comment


          #5
          Re: Conditional Look Up

          Hi Larrin,

          Ask three Alpha developers how to do this and you will have five different suggestions.

          My suggestion for what it is worth, is to use OnDepart event for box 2, you can then pop up a message if the value is out of range. You can at the same time prevent the record from being saved with field rules Validation.
          Regards
          Keith Hubert
          Alpha Guild Member
          London.
          KHDB Management Systems
          Skype = keith.hubert


          For your day-to-day Needs, you Need an Alpha Database!

          Comment


            #6
            Re: Conditional Look Up

            Thanks for the replies but neither is really what I am looking for, although the Alpha Sports example is close. Referring to the picture below:



            I want a drop down for each Octet with all permissible values. Now for Octet 1 this is simple because there only three choices and they always are the same. However, all of the others are dynamic and change based on the preceding octet and this chart.



            1. If box 1 contains 10 then the permissible values for box 2 are 0 to 255
            2. If box 1 contains 172 then the permissible values for box 2 are 16 to 31
            3. If box 1 contains 192 then the permissible value for box 2 is only 168


            Can this be done using Alpha 5 and drop downs? Ultimately I want to filter out the previously used values from Octet 4 and only show the available values (can't reuse values on the same network).

            I just need shown how to build a simple drop down list based on a previous selection and I'm sure I can run with it from there.

            Comment


              #7
              Re: Conditional Look Up

              Hi Larrin,

              I can see better now what you are trying to do.

              You are on the right path with Conditional Lookup. So the lookup to each table will depend on the value in oct1.

              You will need three extra tables with a simple structure that has all the numbers in the ranges specified. The quickest way to fill these extra tables is do it on a spreadsheet first then import.

              To concatenate, you will need a calculated field in field rules like this. oct1+"."+oct2+"."+oct3+"."+oct4

              Have fun.
              Regards
              Keith Hubert
              Alpha Guild Member
              London.
              KHDB Management Systems
              Skype = keith.hubert


              For your day-to-day Needs, you Need an Alpha Database!

              Comment


                #8
                Re: Conditional Look Up

                Larrin, Attached is a small database that helps solve your problem. There are still some issues for you to work out, but the field rules get you there. In my solution I create just one lookup table (I started with a three-table solution like Keith suggested, but then figured one was easier). There is a filter that determines which values are valid.

                When you load the database, go to the 'Code' tab and run the script 'Create IP Tables-n' which creates the 'IP_Choices' table.
                There are three kinds of people in the world: those who can count, and those who can't.

                Comment


                  #9
                  Re: Conditional Look Up

                  Thanks! I was close to this a while back but the mistake I made was that I had a separate column for each Octet_1 value in my look-up table and using a Boolean bit if was valid. This was causing all sorts of headaches. So now I see the error of my ways.

                  Larrin

                  Comment

                  Working...
                  X