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

Where are command line options stored?

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

    Where are command line options stored?

    The A5V9 help contains documentation for Starting Alpha Five with Command Line options, which never really explains where the command line code should be stored, what the extension of the file should be or how it should be executed.

    Can someone shed some light on these options.

    I assume that a somehow a batch file is created, but I can't seem to locate any specifics.

    Forum member Tom Henkel posted a nice example of how he customized his Windows title bar, splash screen, and icon which included
    1. Code for the command line
    2. Code for the "Startup" file

    But Tom didn't provide these details either. Maybe they are just assumed, but I plead ignorance.

    I know the "Startup" file has an .txt extension, but what about the file for the command line itself?

    I normally think Start>Run>Open:cmd as the way of executing a command line. But I sure would like to avoid typing the code in each time I use A5 with my application.

    Thanks,
    Bob McGaffic

    #2
    Re: Where are command line options stored?

    Bob

    From the control panel, tools - create shortcut

    That will generate a shortcut on your desktop with command options and a startup file if you add xbasic commands in the last tab of the dialog.

    That'll be an example that you can learn from.
    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


      #3
      Re: Where are command line options stored?

      Thanks, Al. I'll give that a try.

      Bob McGaffic
      Pittsburgh

      Comment


        #4
        Re: Where are command line options stored?

        A simplified explanation:

        The command line is where the instruction goes to tell the operating system what to do. If you ever used DOS, you had what was called a "C" prompt - that is the command line. If you have not used DOS, in Windows you can start up a window called "Command Prompt". Once this is started, you are at the command line. The OS only takes the first parameter (usually a program, batch file, etc.) and all other parameters are passed to it upon execution. So that program must be able to interpret them and decide what to do. Alpha Five does accept command line options and that is what is listed in the help docs.

        A shortcut just stores all the information in a neat and tidy little package that is passed to the command line.

        Comment


          #5
          Re: Where are command line options stored?

          Doug,

          Just what I was looking for. I didn't want to type in a long, tricky text string. Thanks again to both you guys.

          Bob McGaffic
          Pittsburgh

          Comment


            #6
            Re: Where are command line options stored?

            Be careful if you are creating a generic app that could be installed nearly anywhere - including any folder. If you use A5's built-in shortcut genie, it is only designed to work in the folder it was originally created in. (There may be some way to use relative paths - I don't know but it doesn't seem to do that in the genie.)

            Before getting into this, I'd like to point out that the "command line" options don't require using DOS. They go right in the properties of the Windows shortcut. See the window where it says "Target:" - that's where the command line goes. The actual "target" is the first thing and all the arguments follow it.

            The "Start in:" may not be required anymore but leaving it blank used to cause some of the ".dd*" and ".se*" files to show up on the desktop so I still use it just in case.

            The full "command line" in this particular case is:
            C:\PROGS\A5V7\alpha5.exe -nosplash -title="Trak-It6" -icon="E:\A5v7\Trak-It_SP\App\Trak-it.ico" "E:\a5v7\Trak-It_SP\App\Trak_it6.adb"

            Basically this is:
            <The exe program to run> <series of arguments for the program to use>
            In Alpha's case, this can be further broken down into:
            <The exe program to run> <the .adb file to be opened> <optional startup commands that all start with "-">

            As it happens, Alpha doesn't care if the .adb file comes before or after the optional startup arguments and I happened to put the .adb file last in this case. (The fact that the order doesn't matter actually reduces the complexity. However, it may cause confusion if you are looking at multiple examples and wondering "which sequence is right" - it doesn't matter.)

            I know that a big long command line like that is really difficult to read and even more complicated to build for anyone who only builds databases (yes, I'm being facetious) but there is an easy way to start getting used to it. You can start by using the Genie as mentioned in one of the posts above. The resulting .startup file for this one would contain this:
            -TITLE="Trak-It6
            -NOSPLASH
            -ICON=E:\A5v7\Trak-It_SP\App\Trak-it.ico"
            As it happens, I chose to type the parameter names in lower case and Alpha's genie uses upper case. (more "complexity") Take a close look at the "command line" above and you will see all the other really huge differences. (Yes, I'm being facetious again.)

            Another reference is my A5 Command Line Options page. Or, lookup "Starting Alpha Five With Command Line Options" in Alpha's Help file. Their Help file has been updated with some commands that weren't available when I created that web page.

            And Alpha's command line in their actual shortcut would be:
            C:\PROGS\a5v9\alpha5.exe "E:\a5v9\Trak-It_SP\App\Trak_it.adb" -INCLUDE="E:\a5v9\Trak-It_SP\App\Trak_it.startup"
            which really doesn't look much better than my "full" command line above. And, what bugs me about the "include" file is that I can't just look at the link properties to see/verify how the program starts. Now I have to go find that "include" file and open it too - more work for me and I don't like that! (It has been my experience that most things intended to make something "easy" actually create more work for those who know how to do it the "regular" way.)

            (Note: If there are blank spaces in the "program name" part of the shortcut, then you must enclose it in quotes. This is a Windows issue - not an Alpha issue. So, if this was in my Program Files folder the command line would have to be:
            "C:\Program Files\a5v9\alpha5.exe" "E:\a5v9\Trak-It_SP\App\Trak_it.adb" -INCLUDE="E:\a5v9\Trak-It_SP\App\Trak_it.startup")

            Note that the -INCLUDE argument just points to a text file that has all the actual options/arguments in it. In some cases, I've actually seen INCLUDE files with no argumements. In that case, it could have been left off completely and the full command line would be just:
            C:\PROGS\a5v9\alpha5.exe "E:\a5v9\Trak-It_SP\App\Trak_it.adb"

            So what's the problem with using the genie you say? There isn't any - as long as you either build the shortcut on the computer that you are using the application on or you force other users to always install it in a specified folder. The genie, out of necessity I'd guess, hard codes the path into the shortcut which means it won't work on another computer if the application is stored in a different folder. The problem with forcing it to be in a specific folder is that some customers may want to put the application in some other folder or even another drive and get really angry if you say they can't do that. Only a few get upset but some have very legitimate reasons for wanting to put it somewhere else. This is more likely to happen in larger organizations where the IT department has its own requirements (idiosyncrasies?).

            There's also the fact that you will need to understand something about building shortcuts yourself if you want to use a 3rd party installer such as Astrum or Wise. In that case you will have to understand the really difficult concept of what is the "link target" (program being run) and what constitutes the rest of the "command line" (all the other arguments).

            For those of you who use Astrum, here's a typical startup icon definition as would be used in Astrum:

            For anyone interested, the full Command line is: <InstallDir>\Trak_It\Trak_It.adb -nosplash -title="Trak-It SP" -icon="<InstallDir>\Trak_It\Trak-It.ico"

            As I hope anyone reading this can figure out, the use of the <InstallDir> variable allows this to be installed to any folder on any drive on any computer. If I was using the .startup file and the -Include= command, that wouldn't be possible because the path to the icon file would be hard coded inside the file.

            One other comment. If you don't understand what's going on with shortcuts, how much trouble will you (that's a generic "you" not aimed at anyone in particular) be in when a customer deletes one or, worse yet, messes one up and you have to fix it? (Rare but it has happened to me.)
            Last edited by CALocklin; 09-25-2008, 11:52 PM.

            Comment


              #7
              Re: Where are command line options stored?

              Cal, can you give guidence on the 'launch program file" option in Astrum, cause it does not follow the same format as the shortcut.

              Here is my current settings, but it does not work : <InstallDir>\alpha5.exe <InstallDir>\Application\PLM.adb -INCLUDE=<InstallDir>\Application\PLM.startup

              Any idea?

              Kind regards
              George

              Comment


                #8
                Re: Where are command line options stored?

                Another useful tip following Cal's brilliant explanation. If you should ever want to make changes to a shortcut's target or the start in then Windows will not accept a change unless the folders/paths actually exist on the PC where your shortcut is pointing.

                In other words, the folder that the shortcut points to must already exist before Windowswill allow a change.

                Michael

                Comment


                  #9
                  Re: Where are command line options stored?

                  Originally posted by georgefurnel View Post
                  Cal, can you give guidence on the 'launch program file" option in Astrum, cause it does not follow the same format as the shortcut.

                  Here is my current settings, but it does not work : <InstallDir>\alpha5.exe <InstallDir>\Application\PLM.adb -INCLUDE=<InstallDir>\Application\PLM.startup

                  Any idea?

                  Kind regards
                  George
                  I've never used that option. My guess is that either:

                  1. It will only start A5 (whatever the main program is) but doesn't recognize the rest of the command line.

                  or, more likely (although still just guessing):

                  2. There may be blank spaces in your path and you need to add quotes so Windows can figure out what's what. (Isn't the INCLUDE file supposed to be in quotes anyway? Again, I don't use it so I'm not sure.)

                  Perhaps something like this:

                  "<InstallDir>\alpha5.exe" "<InstallDir>\Application\PLM.adb" -INCLUDE="<InstallDir>\Application\PLM.startup"

                  Comment


                    #10
                    Re: Where are command line options stored?

                    Cal,

                    You are absolutely correct the format "<InstallDir>\alpha5.exe" "<InstallDir>\Application\PLM.adb" -INCLUDE="<InstallDir>\Application\PLM.startup" works perfectly.

                    Kind regards
                    george

                    Comment

                    Working...
                    X