Alpha Video Training
Results 1 to 6 of 6

Thread: new records for no reason

  1. #1
    Guest
    Real Name
    Mark Pearson
    Join Date
    May 2009
    Location
    Townsville, Queensland, Australia
    Posts
    223

    Default new records for no reason

    I have a table that I have repeatedly deleted the records and compacted, but every time I open a view based on that table I get three new records the first time only. I cannot see any reason. The form view is a simply view with a browse built on a table based on the form. The browse view is read only so it cannot create a new record. When you click the button to go to the view it is set to do nothing

    When I zap and compact I have confirmed the table has no records. The Field rules only has one field to auto increment. Can any one please shed some light on this?

  2. #2
    Guest
    Real Name
    Mark Pearson
    Join Date
    May 2009
    Location
    Townsville, Queensland, Australia
    Posts
    223

    Default Re: new records for no reason

    I think I found the issue. While the browse view was read only, the form had no restrictions. Although I was not loading the view with any special requirements (like create new) it just seemed to always create three new records the first time after a delete and compact. I ticked all the restrictions to the form and the problem has gone away. I can see no rationale behind this but it has worked so one must be happy.

  3. #3
    Member
    Real Name
    Geoff Meredith
    Join Date
    Aug 2006
    Posts
    637

    Default Re: new records for no reason

    Mark - I have seen this as well.

  4. #4
    "Certified" Alphaholic
    Real Name
    Tom Cone Jr
    Join Date
    Apr 2000
    Location
    Florida
    Posts
    23,310

    Default Re: new records for no reason

    Mark, the lingo is a bit different in Alpha speak. One can "pack" a table. One can "compact" a database. One cannot "compact" a table.

    When you open a form when your table is empty, Alpha automatically goes into "ENTER" mode. The form will then automatically "save" the pending new record according to Alpha's built in default behaviors. When you set the form level restrictions you are changing the default behaviors for the form.

    Because the form is automatically "bound" to the underlying table(s) , each time you open a form you open a new instance of the table in memory. As a result I've found it best to "pack" tables when their related forms are closed.

    Also, be aware that packing requires exclusive access to the table so you should plan on trapping "can't open" table errors when running in a multi-user environament. If anyone else has a form open that is supported by your table your script will fail. The reverse is also true. If someone tries to open a form while your pack table script is running they will have trouble.

    For these reasons many would place "packing" into a collection of "maintenance" routines that get run only when the administrator has control of the environment.

  5. #5
    Guest
    Real Name
    Mark Pearson
    Join Date
    May 2009
    Location
    Townsville, Queensland, Australia
    Posts
    223

    Default Thanks

    This problem all started a few threads back. Initially it related to being able to opening a maximise form and then subequent forms as modlal. I couldn't get the modless report menu unless all forms were modless. Thanks to to this forum I tweeked to get a similar look and get the form menu properly. In the first instance I also used an xdialog but had to do away with it as it was modal too. So in order to get the effect I used a form in modless to simulate what I was doing in one of my steps with the xdialog. Hence this thread on record creation problem. If there were no records I really did not want one created at this point. Now that I have been able to tweek the views to get my effect, I have actually been able to go back to the xdialog approach.

    Just want to thank all the help given as I am one step closer to my resolve. Proves the woth forum

  6. #6
    "Certified" Alphaholic
    Real Name
    Mike Christensen
    Join Date
    Nov 2005
    Location
    Michigan U.P.
    Posts
    5,937

    Default Re: new records for no reason

    Just a FYI--
    I also used an xdialog but had to do away with it as it was modal too.
    You can create a modeless xdialog as well.
    Mike
    __________________________________________
    It is only when we forget all our learning that we begin to know.
    It's not what you look at that matters, it's what you see.
    Henry David Thoreau
    __________________________________________




Similar Threads

  1. Alpha5 V9 Stops Without Reason
    By jrtarrago in forum Application Server Version 9 - Web/Browser Applications
    Replies: 0
    Last Post: 10-18-2008, 03:33 PM
  2. alpha hangs, no obvious reason
    By richard2007 in forum Alpha Five Version 9 - Desktop Applications
    Replies: 9
    Last Post: 10-14-2008, 05:49 AM
  3. Replies: 1
    Last Post: 04-16-2008, 09:20 AM
  4. Text Property Tools - Stops working for no reason
    By Ant-Tech in forum Alpha Five Version 8
    Replies: 4
    Last Post: 06-02-2007, 03:03 PM
  5. ODBC error mssg pl confirm reason
    By Dave Wilson in forum Alpha Five Version 6
    Replies: 0
    Last Post: 09-16-2004, 05:09 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
  •