Alpha Video Training
Results 1 to 3 of 3

Thread: Creating New Functions Deletes Scripts and Causes Strange Issues

  1. #1
    Member
    Real Name
    Elijah Gartin
    Join Date
    Nov 2012
    Posts
    2

    Default Creating New Functions Deletes Scripts and Causes Strange Issues

    Hello,

    The back story on this is rather long, but the project started in 2012 and was pieced together by me with the gracious help of Al. The project also started in QReportBuilder and am having to now drudge through updating the application again with the A5v11 Desktop Application. For reference, I've been apart from any Alpha Five Xbasic type development except for minor updates to this project over the years. I'm able to understand the documentation for the most part, but I haven't found anything yet that seems to fit the issue that I'm experiencing, thus, this post.

    The client asked me to add some logic to do a currency exchange rate calculation. Therein, I created two functions and two new variables. One to replace the current if statement calculated field and pass the result of that into my other function that does the actual calculation for the exchange rate. When running the functions in the Interactive Window, everything works great. However, when I begin to attempt to add these functions into the solution, everything gets... weird. The function will work in the report run up to a certain point as well, but it breaks a bunch of items because I think it changes the reference of the calculated field that others depend on (which I'll be working on fixing).

    The biggest issue I'm experiencing right now is that upon adding the functions `exchangeRateConversion(4 Parameters)` and `netInvoiceLine(5 parameters)`, Alpha Five then deletes some of the data import scripts that are crucial to importing items from Quickbooks and then wipes out a lot of the content in the other functions (or at least seems to as opening them just shows a blank white space). It also removes the QReportBuilder feel to the program and removes what the client would be familiar with in terms of running the report with the "favorited" items.

    I'm at a bit of a loss right now so any guidance or assistance to help me understand why adding two functions is seemingly trashing the program, I'd be very grateful.

    Thank you,
    Elijah

  2. #2
    Moderator
    Real Name
    Alan Buchholz
    Join Date
    Oct 2000
    Location
    Delavan, Wisconsin
    Posts
    9,557

    Default Re: Creating New Functions Deletes Scripts and Causes Strange Issues

    Elijah

    Long time no talk..

    I've emailed you directly so we can connect and figure this out.
    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.

  3. #3
    Moderator
    Real Name
    Alan Buchholz
    Join Date
    Oct 2000
    Location
    Delavan, Wisconsin
    Posts
    9,557

    Default Re: Creating New Functions Deletes Scripts and Causes Strange Issues

    Multiple issues were resolved.

    When copying files to a new directory get all of the tables files. Including those pesky .ddx files.

    Database/workspace container files can get corrupted (rarely) but can be replaced by a new one. Add tables and sets. Import code objects from exported file.

    Object calculated field objects note that they are orphaned if their definition is removed. Re-add the definition.

    Object names: Start with a letter use only letters, numbers, and underscores . Even in all parts of the fully qualified file names.

    Alpha will tell you what's wrong in it's own way. Easy to see when the same things have happened over the years.

    Multiple issues does make for muddy waters.
    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.

Similar Threads

  1. operations vs scripts or functions
    By ocastillo in forum Windows Desktop Applications
    Replies: 6
    Last Post: 01-31-2017, 03:11 PM
  2. Functions or scripts
    By Dave Mac Callum in forum Alpha Five Version 7
    Replies: 3
    Last Post: 03-17-2009, 01:46 AM
  3. how to: scripts and functions
    By fddizon in forum Alpha Five Version 8
    Replies: 3
    Last Post: 02-12-2008, 11:28 PM
  4. functions vs scripts
    By dik_coleman in forum Alpha Five Version 6
    Replies: 6
    Last Post: 10-03-2004, 11:14 AM
  5. Scripts and Functions
    By dik_coleman in forum Alpha Five Version 5
    Replies: 5
    Last Post: 06-16-2004, 04:17 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •