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

Please Help!! I've Lost All My Code

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

    Please Help!! I've Lost All My Code

    This is a total disaster! I've been working for about 2 weeks on a project and tonight, just before I was about to package it up, I compacted the database. When I went back in, ALL OF MY CODE AND SCRIPTS WERE GONE! I still have the .ADB, .ALB, and .ALM files which appear to have data in them. Does anyone know how I might be able to retrieve my stuff? Please...
    Thanks.
    Michael

    #2
    Re: Please Help!! I've Lost All My Code

    Michael, if you're talking about the scripts and code found on the CODE PAGE of the control panel, they're stored in the database library files you mention (plus the .ALX file). I don't know of a way to recover them except by restoring from a good backup. Perhaps others will have more helpful suggestions for you, so I'll keep an eye on this thread. Good luck.

    Comment


      #3
      Re: Please Help!! I've Lost All My Code

      Tom,
      Thanks for the early reply. I thought my automatic backup was backing up this project, but learned only too late that it wasn't. (Probably happened when I switched its location from Drive C to Drive E. :() My only saving grace so far has been that I ran A5Doc last night a few hours prior to my disaster, so most of the code is stored inside that. I think something is vitally wrong with one of the core Alpha files as neither Copying nor Exporting and re-Importing XBasic scripts from another database into this one has been successful.
      --Michael

      Comment


        #4
        Re: Please Help!! I've Lost All My Code

        Michael,

        You should be able to test the integrity of your Alpha five installation by running Alphasports from the samples directory of your program files directory.

        The problems you describe now suggest possibilities to me:
        a) your system has a virus or other malware; or
        b) you've chosen names for things in your database that are illegal; or
        c) you've chosen to split the files in your database across multiple folders or subfolders and some of them have illegal names.

        A pathing issue might explain the difficulty alpha is having trying to work with your database, especially if the problem manifested itself after you moved the database to a different drive. In order for a database to be fully "portable" all of its objects must be in the same directory.

        Comment


          #5
          Re: Please Help!! I've Lost All My Code

          Update - Miracle in NY :)

          I don't understand what just happened, but maybe someone can explain. I have an older copy of this database from early February stored on my C: drive. I thought I might be able to use the Export... and Import... functions to salvage some of the scripts and functions, so I did the following:

          1. I did another Database Compact on the corrupted database on drive E:.
          2. I opened the older version of the database on drive C:.
          3. I Exported all of the Scripts and Functions in the drive C: version to a .TXT file.
          4. I opened the corrupted version of the database on drive E:.
          5. I Imported all of the Scripts and Functions from the .TXT file created in Step #3 above.

          Now here's the both weird and miraculous part...

          6. When the Import completed, ALL of the Scripts and Functions that I had lost last night re-appeared in their entirety, including the last one I had created around 10:36PM.

          How did that happen? I had even copied the .ADB, .ALB, and .ALM files to another location, renamed them for access in FoxPro and still couldn't find the code, i.e., the Memo fields, although indicating data available, displayed as blank when I browsed them. So how did my code return? If anyone could explain, I'd love to know. Right now I'm very thankful and have already made multiple backups ;).

          --Michael

          Comment


            #6
            Re: Please Help!! I've Lost All My Code

            Can't say. Would guess the failure to copy over the .ALX file might have been a factor.

            Comment


              #7
              Re: Please Help!! I've Lost All My Code

              Most likely the import process updated the indexes in the file that holds the code. When that happened the code was available again. Much like missing table records due to a corrupted cdx.
              There can be only one.

              Comment


                #8
                Re: Please Help!! I've Lost All My Code

                Reading your initial post, I knew the scripts are there..somewhere but your post didn't clarify where are these script?
                Compacting a database does not delete any scripts regardless of where they are.. as how to explain the miracle.. I think your database was pointing to the wrong dictionary..
                Regardless, renaming and moving database between directories always results in a mess up like this but the data is always there.
                Careful when moving a database from one place to another, and always back up first.

                Comment


                  #9
                  Re: Please Help!! I've Lost All My Code

                  Originally posted by Stan Mathews View Post
                  Most likely the import process updated the indexes in the file that holds the code. When that happened the code was available again. Much like missing table records due to a corrupted cdx.
                  I think Stan has the correct explanation. And Gabe has sound advice.
                  Peter
                  AlphaBase Solutions, LLC

                  [email protected]
                  https://www.alphabasesolutions.com


                  Comment


                    #10
                    Re: Please Help!! I've Lost All My Code

                    He imported the scripts.. not the records..
                    Indexes came into play only in compacting.
                    The db was pointing to the current dictionary, which didn't have the scripts...until imported via the txt file.

                    Comment


                      #11
                      Re: Please Help!! I've Lost All My Code

                      just to add to this thread, i overwrote the current alx file with an older version and some scripts were missing. i deleted the alx file and ran database compact and the scripts were restored.

                      Comment


                        #12
                        Re: Please Help!! I've Lost All My Code

                        Originally posted by michaelklein View Post
                        How did that happen?
                        It's hard to say why you recovered the files, unless it was just the index file (ALX file). ADB has no importance except to keep the currently attached tables and some other minor info.

                        Originally posted by michaelklein View Post
                        I had even copied the .ADB, .ALB, and .ALM files to another location, renamed them for access in FoxPro and still couldn't find the code, i.e., the Memo fields, although indicating data available, displayed as blank when I browsed them. So how did my code return? If anyone could explain, I'd love to know.
                        The code itself (scripts, udfs, classes, enumerations) are stored in an encrypted format in the memo field (ALM). I have some internal utilities (it is definitely Not-For-Sale) that can get back A5 code from some damaged memo files, but it is somewhat painful to use.

                        I also have utilities (again Not-For-Sale) that can potentially recover code from AEX compiled files as well.

                        Should this happen in the future, I suggest that you immediately stop writing to the drive (especially windows) if possible, so there may be a chance of finding old files or file fragments. It is possible to sometimes recover these sections and then grab what is recoverable. To recover this data can sometimes be done quickly, many times it can take much work and time. One time I had to create a really complicated code to intelligently piece together parts of a file scattered all over a hard drive. Not fun, Not easy. Much easier and better if you just had a backup.

                        While a normal data recovery company can sometimes recover regular DBF database info, I'll bet they couldn't do the data dictionaries of Alpha nor AEX files.

                        But it is services I have done on occasion for some people on this board, and sadly, for myself as well when I crashed during a development session (and hadn't backed up yet) and lost my recent edits. So should someone find them in this situation, I highly suggest that they stop what they are doing immediately and give me a call right away.
                        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


                          #13
                          Re: Please Help!! I've Lost All My Code

                          like i mentioned ira, i overwrote the alx file with an older version, none of the others. that's why rebuilding the alx index brought back the scripts, because they're not stored in the alx. it's only holds pointers, as far as i know.

                          i didn't mention, but i moved the whole folder to another drive before i deleted the alx and did the compact.

                          Comment


                            #14
                            Re: Please Help!! I've Lost All My Code

                            Hi Gary,

                            Actually, a missing ALX or a corrupted ALX, could have been replaced with any good ALX file (of any ADB), and probably with a renamed DDX file. I don't know if Alpha is smart enough to totally replace an ALX it if missing or corrupted, but it could (I haven't done that experiment, but it's easy for anyone to do - not sure if that's what you said). It just is restoring the original data dictionary index definitions, the pointers being rebuilt upon a compact, or using an index rebuild command if changed to DBF extensions. The data file (ALB) still had all it's pointers to the memo file (ALM) record entries. That's an easy recovery.

                            The ALB has relatively little info in it, mostly entry name and type. So if it is missing, the memo file (ALM) can be recovered , but you will have potentially multiple entries of the same item, which need to be sorted out. In this case, you need to decrypt each memo entry (not trivial) and see what each looks like. Fortunately, with most of the code, there is a date and time stamp at the top of the code that makes recognizing the most recent easier.

                            Finally, if the memo file (ALM) is corrupted, it has enough structure left by itself to sometimes recover at least the beginnings of a code segment (which for most people codes are typically not that long), which means you can generally find the end in the segment as well.
                            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


                              #15
                              Re: Please Help!! I've Lost All My Code

                              ok, thanks for the info, ira.

                              Gary

                              Comment

                              Working...
                              X