Welcome to SPN

Register and Join the most happening forum of Sikh community & intellectuals from around the world.

Sign Up Now!

Lock data entry in Form

Discussion in 'Information Technology' started by Jorg, Jul 28, 2006.

  1. Jorg

    Jorg
    Expand Collapse
    Guest

    I have a combo box - Status- with active-closed. when set to "closed" i want
    to lock the data entry for this record.
     
  2. Loading...

    Similar Threads Forum Date
    Debate With Sarbjeet Singh Dhunda At Turlock (California) Gurdwara, April 2015 - YouTube Gurmat Vichaar Apr 23, 2016
    Uk clocks go back Blogs Oct 17, 2015
    Kesh: Dreadlocks Questions and Answers Nov 20, 2013
    Obamacare Faces Near-Solid Block In The South Health & Nutrition Mar 31, 2013
    Malaysia Have you forsaken your flock, Archbishop? Malaysia News Update Breaking News Jan 30, 2013

  3. Barry Gilbert

    Barry Gilbert
    Expand Collapse
    Guest

    In the combobox's AfterUpdate event, put:

    Me.AllowEdits=(Me.Status = "Active")
    Me.AllowAdditions=Me.AllowEdits
    Me.AllowDeletions=Me.AllowEdit

    Barry

    "Jorg" wrote:

    > I have a combo box - Status- with active-closed. when set to "closed" i want
    > to lock the data entry for this record.
     
  4. Jorg

    Jorg
    Expand Collapse
    Guest

    Hi Barry,
    Thanks for your help, it works - but when I reopen the data base the record
    set to "close" can be edit again. Any further thoughts?
    jorg

    "Barry Gilbert" wrote:

    > In the combobox's AfterUpdate event, put:
    >
    > Me.AllowEdits=(Me.Status = "Active")
    > Me.AllowAdditions=Me.AllowEdits
    > Me.AllowDeletions=Me.AllowEdit
    >
    > Barry
    >
    > "Jorg" wrote:
    >
    > > I have a combo box - Status- with active-closed. when set to "closed" i want
    > > to lock the data entry for this record.
     
  5. Barry Gilbert

    Barry Gilbert
    Expand Collapse
    Guest

    When you say the record can be edited again, do you mean through the form or
    are you trying to edit it in the table?

    This code doesn't affect the ability to edit the record, it just changes
    properties on the form when the record is displayed. The code basically says,
    if the status column on the current record is "active", allow edits,
    otherwise don't.

    Barry

    "Jorg" wrote:

    > Hi Barry,
    > Thanks for your help, it works - but when I reopen the data base the record
    > set to "close" can be edit again. Any further thoughts?
    > jorg
    >
    > "Barry Gilbert" wrote:
    >
    > > In the combobox's AfterUpdate event, put:
    > >
    > > Me.AllowEdits=(Me.Status = "Active")
    > > Me.AllowAdditions=Me.AllowEdits
    > > Me.AllowDeletions=Me.AllowEdit
    > >
    > > Barry
    > >
    > > "Jorg" wrote:
    > >
    > > > I have a combo box - Status- with active-closed. when set to "closed" i want
    > > > to lock the data entry for this record.
     
  6. Barry Gilbert

    Barry Gilbert
    Expand Collapse
    Guest

    When you say the record can be edited again, do you mean through the form or
    are you trying to edit it in the table?

    This code doesn't affect the ability to edit the record, it just changes
    properties on the form when the record is displayed. The code basically says,
    if the status column on the current record is "active", allow edits,
    otherwise don't.

    Barry

    "Jorg" wrote:

    > Hi Barry,
    > Thanks for your help, it works - but when I reopen the data base the record
    > set to "close" can be edit again. Any further thoughts?
    > jorg
    >
    > "Barry Gilbert" wrote:
    >
    > > In the combobox's AfterUpdate event, put:
    > >
    > > Me.AllowEdits=(Me.Status = "Active")
    > > Me.AllowAdditions=Me.AllowEdits
    > > Me.AllowDeletions=Me.AllowEdit
    > >
    > > Barry
    > >
    > > "Jorg" wrote:
    > >
    > > > I have a combo box - Status- with active-closed. when set to "closed" i want
    > > > to lock the data entry for this record.
     
  7. Jorg

    Jorg
    Expand Collapse
    Guest

    Through the form. also once "closed†is applied all other records are also
    not edible.

    "Barry Gilbert" wrote:

    > When you say the record can be edited again, do you mean through the form or
    > are you trying to edit it in the table?
    >
    > This code doesn't affect the ability to edit the record, it just changes
    > properties on the form when the record is displayed. The code basically says,
    > if the status column on the current record is "active", allow edits,
    > otherwise don't.
    >
    > Barry
    >
    > "Jorg" wrote:
    >
    > > Hi Barry,
    > > Thanks for your help, it works - but when I reopen the data base the record
    > > set to "close" can be edit again. Any further thoughts?
    > > jorg
    > >
    > > "Barry Gilbert" wrote:
    > >
    > > > In the combobox's AfterUpdate event, put:
    > > >
    > > > Me.AllowEdits=(Me.Status = "Active")
    > > > Me.AllowAdditions=Me.AllowEdits
    > > > Me.AllowDeletions=Me.AllowEdit
    > > >
    > > > Barry
    > > >
    > > > "Jorg" wrote:
    > > >
    > > > > I have a combo box - Status- with active-closed. when set to "closed" i want
    > > > > to lock the data entry for this record.
     
  8. Barry Gilbert

    Barry Gilbert
    Expand Collapse
    Guest

    Ok. You should put this code in the form's OnCurrent event as well.

    Barry

    "Jorg" wrote:

    > Through the form. also once "closed†is applied all other records are also
    > not edible.
    >
    > "Barry Gilbert" wrote:
    >
    > > When you say the record can be edited again, do you mean through the form or
    > > are you trying to edit it in the table?
    > >
    > > This code doesn't affect the ability to edit the record, it just changes
    > > properties on the form when the record is displayed. The code basically says,
    > > if the status column on the current record is "active", allow edits,
    > > otherwise don't.
    > >
    > > Barry
    > >
    > > "Jorg" wrote:
    > >
    > > > Hi Barry,
    > > > Thanks for your help, it works - but when I reopen the data base the record
    > > > set to "close" can be edit again. Any further thoughts?
    > > > jorg
    > > >
    > > > "Barry Gilbert" wrote:
    > > >
    > > > > In the combobox's AfterUpdate event, put:
    > > > >
    > > > > Me.AllowEdits=(Me.Status = "Active")
    > > > > Me.AllowAdditions=Me.AllowEdits
    > > > > Me.AllowDeletions=Me.AllowEdit
    > > > >
    > > > > Barry
    > > > >
    > > > > "Jorg" wrote:
    > > > >
    > > > > > I have a combo box - Status- with active-closed. when set to "closed" i want
    > > > > > to lock the data entry for this record.
     
  9. Jorg

    Jorg
    Expand Collapse
    Guest

    Thanks Barry, that was it.

    "Barry Gilbert" wrote:

    > Ok. You should put this code in the form's OnCurrent event as well.
    >
    > Barry
    >
    > "Jorg" wrote:
    >
    > > Through the form. also once "closed†is applied all other records are also
    > > not edible.
    > >
    > > "Barry Gilbert" wrote:
    > >
    > > > When you say the record can be edited again, do you mean through the form or
    > > > are you trying to edit it in the table?
    > > >
    > > > This code doesn't affect the ability to edit the record, it just changes
    > > > properties on the form when the record is displayed. The code basically says,
    > > > if the status column on the current record is "active", allow edits,
    > > > otherwise don't.
    > > >
    > > > Barry
    > > >
    > > > "Jorg" wrote:
    > > >
    > > > > Hi Barry,
    > > > > Thanks for your help, it works - but when I reopen the data base the record
    > > > > set to "close" can be edit again. Any further thoughts?
    > > > > jorg
    > > > >
    > > > > "Barry Gilbert" wrote:
    > > > >
    > > > > > In the combobox's AfterUpdate event, put:
    > > > > >
    > > > > > Me.AllowEdits=(Me.Status = "Active")
    > > > > > Me.AllowAdditions=Me.AllowEdits
    > > > > > Me.AllowDeletions=Me.AllowEdit
    > > > > >
    > > > > > Barry
    > > > > >
    > > > > > "Jorg" wrote:
    > > > > >
    > > > > > > I have a combo box - Status- with active-closed. when set to "closed" i want
    > > > > > > to lock the data entry for this record.
     

Share This Page