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

error modifying a script?

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

    #16
    Re: error modifying a script?

    Originally posted by G Gabriel View Post
    What are you talking about?
    I'm talking about the line of code that the code fails on, which happens to be
    if(left(line1,9)="'password",.t.,.f.)
    As I said, I can't duplicate Dave's failure, but the left() function is the only argument in the expression that could potentially have an argument out-of-range.

    Originally posted by G Gabriel View Post
    I could see that perhaps a5_add_timestamp() is failing internally, possibly assuming that alpha does that as a matter of routine whenever you save any script. Maybe, and if so, that would be a good point.
    It does execute a5_add_timestamp() on code editor saves of scripts and functions. If the A5 settings are enabled, it executes the "a5_add_timestamp" script which does the actual insert.

    Originally posted by G Gabriel View Post
    But what does 'xxx has to do with anything?
    It is a line that is shorter than the left(line1,9) is trying to extract, and it is very rare to have a line that short on the 1st line of code, hence the most likely issue is the length, and hence my recommendation to remove the line or make it longer.

    The left() function should not normally return that error, but without being able to reproduce the error the above is the best recommendation.

    Originally posted by G Gabriel View Post
    It's a commented line in the top of the script, it is not a password. Alpha will check for a password and confirms the existence of one when you so signify, but you could put any garbage and comment it out and it won't make a difference whether it's one character or 9.
    Alpha executes the line if the code timestamp option is on, and it executes the line no matter what the text of it is. And that is the failing point, so the error message points to an issue with length versus the argument of 9.
    Regards,

    Ira J. Perlow
    Computer Systems Design


    CSDA A5 Products
    New - Free CSDA DiagInfo - v1.39, 30 Apr 2013
    CSDA Barcode Functions

    CSDA Code Utility
    CSDA Screen Capture


    Comment


      #17
      Re: error modifying a script?

      The error, which refers to line 20, according to Dave happens with ANY other scripts when he tries to modify it & save it so line 20 of the one he displayed is not the issue.

      I am more inclined to believe that the function itself (line 20 in the function), not the script, is the problem.

      Comment


        #18
        Re: error modifying a script?

        Gabe is correct.

        I can try to modify line 20 or line one, with or without a password and the result is the same.


        .
        Dave Mason
        [email protected]
        Skype is dave.mason46

        Comment


          #19
          Re: error modifying a script?

          Originally posted by G Gabriel View Post
          The error, which refers to line 20, according to Dave happens with ANY other scripts when he tries to modify it & save it so line 20 of the one he displayed is not the issue.

          I am more inclined to believe that the function itself (line 20 in the function), not the script, is the problem.
          EVERY SAVE of the code editor when it is a script or function tab calls code that includes a call of the function a5_add_timestamp().

          That function plays a script using script_play_local("a5_add_timestamp") if the time stamp is enabled in A5 settings. EVERY TIME!

          The script a5_add_timestamp fails on line 20 of the script as it shows in the error image Dave supplied, not the function!

          The only relevance to the script or function Dave is editing on the code tab is the 1st line of text of the code's text that is passed as an argument to the function a5_add_timestamp() and eventually to the script a5_add_timestamp
          Regards,

          Ira J. Perlow
          Computer Systems Design


          CSDA A5 Products
          New - Free CSDA DiagInfo - v1.39, 30 Apr 2013
          CSDA Barcode Functions

          CSDA Code Utility
          CSDA Screen Capture


          Comment


            #20
            Re: error modifying a script?

            Maybe if Dave shut off the Time Stamp option in the settings, we could see if that is the culprit...

            Tom

            Comment


              #21
              Re: error modifying a script?

              Hi Dave,

              Originally posted by DaveM View Post
              I can try to modify line 20 or line one, with or without a password and the result is the same.
              Line 20 of your code is totally irrelevant. That's not the failing point

              Very occasionally, what seem to be non-visible characters (my term - not actually proven as to what it is) have caused issues on a code editor line, so if deleting a line, do it by selecting all text from line 1 to at least the beginning of line 2, and hit delete. Deleting a character at a time will not remove the issue associated with these "non-visible characters".

              But, since your problem can't be reproduced by others, the next step is to do a reinstall of Alpha 5 and see if the problem goes away.

              If that doesn't work, you can try recreating the database by exporting all the code, and reimporting to a new one where you add the same tables/sets back. Any corruption error would probably be due to an issue in the ADB, ALB, ALX and ALM files. Also note you will need to copy any import definitions which are also stored in the database files from the old one.

              Why the failure at that point? The cause can be a cascade of errors from a corruption that destabilizes Alpha in such a way that all bets are off. It's rare to see it in XBasic, but it does happen. In most cases, it's code you did, but since many settings in A5 configure Alpha from the database files, a bad piece of data there can cause A5 to go astray.
              Regards,

              Ira J. Perlow
              Computer Systems Design


              CSDA A5 Products
              New - Free CSDA DiagInfo - v1.39, 30 Apr 2013
              CSDA Barcode Functions

              CSDA Code Utility
              CSDA Screen Capture


              Comment


                #22
                Re: error modifying a script?

                Hi Tom,

                Originally posted by Tom Henkel View Post
                Maybe if Dave shut off the Time Stamp option in the settings, we could see if that is the culprit...
                That's a real good suggestion, and easy to try too!

                Added: The point of error would be more exact. The "culprit" would be the source of the problem that eventually causes it to manifest as the error shown.
                Last edited by csda1; 05-26-2010, 02:04 PM.
                Regards,

                Ira J. Perlow
                Computer Systems Design


                CSDA A5 Products
                New - Free CSDA DiagInfo - v1.39, 30 Apr 2013
                CSDA Barcode Functions

                CSDA Code Utility
                CSDA Screen Capture


                Comment


                  #23
                  Re: error modifying a script?

                  However, I can tell you that it is error-ing out in line 20 of the a5_add_timestamp script, and that it is failing when taking the left 9 characters of the 1st line of the code, in your case 'xxx
                  Just a note. In trying to save a script in V5 or V8 with 'xxx as the first line, it saves but upon editing the 'xxx is not there.
                  There can be only one.

                  Comment


                    #24
                    Re: error modifying a script?

                    I would report this as a bug, not me, Dave with a zipped db.
                    Something went array in your db and the function is not capturing the correct machine time for some reason.
                    Let's assume that you did all the other stuff ..compacting, refresh CP, updating indices.. all the usual suspects.

                    Comment


                      #25
                      Re: error modifying a script?

                      Now have gone much further. Was off line for a while.

                      v7 still almost works correctly. Had on error and it seems ok now.

                      v9 same as v10

                      I can write a script and save it. If I simply define a variable after that, it goes wrong.

                      Have deleted all of alpha complete. reinstalled all of v7, v9, v10.5
                      have written a new db from scratch.

                      Problem still there.

                      I will go further as I go. Maybe I missed something in the registry?? possible that once something in memory is triggered in one db, it transfers to a new db when opened.

                      ran my virus scanner to it's strongest and malwarebytes.

                      Whatever it is, it started yesterday afternoon.
                      Dave Mason
                      [email protected]
                      Skype is dave.mason46

                      Comment


                        #26
                        Re: error modifying a script?

                        I don't see this as a bug if it is an issue exclusively to this one solitary application, right?
                        Mike W
                        __________________________
                        "I rebel in at least small things to express to the world that I have not completely surrendered"

                        Comment


                          #27
                          Re: error modifying a script?

                          it is not 1 single application anymore.

                          It is every db used with both v9 and v10.5

                          It also just manifested itself in a form:

                          copied a button that opened another form, renamed it, deleted the action scripting to open the form, replaced it with another action script to open a fifferent for, could not save - same error message.

                          I deleted the copied button, remade it from scratch and it works fine.
                          ???

                          This was all from a fresh start of v9

                          edit - this was yet another db/app
                          .
                          Dave Mason
                          [email protected]
                          Skype is dave.mason46

                          Comment


                            #28
                            Re: error modifying a script?

                            How about creating a sample database that displays the problem and letting us test on our machines?
                            There can be only one.

                            Comment


                              #29
                              Re: error modifying a script?

                              It still could be a bug and under the "Perfect Storm" scenario manifested itself. Problem is, we don't know the perfect storm scenario, nor can we, nor can alpha, without a db. Clearly, it is not something to do with an error in a specific script. I would have submitted a bug report but it would be unreasonable to expect alpha to figure it out not knowing the context.

                              This thing seems malicious and the sooner you deal with it the better. I am not saying it is or it is not a bug, I don't know but something malicious and ubiquitous as this deserves a report.

                              Here is another thought. Go to your Windows and restore an earlier Restore Point. Your Registry might have corrupted.

                              Another thought:
                              Go to Word and see if you could stamp date/time.
                              Last edited by G Gabriel; 05-26-2010, 05:01 PM.

                              Comment


                                #30
                                Re: error modifying a script?

                                OK,

                                Looks like the culprit was in the settings to do with time stamp. At least that seems to be it.

                                I changed a setting on the time stamp and it seems to be working now.

                                Thanks a lot for the help. If anything changes, I will add to this post.

                                I do not understand how it either worked for a while and acted up or got changed since I was not there in v9 or v10.

                                edit: Gabe may be right about the registry. I ran malwarebytes yesterday and it cleand some stuff from the registry and I bet that setting was there. ???
                                Dave Mason
                                [email protected]
                                Skype is dave.mason46

                                Comment

                                Working...
                                X