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

doubleRow Click

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

    doubleRow Click

    I am dblclicking on a row.This defined by the following;
    Open a form- Records that match a value in a control on the current form (systemID)
    This opens a form, to the correct record.
    However,once I view the form it only allows me to view the selected record. I cannot remove the filter. ( show all).
    How do I fix this?

    #2
    RE: doubleRow Click

    Jeff, I tried what I think you are doing (using form.view), and got the form I wanted, complete with the standard tool bar. Then I clicked on the Show All button, and it showed all the records.

    How are you doing this? Maybe posting your script will show us what might be wrong.

    Comment


      #3
      RE: doubleRow Click

      Hi Jeff

      I'm not too sure about this but I think you will need to insert SOME of the following into the script that was created with Action scripting. Probably at the query.filter point this is an extract of my script that goes from a browse and opens a form called "Jobs" in a table called Schedule. It is the last 5 lines that realy make it work. Let us know how you get on.

      Dim fm as P
      tbl=table.current()
      query.description="Select Record Number"
      query.filter="record_number=var->recno"
      fm=form.load("Jobs")
      fm:tables:Schedule.query_create()
      fm.resynch()
      fm.show()
      fm.resynch()
      fm.activate()
      fm.show_all()

      Keith Hubert
      London.
      Regards
      Keith Hubert
      Alpha Guild Member
      London.
      KHDB Management Systems
      Skype = keith.hubert


      For your day-to-day Needs, you Need an Alpha Database!

      Comment


        #4
        RE: doubleRow Click

        OK Jeff

        Here is the complete script generated by the Genie and then converted to Inline XBasic and with my bit added to the bottom. It works, I tested it. all you will need to change is the VarP_formname on the last 5 lines.

        Keith Hubert
        London.

        'Inline-Xbasic. Converted from: Open a Form or Browse layout, displaying all, or selected records in the layout.
        'Open a Form or Browse layout, displaying all, or selected records in the layout.
        'Check to see if you are running the script from within a Form
        dim flag_error as l
        flag_error = .f.
        if is_object(topparent.this) then
        p = topparent.this
        if p.class() = "Form" then
        DELETE Parameter1
        'Set the Parameter variable to the object's .value property
        Parameter1 = eval("P:BROWSE1:Record_number.value")
        else 'Not in a Form. This is an error condition.
        flag_error = .t.
        end if
        else
        flag_error = .t.
        end if

        if flag_error then
        ui_msg_box("Error","You can only run this script from within a Form",UI_STOP_SYMBOL)
        end
        end if


        filter = "Record_number = [varN->parameter1]"
        query.filter = replace_parameters(filter,local_variables())
        query.order = ""





        'Open the layout_type showing just the records that satisfy the filter
        DIM Shared varP_Jobs as P
        DIM layout_name as c
        layout_name = "Jobs"


        dim tempP as p
        'Get pointer to existing window. In case layout_name is qualified with a dictionary name, extract up to first @. In case formname has spaces, normalize it
        tempP=obj(":"+object_name_normalize(word(layout_name,1,"@")))
        'Test if pointer is valid
        if is_object(tempP) then
        'Test if pointer refers to a form or browse
        if tempP.class() = "form" .or. tempP.class() = "browse" then
        'Apply the query to the form or browse as the Base query. (this means that
        'the user cannot turn the query off, only add to the query)
        tempP.BaseQueryRun(query.filter,query.order)
        'then activate the already open window
        tempP.activate()
        else
        'Window is not already open, so open it
        varP_Jobs = :Form.viewqueried(layout_name,query.filter, query.order )

        end if
        else
        varP_Jobs = :Form.viewqueried(layout_name,query.filter, query.order )

        end if

        varP_Jobs.resynch()
        varP_Jobs.show()
        varP_Jobs.resynch()
        varP_Jobs.activate()
        varP_Jobs.show_all()
        Regards
        Keith Hubert
        Alpha Guild Member
        London.
        KHDB Management Systems
        Skype = keith.hubert


        For your day-to-day Needs, you Need an Alpha Database!

        Comment


          #5
          RE: doubleRow Click

          I am doing this with action scripting.
          It works fine except I can't get the filter to release.

          Comment


            #6
            RE: doubleRow Click

            I will try it.
            Do I assume that the last 5 lines releases the query and shows all the records?

            Doe sthe Var_P get changed to my form name?
            Thanks for the help.

            Comment


              #7
              RE: doubleRow Click

              Here's what I ended up with.It only will allow me to view the one record that it found with the query.It will also allow me to add a new record.
              However, It still does not allow mw to view all.
              Any suggestions.
              'Date Created: 10-Feb-2003 10:03:32 PM
              'Last Updated: 10-Feb-2003 10:07:36 PM
              'Created By :
              'Updated By :
              'Open a Form or Browse layout, displaying all, or selected records in the layout.
              'Check to see if you are running the script from within a Form
              dim flag_error as l
              flag_error = .f.
              if is_object(topparent.this) then
              p = topparent.this
              if p.class() = "Form" then
              DELETE Parameter1
              'Set the Parameter variable to the object's .value property
              Parameter1 = eval("P:BROWSE2:System_id_order_number.value")
              else 'Not in a Form. This is an error condition.
              flag_error = .t.
              end if
              else
              flag_error = .t.
              end if

              if flag_error then
              ui_msg_box("Error","You can only run this script from within a Form",UI_STOP_SYMBOL)
              end
              end if


              filter = "System_id = [varC->parameter1]"
              query.filter = replace_parameters(filter,local_variables())
              query.order = ""


              'Open the layout_type showing just the records that satisfy the filter
              DIM Shared varP_order_entry as P
              DIM layout_name as c
              layout_name = "order entry"
              varP_order entry = :Form.viewqueried(layout_name,query.filter, query.order )
              varP_order entry.resynch()
              varP_order entry.show()
              varP_order entry.resynch()
              varP_order entry.activate()
              varP_order entry.show_all()

              Comment


                #8
                RE: doubleRow Click

                Keith,
                I was wondering if you could respond to my answer.
                Thanks.

                Comment


                  #9
                  RE: doubleRow Click

                  Hi Jeff,

                  I will have to look at your script when I get home this evening 8.pm which is 5.pm est. Sorry to make you wait, but all my alpha stuff is on my machine at home.

                  Keith Hubert
                  London.
                  Regards
                  Keith Hubert
                  Alpha Guild Member
                  London.
                  KHDB Management Systems
                  Skype = keith.hubert


                  For your day-to-day Needs, you Need an Alpha Database!

                  Comment


                    #10
                    RE: doubleRow Click

                    Hi Jeff.

                    Home at last. Time now 7.45 pm.
                    Here is the actual script that I have on a browse that takes me to a form OnDoubleClick. As you can see it stops and asks for confirmation that it is going to the correct record number and it can cancel the event if the user chooses to do so. I do hope this helps you now, please let me know how you get on.

                    Keith Hubert
                    London.

                    'Date Created: 09-Feb-2003 08:01:34 PM
                    'Last Updated: 09-Feb-2003 08:01:34 PM
                    'Created By : Keith Hubert
                    'Updated By : Keith Hubert
                    ''XBasic
                    dim fm as p
                    dim recno as n
                    dim rechar as c
                    dim response as n
                    recno=this:record_number.value
                    response=ui_msg_box("Confirm Record Number", "RECORD NUMBER "+str(recno)+chr(13)+"Press OK to Continue or"+chr(13)+"Cancel to Cancel Action",289)

                    if response=2 then ui_msg_box("Warning","Action Aborted",16)
                    END
                    end if
                    tbl=table.current()
                    query.description="Select Record Number"
                    query.filter="record_number=var->recno"
                    fm=form.load("Jobs")
                    fm:tables:Schedule.query_create()
                    fm.resynch()
                    'fm.restrict_change=.T.
                    fm.show()
                    fm.resynch()
                    fm.activate()
                    fm.show_all()
                    END
                    Regards
                    Keith Hubert
                    Alpha Guild Member
                    London.
                    KHDB Management Systems
                    Skype = keith.hubert


                    For your day-to-day Needs, you Need an Alpha Database!

                    Comment


                      #11
                      RE: doubleRow Click

                      I Figured out the problem.
                      I usually start my app. on the order entry screen. I then also open my customer database. This form also gives me an embedded browse with the Purchase orders written for that customer.
                      When I double click on the browse I have it set to open up the order entry form with that customer -Po# combination.
                      What I didn't realize is- this opens up the order entry form a second time wit hthe chosen PO#.
                      When I close the 2nd instance, I am back to the first with no problems. It's not exactly what I want, but I will have to work on this to figure out a better solution.
                      Thanks for the help.

                      Comment


                        #12
                        RE: doubleRow Click

                        Purhaps you could "activate" the order entry form to the current record rather than "open" the form.

                        Never tried this but it may be possible.

                        Just a thought
                        Marc King
                        A5solutions

                        Comment


                          #13
                          RE: doubleRow Click

                          Hello Jeff,

                          Keiths script should work for you just fine. However, another approach would be to just 'goto' the desired record rather than query the table. Taking off from Keith's script at this point:

                          query.filter="record_number=var->recno"
                          fm=form.load("Jobs")
                          ' I'm starting new routine here
                          t = table.get("schedule")
                          t.index_primary_put()
                          t.fetch_goto(var->recno)
                          fm.resynch()
                          fm.show()
                          fm.activate()

                          This of course puts and leaves the table in record order number. If you wanted a specific index, you would just add another line activating the desired index.

                          Good luck,
                          Jim

                          Comment


                            #14
                            RE: doubleRow Click

                            Jeff,

                            Just posted this and realized I don't know what context you are running this from. If you are calling this routine form a parent form but opening another form, table.get() will refer to the context of the parent form. So you'd probably have to use the syntax:

                            t = fm:tables:schedule.this

                            I've got to mention that I believe that this is good solid Xbasic syntax that I've used for years. But I have had trouble with returning a table pointer in this manner with version 5. It may have been a particular build, or my system may have been unstable at the time. But I was able to repeat it and I sent it up to Alpha for investigation.

                            Good luck,
                            Jim

                            Comment


                              #15
                              RE: doubleRow Click

                              Jim,

                              Thanks for endorsing my script, the final part which enabled the form to move to next record and back to previous record was given to me by Tom Holt.
                              I am surprised that you are having a problem now with V5 as like you I had the script built in V4.5 and has continued well with the upgrade. However, I shall monitor its use.

                              Keith Hubert
                              London.
                              Regards
                              Keith Hubert
                              Alpha Guild Member
                              London.
                              KHDB Management Systems
                              Skype = keith.hubert


                              For your day-to-day Needs, you Need an Alpha Database!

                              Comment

                              Working...
                              X