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

form variables not printing?

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

  • whanigsberg
    replied
    RE: form variables not printing?

    Hi Mac,

    "Do you think declaring global variables more than once can cause a problem here?"

    Almost certainly not unless you have the same variable declared as shared in one place and global in another or some such.

    Alpha will do fine with this but you will go nuts wondering why Alpha doesn't see your variable when it is in fact seeing one of your variables. You, on the other hand, are thinking about a different variable of different scope to which you have given the same name.


    It is really difficult to give you suggestions without examining what you have done.

    You should think about sanitizing your data (create a dummy data set) so you can seek assistance more effectively.

    Bill

    Leave a comment:


  • L. McIntosh
    Guest replied
    RE: form variables not printing?

    William,

    I have something for you to ponder on. I've been viewing 'error' statements in the trace window and this particular statement came up -

    Recursion error encountered while searching for Classes
    Var Frame [0] 1378
    Var Frame [1] 140d
    Var Frame [2] 1378
    Var Frame [3] 194b

    Do you think declaring global variables more than once can cause a problem here? I know the form initiates the global scope on all the variables, but then in the script I have it dimming them again? Do you think this could be the problem?

    I've found out that changing them back too 'shared' in the script will not let them pass to the form. If global variables are visible to all sessions in alpha, then how come this happens? Am I missing something simple here? It's got me confused William.

    Any help appreciated -

    Mac

    Leave a comment:


  • L. McIntosh
    Guest replied
    RE: form variables not printing?

    William,

    Yes, the variables are global on the report? As far as the app goes - what could prohibit this exchange in the app itself? If you can give me some ideas I'll sure check it out. I wish I could attach a copy of my app, but the data is extremely private. This script is just one of many in this app, but since you introduced me to the report theory, I think I'll go back and change the forms I have designed to print and insert them into reports. Yes, they had multiple variables on them too and did not have this problem?

    Sure appreciate any info you can come up with William -

    Thanks
    Mac

    Leave a comment:


  • whanigsberg
    replied
    RE: form variables not printing?

    Have you declared the variables in the report design. You must declare them with the same scope to which you did elsewhere which is global, correct?

    If this is not the problem then there is something specific to your application which cannot be addressed in the abstract.

    Bill

    Leave a comment:


  • L. McIntosh
    Guest replied
    RE: form variables not printing?

    Tom,

    Yes they do have a value within the script. Just not on the form?

    Anymore sugestions appreciated - thanks

    Mac

    Leave a comment:


  • Tom Cone Jr
    replied
    RE: form variables not printing?

    Suggest you print these variables to the trace window immediately after you assign them values from the data table. This will permit you to verify that they aren't empty. An empty field object won't print.

    -- t

    Leave a comment:


  • L. McIntosh
    Guest replied
    RE: form variables not printing?



    I'm sorry William, the five(5) variables I'm talking about are;
    PATH1
    PATH2
    PATH3
    CYTO1
    CYTO2
    Hope this helps - sorry again :-)

    Mac

    Leave a comment:


  • L. McIntosh
    Guest replied
    RE: form variables not printing?

    William,

    Excellent idea!!! I imported the form into a report 'stats report' and really worked great! I then ran the script and to no avail, it still does not print those 5 variable values? Also, I did check the variables on the report layout and they are all 'global'? So, I thought I'd let you see if you can find anything wrong with this script?

    'Date Created: 29-Jan-2004 08:44:51 PM
    'Last Updated: 28-Nov-2004 07:21:08 AM
    'Created By : Mac
    'Updated By : Mac
    '-----------------------------------------------
    'THIS SCRIPT PULLS DATA FOR DAILY CYTO SCREENINGS
    'ALL PARTS THEREOF 'PAPPY 1.1' DATABASE.
    '(c)Copyright 1996-2001, LeMac Inc, All rights reserved
    'Indexed: EN-I-A "Cyto Screenings"
    'Updated: 12/26/01
    'Changed: 04/08/03 Spead up processing with new indexes
    'Changed: 01/17/04 Updated to rtrv prvs years rcrds
    '------------------------------------------------
    DIM global DATE1 AS D
    DIM global DATE2 AS D
    DIM SHARED START_DTE AS D
    DIM SHARED END_DTE AS D
    DIM SHARED TBL AS P
    DIM SHARED DBE AS P
    DIM global TTL_DAYS AS N
    DIM global CY1_RSCRNSL AS N
    DIM global CY1_RSCRNCS AS N
    DIM global CY2_RSCRNSL AS N
    DIM global CY2_RSCRNCS AS N
    DIM global CY3_RSCRNSL AS N
    DIM global CY3_RSCRNCS AS N
    DIM global TTL_CY1_TME AS C
    DIM global TTL_CY2_TME AS C
    DIM global TTL_CY3_TME AS C
    DIM global CY1_TMEGYN AS C
    DIM global CY1_TMENGYN AS C
    DIM global CY1_TMEOTHR AS C
    DIM global CY2_TMEGYN AS C
    DIM global CY2_TMENGYN AS C
    DIM global CY2_TMEOTHR AS C
    DIM global CY3_TMEGYN AS C
    DIM global CY3_TMENGYN AS C
    DIM global CY3_TMEOTHR AS C
    DIM global CYTO1 AS C
    DIM global CYTO2 AS C
    DIM global CYTO3 AS C
    DIM global PATH1 AS C
    DIM global PATH2 AS C
    DIM global PATH3 AS C
    DIM global PATH4 AS C
    DIM global PATH5 AS C
    DIM global CYTO1_SL AS N
    DIM global CYTO2_SL AS N
    DIM global CYTO3_SL AS N
    DIM global PATH1_SL AS N
    DIM global PATH2_SL AS N
    DIM global PATH3_SL AS N
    DIM global PATH4_SL AS N
    DIM global PATH5_SL AS N
    DIM global CY1_SL_HR AS N
    DIM global CY2_SL_HR AS N
    DIM global CY3_SL_HR AS N
    DIM global CY1_SL_DAY AS N
    DIM global CY2_SL_DAY AS N
    DIM global CY3_SL_DAY AS N
    DIM global CY1_HR_DAY AS C
    DIM global CY2_HR_DAY AS C
    DIM global CY3_HR_DAY AS C
    DIM global CY1_CASES AS N
    DIM global CY2_CASES AS N
    DIM global CY3_CASES AS N
    DIM global CY1_DAYS AS N
    DIM global CY2_DAYS AS N
    DIM global CY3_DAYS AS N
    DIM global CY1_GYNCS AS N
    DIM global CY2_GYNCS AS N
    DIM global CY3_GYNCS AS N
    DIM global CY1_GYNSL AS N
    DIM global CY2_GYNSL AS N
    DIM global CY3_GYNSL AS N
    DIM global CY1_NGYNCS AS N
    DIM global CY2_NGYNCS AS N
    DIM global CY3_NGYNCS AS N
    DIM global CY1_NGYNSL AS N
    DIM global CY2_NGYNSL AS N
    DIM global CY3_NGYNSL AS N
    DIM global CY1_NDAYS AS N
    DIM global CY2_NDAYS AS N
    DIM global CY3_NDAYS AS N
    DIM global CY1_OTHRCS AS N
    DIM global CY2_OTHRCS AS N
    DIM global CY3_OTHRCS AS N
    DIM global CY1_OTHRSL AS N
    DIM global CY2_OTHRSL AS N
    DIM global CY3_OTHRSL AS N
    DIM global PATH1_DAYS AS N
    DIM global PATH2_DAYS AS N
    DIM global PATH3_DAYS AS N
    DIM global PATH4_DAYS AS N
    DIM global PATH5_DAYS AS N
    DIM global PATH1_TIME AS C
    DIM global PATH2_TIME AS C
    DIM global PATH3_TIME AS C
    DIM global PATH4_TIME AS C
    DIM global PATH5_TIME AS C
    DIM global PATH1_CASES AS N
    DIM global PATH2_CASES AS N
    DIM global PATH3_CASES AS N
    DIM global PATH4_CASES AS N
    DIM global PATH5_CASES AS N
    DIM global PATH1_RESCRN AS N
    DIM global PATH2_RESCRN AS N
    DIM global PATH3_RESCRN AS N
    DIM global PATH4_RESCRN AS N
    DIM global PATH5_RESCRN AS N
    DIM global PATH1_SPOTCK AS N
    DIM global PATH2_SPOTCK AS N
    DIM global PATH3_SPOTCK AS N
    DIM global PATH4_SPOTCK AS N
    DIM global PATH5_SPOTCK AS N
    DIM TEC(3) AS C
    DIM tmegyn(3) AS N
    DIM tmergyn(3) AS N
    DIM tmengyn(3) AS N
    DIM tmeothr(3) AS N

    TTL_DAYS = 0
    CY1_RSCRNSL = 0
    CY1_RSCRNCS = 0
    CY2_RSCRNSL = 0
    CY2_RSCRNCS = 0
    CY3_RSCRNSL = 0
    CY3_RSCRNCS = 0
    TTL_CY1_TME = ""
    TTL_CY2_TME = ""
    TTL_CY3_TME = ""
    CY1_TMEGYN = ""
    CY1_TMENGYN = ""
    CY1_TMEOTHR = ""
    CY1_RTME = ""
    CY2_TMEGYN = ""
    CY2_TMENGYN = ""
    CY2_TMEOTHR = ""
    CY2_RTME = ""
    CY3_TMEGYN = ""
    CY3_TMENGYN = ""
    CY3_TMEOTHR = ""
    CY3_RTME = ""
    CYTO1 = ""
    CYTO2 = ""
    CYTO3 = ""
    PATH1 = ""
    PATH2 = ""
    PATH3 = ""
    PATH4 = ""
    PATH5 = ""
    CYTO1_SL = 0
    CYTO2_SL = 0
    CYTO3_SL = 0
    PATH1_SL = 0
    PATH2_SL = 0
    PATH3_SL = 0
    PATH4_SL = 0
    PATH5_SL = 0
    CY1_SL_HR = 0
    CY2_SL_HR = 0
    CY3_SL_HR = 0
    CY1_SL_DAY = 0
    CY2_SL_DAY = 0
    CY3_SL_DAY = 0
    CY1_HR_DAY = ""
    CY2_HR_DAY = ""
    CY3_HR_DAY = ""
    CY1_CASES = 0
    CY2_CASES = 0
    CY3_CASES = 0
    CY1_DAYS = 0
    CY2_DAYS = 0
    CY3_DAYS = 0
    CY1_GYNCS = 0
    CY2_GYNCS = 0
    CY3_GYNCS = 0
    CY1_GYNSL = 0
    CY2_GYNSL = 0
    CY3_GYNSL = 0
    CY1_NGYNCS = 0
    CY2_NGYNCS = 0
    CY3_NGYNCS = 0
    CY1_NGYNSL = 0
    CY2_NGYNSL = 0
    CY3_NGYNSL = 0
    CY1_OTHRCS = 0
    CY2_OTHRCS = 0
    CY3_OTHRCS = 0
    CY1_OTHRSL = 0
    CY2_OTHRSL = 0
    CY3_OTHRSL = 0
    CY1_NDAYS = 0
    CY2_NDAYS = 0
    CY3_NDAYS = 0
    PATH1_DAYS = 0
    PATH2_DAYS = 0
    PATH3_DAYS = 0
    PATH4_DAYS = 0
    PATH5_DAYS = 0
    PATH1_TIME = ""
    PATH2_TIME = ""
    PATH3_TIME = ""
    PATH4_TIME = ""
    PATH5_TIME = ""
    PATH1_CASES = 0
    PATH2_CASES = 0
    PATH3_CASES = 0
    PATH4_CASES = 0
    PATH5_CASES = 0
    PATH1_RESCRN = 0
    PATH2_RESCRN = 0
    PATH3_RESCRN = 0
    PATH4_RESCRN = 0
    PATH5_RESCRN = 0
    PATH1_SPOTCK = 0
    PATH2_SPOTCK = 0
    PATH3_SPOTCK = 0
    PATH4_SPOTCK = 0
    PATH5_SPOTCK = 0
    :form.refresh_fields()

    start = ui_get_date("Enter Start-Date","Enter Date-",dtoc(START_DTE))
    finish = ui_get_date("Enter Last-Date","Enter Date-",dtoc(END_DTE))
    date1 = ctod(start)
    date2 = ctod(finish)
    START_DTE = ctod(start)
    END_DTE = ctod(finish)
    form.refresh_fields()

    on error goto invalid_year
    IF year(START_DTE) " year(date()) .and. year(END_DTE) " year(date()) THEN
    IF END_DTE - START_DTE "95 THEN
    result = ui_msg_box("ATTENTION !!","You have entered a date span that may require 1-2 minutes to calculate. Do you still want to continue?",49)
    IF result = 2 THEN
    START_DTE = {}
    END_DTE = {}
    form.refresh_fields()
    End
    END IF
    END IF
    dbe = table.open(a_db_current_path+ltrim(str(year(START_DTE)))+"\pap_"+ltrim(str(year(START_DTE))))
    dbe.index_primary_put("path_dte")
    goto start
    ELSE
    dbe = table.open(a_db_current_path+"pap_rslt.dbf")
    dbe.index_primary_put("path_dte")
    goto start
    END IF

    Start:

    data = a_db_current_path+"info.dbf"
    dbg = table.open(data)
    dbg.index_primary_put("eff_date")
    dbg.fetch_first()
    While .not. dbg.fetch_eof()
    If START_DTE "= dbg.eff_date then
    path1 = dbg.path1
    path2 = dbg.path2
    path3 = dbg.path3
    path4 = dbg.path4
    path5 = dbg.path5
    cyto1 = dbg.cyto1
    cyto2 = dbg.cyto2
    cyto3 = dbg.cyto3
    Exit While
    End if
    dbg.fetch_next()
    End While
    dbg.close()
    parentform.refresh_fields()
    x=3
    tbl = table.current()
    tbl.fetch_first()
    IF tbl.fetch_find(START_DTE) " 0 THEN
    IF month(START_DTE)"" month(stats-"date) .and. year(START_DTE)"" year(stats-"date) THEN
    tbl.fetch_last()
    ui_msg_box("ATTENTION !!","You have entered a date span that is beyond what statistics for cytologists exists. Please enter a date earlier than -"+dtoc(stats-"date)+"- .")
    End
    END IF
    END IF
    prev_cyto = ""
    WHILE .not. tbl.fetch_eof()
    IF stats-"date "= START_DTE .and. stats-"date "= END_DTE THEN
    SELECT
    CASE TEC(1) "" stats-"cyto .and. TEC(1)=""
    TEC(1) = stats-"cyto
    CASE TEC(1) "" stats-"cyto .and. TEC(2)=""
    TEC(2) = stats-"cyto
    CASE TEC(1) "" stats-"cyto .and. TEC(2) "" stats-"cyto .and. TEC(3)=""
    TEC(3) = stats-"cyto
    exit while
    END SELECT
    ELSE IF stats-"date " START_DTE THEN
    exit while
    END IF
    tbl.fetch_next()
    END WHILE

    TECH1 = TEC(1)
    TECH2 = TEC(2)
    TECH3 = TEC(3)
    mins1 = 0
    mins2 = 0
    mins3 = 0
    path1time = 0
    path2time = 0
    path3time = 0
    path4time = 0
    path5time = 0
    prev_date = {}
    prev_path = ""
    prev_rec = 0
    FOR x = 1 TO 3
    tmegyn(x) = 0
    tmergyn(x)= 0
    tmengyn(x)= 0
    tmeothr(x)= 0
    NEXT x

    tbl.fetch_first()
    tbl.fetch_find(START_DTE)
    WHILE .not. tbl.fetch_eof()
    IF stats-"date "= START_DTE .and. stats-"date "= END_DTE THEN
    IF stats-"date "" prev_date THEN
    ttl_days = ttl_days + 1
    END IF
    SELECT
    CASE stats-"cyto = ""
    ui_msg_box("ATTENTION !!!","Data collection will stop here! You have data recorded with no cyto initials? Please look at this date - "+dtoc(stats-"date)+" and enter a cytologist(s) for the date specified.")
    End
    CASE stats-"cyto = tech1
    cy1_cases = stats-"ttl_cases + cy1_cases
    cyto1_sl = stats-"ttl_slides + cyto1_sl
    cy1_days = cy1_days + 1
    cy1_gynsl = stats-"gyn_slides + stats-"r_gyn_sl + cy1_gynsl
    cy1_ngynsl = stats-"non_slides + cy1_ngynsl
    cy1_gyncs = stats-"gyn_cases + stats-"r_gyn_cs + cy1_gyncs
    cy1_ngyncs = stats-"non_cases + cy1_ngyncs
    cy1_rscrnsl = stats-"r_gyn_sl + cy1_rscrnsl
    cy1_rscrncs = stats-"r_gyn_cs + cy1_rscrncs
    cy1_othrsl = stats-"othr_slide + cy1_othrsl
    cy1_othrcs = stats-"othr_cases + cy1_othrcs
    tmegyn(1) = stats-"gyn_time + tmegyn(1)
    tmergyn(1)= stats-"r_gyn_time + tmergyn(1)
    tmengyn(1)= stats-"non_time + tmengyn(1)
    tmeothr(1)= stats-"othr_time + tmeothr(1)
    mins1 = stats-"ttl_time + mins1
    IF stats-"non_slides " 0 THEN
    cy1_ndays = cy1_ndays + 1
    END IF
    CASE stats-"cyto = tech2
    cy2_cases = stats-"ttl_cases + cy2_cases
    cyto2_sl = stats-"ttl_slides + cyto2_sl
    cy2_days = cy2_days + 1
    cy2_gynsl = stats-"gyn_slides + stats-"r_gyn_sl + cy2_gynsl
    cy2_ngynsl = stats-"non_slides + cy2_ngynsl
    cy2_gyncs = stats-"gyn_cases + stats-"r_gyn_cs + cy2_gyncs
    cy2_ngyncs = stats-"non_cases + cy2_ngyncs
    cy2_rscrnsl = stats-"r_gyn_sl + cy2_rscrnsl
    cy2_rscrncs = stats-"r_gyn_cs + cy2_rscrncs
    cy2_othrsl = stats-"othr_slide + cy2_othrsl
    cy2_othrcs = stats-"othr_cases + cy2_othrcs
    tmegyn(2) = stats-"gyn_time + tmegyn(2)
    tmergyn(2)= stats-"r_gyn_time + tmergyn(2)
    tmengyn(2)= stats-"non_time + tmengyn(2)
    tmeothr(2)= stats-"othr_time + tmeothr(2)
    mins2 = stats-"ttl_time + mins2
    IF stats-"non_slides " 0 THEN
    cy2_ndays = cy2_ndays + 1
    END IF
    CASE stats-"cyto = tech3
    cy3_cases = stats-"ttl_cases + cy3_cases
    cyto3_sl = stats-"ttl_slides + cyto3_sl
    cy3_days = cy3_days + 1
    cy3_gynsl = stats-"gyn_slides + stats-"r_gyn_sl + cy3_gynsl
    cy3_ngynsl = stats-"non_slides + cy3_ngynsl
    cy3_gyncs = stats-"gyn_cases + stats-"r_gyn_cs + cy3_gyncs
    cy3_ngyncs = stats-"non_cases + cy3_ngyncs
    cy3_rscrnsl = stats-"r_gyn_sl + cy3_rscrnsl
    cy3_rscrncs = stats-"r_gyn_cs + cy3_rscrncs
    cy3_othrsl = stats-"othr_slide + cy3_othrsl
    cy3_othrcs = stats-"othr_cases + cy3_othrcs
    tmegyn(3) = stats-"gyn_time + tmegyn(3)
    tmergyn(3)= stats-"r_gyn_time + tmergyn(3)
    tmengyn(3)= stats-"non_time + tmengyn(3)
    tmeothr(3)= stats-"othr_time + tmeothr(3)
    mins3 = stats-"ttl_time + mins3
    IF stats-"non_slides " 0 THEN
    cy3_ndays = cy3_ndays + 1
    END IF
    END SELECT
    '---------------------- Check to see if path has been entered twice?
    IF stats-"path = prev_path .and. stats-"date = prev_date THEN
    choice = ui_msg_box("IMPORTANT QUESTION -?","You have the same pathologist for the same date OR no pathologist at all? - data may not be accurate? Do you want to continue?",20)
    IF choice = 7 THEN
    ui_msg_box("IMPORTANT -!","You must go to the -DATA INPUT SCREEN- and correct this problem before you collect data on this time period! Look at record # -"+Ltrim(str(recno()))+" with a date of: "+dtoc(stats-"date)+"- for NO pathologist or, DUP pathologists?")
    End
    END IF
    END IF
    '---------------------- Get Path's days & time in seconds
    SELECT
    CASE stats-"path = path1 .and. path1 "" ""
    path1_days = path1_days + 1
    path1time = stats-"path_time + path1time
    CASE stats-"path = path2 .and. path2 "" ""
    path2_days = path2_days + 1
    path2time = stats-"path_time + path2time
    CASE stats-"path = path3 .and. path3 "" ""
    path3_days = path3_days + 1
    path3time = stats-"path_time + path3time
    CASE stats-"path = path4 .and. path4 "" ""
    path4_days = path4_days + 1
    path4time = stats-"path_time + path4time
    CASE stats-"path = path5 .and. path5 "" ""
    path5_days = path5_days + 1
    path5time = stats-"path_time + path5time
    END SELECT
    '---------------------- Get Path's screening stats from Pappi & slides/cases

    IF stats-"path_date "" {} THEN
    dbe.fetch_first()
    dbe.fetch_find(stats-"path_date)
    WHILE .not. dbe.fetch_eof()
    IF dbe.path_init = stats-"path .and. dbe.path_date = stats-"path_date THEN
    SELECT
    CASE dbe.path_init = path1 .and. dbe.path_init "" ""
    IF dbe.p_re_scrn = .T. THEN
    path1_rescrn = path1_rescrn + 1
    END IF
    IF dbe.spot_ck = .T. THEN
    path1_spotck = path1_spotck + 1
    END IF
    path1_cases = path1_cases + 1
    path1_sl = path1_sl + dbe.no_slides
    CASE dbe.path_init = path2 .and. dbe.path_init "" ""
    IF dbe.p_re_scrn = .T. THEN
    path2_rescrn = path2_rescrn + 1
    END IF
    IF dbe.spot_ck = .T. THEN
    path2_spotck = path2_spotck + 1
    END IF
    path2_cases = path2_cases + 1
    path2_sl = path2_sl + dbe.no_slides
    CASE dbe.path_init = path3 .and. dbe.path_init "" ""
    IF dbe.p_re_scrn = .T. THEN
    path3_rescrn = path3_rescrn + 1
    END IF
    IF dbe.spot_ck = .T. THEN
    path3_spotck = path3_spotck + 1
    END IF
    path3_cases = path3_cases + 1
    path3_sl = path3_sl + dbe.no_slides
    CASE dbe.path_init = path4 .and. dbe.path_init "" ""
    IF dbe.p_re_scrn = .T. THEN
    path4_rescrn = path4_rescrn + 1
    END IF
    IF dbe.spot_ck = .T. THEN
    path4_spotck = path4_spotck + 1
    END IF
    path4_cases = path4_cases + 1
    path4_sl = path4_sl + dbe.no_slides
    CASE dbe.path_init = path5 .and. dbe.path_init "" ""
    IF dbe.p_re_scrn = .T. THEN
    path5_rescrn = path5_rescrn + 1
    END IF
    IF dbe.spot_ck = .T. THEN
    path5_spotck = path5_spotck + 1
    END IF
    path5_cases = path5_cases + 1
    path5_sl = path5_sl + dbe.no_slides
    END SELECT
    ELSE IF dbe.path_date " stats-"date THEN
    Exit While
    END IF
    dbe.fetch_next()
    END WHILE
    END IF

    prev_date = stats-"date
    prev_path = stats-"path
    prev_rec = recno()
    ELSE IF stats-"date " START_DTE .and. stats-"date "" {} THEN
    exit while
    END IF
    tbl.fetch_next()
    END WHILE
    dbe.close()

    ttl_cy1_tme = totime(toseconds(ltrim(str((mins1*60)))),1,0)
    ttl_cy2_tme = totime(toseconds(ltrim(str((mins2*60)))),1,0)
    cy1_tmegyn = totime(toseconds(ltrim(str((tmegyn(1)*60)))),1,0)
    cy1_rtme = totime(toseconds(ltrim(str((tmergyn(1)*60)))),1,0)
    cy1_tmengyn = totime(toseconds(ltrim(str((tmengyn(1)*60)))),1,0)
    cy1_tmeothr = totime(toseconds(ltrim(str((tmeothr(1)*60)))),1,0)
    cy2_tmegyn = totime(toseconds(ltrim(str((tmegyn(2)*60)))),1,0)
    cy2_rtme = totime(toseconds(ltrim(str((tmergyn(2)*60)))),1,0)
    cy2_tmengyn = totime(toseconds(ltrim(str((tmengyn(2)*60)))),1,0)
    cy2_tmeothr = totime(toseconds(ltrim(str((tmeothr(2)*60)))),1,0)
    cy1_sl_hr = cyto1_sl/(mins1/60)
    cy1_sl_day = cyto1_sl/cy1_days
    cy1_hr_day = totime(toseconds(ltrim(str((mins1*60)/cy1_days))),1,0)
    cy2_sl_hr = cyto2_sl/(mins2/60)
    cy2_sl_day = cyto2_sl/cy2_days
    cy2_hr_day = totime(toseconds(ltrim(str((mins2*60)/cy2_days))),1,0)

    IF cyto3 "" "" THEN
    ttl_cy3_tme = totime(toseconds(ltrim(str((mins3*60)))),1,0)
    cy3_tmegyn = totime(toseconds(ltrim(str((tmegyn(3)*60)))),1,0)
    cy3_rtme = totime(toseconds(ltrim(str((tmergyn(3)*60)))),1,0)
    cy3_tmengyn = totime(toseconds(ltrim(str((tmengyn(3)*60)))),1,0)
    cy3_tmeothr = totime(toseconds(ltrim(str((tmeothr(3)*60)))),1,0)
    cy3_sl_hr = cyto3_sl/(mins3/60)
    cy3_sl_day = cyto3_sl/cy3_days
    cy3_hr_day = totime(toseconds(ltrim(str((mins3*60)/cy3_days))),1,0)
    END IF

    path1_time = totime(toseconds(ltrim(str(path1time*60))),1,0)
    path2_time = totime(toseconds(ltrim(str(path2time*60))),1,0)
    path3_time = totime(toseconds(ltrim(str(path3time*60))),1,0)
    path4_time = totime(toseconds(ltrim(str(path4time*60))),1,0)
    path5_time = totime(toseconds(ltrim(str(path5time*60))),1,0)
    parentform.refresh_fields()
    Report.print("Stats Report")
    End

    invalid_year:
    tbl.fetch_first()
    ui_msg_box("ATTENTION !!!","You have entered a date span that will not conform with your cytologists statistical records. Please enter a date span starting with - "+dtoc(stats-"date)+" -.")
    err = error_code_get()
    msg = error_text_get(err)
    ui_msg_box("Code explanation",msg)
    end


    I hope maybe it's just something simple here and I can't see it?

    Thanks William for any help - and if you need anything else, please let me know.

    Mac

    Leave a comment:


  • L. McIntosh
    Guest replied
    RE: form variables not printing?

    William,

    Thanks William, I didn't know about that feature. I started using A5V1 back in 1995-1996 and am just upgrading to A5V5.

    Question William?
    Will the values of the variables xfr ok to a report in lieu of a form layout. I've always thought of reports being used when printing out filtered field values of a DB. The report I'm creating here actually has no field values involved for printing results. The script takes values of the fields and calculates results to be printed as a whole. Kind of like a survey report if you know what I mean?

    Anyways, I will check out your idea and see what happens :)

    Thanks,

    Mac

    Leave a comment:


  • whanigsberg
    replied
    RE: form variables not printing?

    There is no problem with A5 but I can't know what is happening in your application without seeing it.

    So you should post a copy with instructions on how to replicate the problem.

    Having said this, I offer the general (and perennial) advice to not print forms. They are for screen display.

    Create a report which looks like the screen you want to print. This is not difficult. If you open the report editor and look on the menu you will find an item ("report") which allows you to insert an object such as your form into the report design.

    Bill

    Leave a comment:


  • L. McIntosh
    Guest started a topic form variables not printing?

    form variables not printing?

    Hello again Forum,

    Say, I've got a little problem with global variables. I have a form with multiple variables(field variables) and I can't get the values of about 5 to xfr to form? All the other values xfr just fine? Everyone of the variables is set 'global' on the form and within the script. The script is fired by a button event 'onpush' on the form. I've tried changing the refresh method from 'form.refresh_fields() to 'parentform.refresh_fields' but still to no avail. The initial display of the form shows all the values just fine, but when you print or preview the form before printing, these five variables are not showing any values? So, when you just go ahead and initially print the form, it does not print their values either? I've even closed out totally and restarted my app, but still makes no difference?

    Am I missing something simple here or have we got a problem with A5V5?

    Any help truly appreciated - Thanks

    Mac

    P.S.
    I did do a search on the forum and found nothing pertaining to this :-) .
Working...
X