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

Dimming form pointers as shared

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

  • Dimming form pointers as shared

    Am trying to grasp the scope of Shared variables as they relate to a form window, which I am assuming is the same as the form that contains the field objects.
    When I call a form to update a record from an embedded browse, could I not establish a shared pointer to the browse form like this?

    Code:
    dim SHARED myBrowseForm as p
    dim SHARED myUpdateForm as p
    myBrowseForm = topparent.this
    myUpdateForm = form.zoom_to_record("Update_form","existing")
    Now on my Save button in the update form, can I not reference objects on the browse form as this?

    Code:
    dim SHARED myBrowseForm as p
    myBrowseForm:count_field.value = parentform:count.value
    This doesn't seem to work, but can't understand why. Would appreciate any enlightenment.
    Thanks.
    Ernie

  • #2
    Re: Dimming form pointers as shared

    Hi Ernie,

    Originally posted by enstorms View Post
    Am trying to grasp the scope of Shared variables as they relate to a form window, which I am assuming is the same as the form that contains the field objects.
    When I call a form to update a record from an embedded browse, could I not establish a shared pointer to the browse form like this?

    Code:
    dim SHARED myBrowseForm as p
    dim SHARED myUpdateForm as p
    myBrowseForm = topparent.this
    myUpdateForm = form.zoom_to_record("Update_form","existing")
    Now on my Save button in the update form, can I not reference objects on the browse form as this?

    Code:
    dim SHARED myBrowseForm as p
    myBrowseForm:count_field.value = parentform:count.value
    This doesn't seem to work, but can't understand why. Would appreciate any enlightenment.
    Each form (actually pretty much any A5 window that is not an XDialog or dialog) operates in it's own session (or also referred to as thread) and has its own session variable space (which is synonymous with shared). Thus creating it in one form as shared does not mean it is shared with the other form. It means that it is shared with all code running in that form's session.

    Global variables would be accessible to all forms. It is also possible to get the shared or local variable space pointer from another thread via methods available from the form pointers and read or write the values in those variable spaces.
    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


    • #3
      Re: Dimming form pointers as shared

      Ira,
      Really appreciate you getting back to me on this. I mis-interpreted the attached diagram. Where it show form1 and browse1 in the same session/thread, I assumed that was what I was doing in calling a form from a browse. Didn't read the fine print where is says change a layout using f8. Never used that.
      Yes, I am familiar with the functions available for getting a pointer to another open window, just thought I'd try a shortcut. In re-reading some of your response, you mention xdialog or dialog. I am assuming opening a different form as dialog wouldn't work in this case either????
      Thanks again for your explanations.
      Ernie

      Comment


      • #4
        Re: Dimming form pointers as shared

        Hi Ernie,

        Originally posted by enstorms View Post
        In re-reading some of your response, you mention xdialog or dialog. I am assuming opening a different form as dialog wouldn't work in this case either????
        A form opened as a dialog is still a form running in it's own session (I believe). It may be only if it is modeless. Modal operation may effectively share the current session. Best was is to test it to find out and report back for others. In general, I don't recommend using forms as dialogs, but there may be some cases where they have advantages (although they are bound to a table - a definite drawback for dialogs).

        Windows running their own sessions may be all MDI windows (Ones that have Minimize, Maximize/Restore and close boxes in the title bar typically), or possibly others. As far as I know, all alpha internal dialogs are either compiled code or XDialogs, and they don't run in their own sessions.
        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


        • #5
          Re: Dimming form pointers as shared

          Evidently, modal windows open in own session. Tried opening the update form as "dialog" and shared pointer not found.
          Thanks again, Ira.
          Ernie

          Comment


          • #6
            Re: Dimming form pointers as shared

            opening another form as a dialog, where the form is based on a table

            Code:
            dim f as p 'not really needed but put here anyway
            dim global recnum as n 'not shared
            recnum=0
            f=form.view("customers_dialog","dialog")
            'at that forms continue/close event, set recnum
            'something like = recnum=table.current().recno()
            f.close() 'must close if opened as dialog
            'do something with recnum
            if recnum > 0
                 parentform.index_set("") 'recordnumber order
                 parentform.find(recnum)
                 recnum=0
            end if
            Cole Custom Programming - Terrell, Texas
            972 524 8714
            [email protected]

            ____________________
            "A young man who is not liberal has no heart, but an old man who is not conservative has no mind." GB Shaw

            Comment

            Working...
            X