Search results

  1. X

    Need some serious help about opening form from listboxes!!!!

    Hi, I am having trouble opening a form and editing a record based on the record i selected from my listbox. I have tried two codes and both failed..ill just state the codes here: 1st code: DoCmd.OpenForm "AddNewBorrower", , , _ "[tblBorrowerDetails.BorrowerSerialNo]=" &...
  2. X

    Which is the best code to use to save a record and exit using a button?

    Do i replace the "Name" in Me.Name with the form's name?
  3. X

    Which is the best code to use to save a record and exit using a button?

    Hi, What is the best code to use in order to save the record and quit the form? I have a main menu so i will save,quit this form and go to main form I have this code: Private Sub testingsaveok_Click() If Me.Dirty Then Me.Dirty = False DoCmd.OpenForm "BorrowerSection", acNormal DoCmd.Close...
  4. X

    Instead of AcSaveNo, what should i use to save record?

    Hi, I have read that the command AcSaveNo only saves the form, not data. So which code should i use to save the data in a form? Heres my code DoCmd.OpenForm "BorrowerSection", acNormal DoCmd.Close acForm, "AddNewBorrower", acSaveNo
  5. X

    How to create a save and go to new record button without affecting Me.Undo??

    Ok then can you teach me to prompt them if they move forms or try to save it while not prompting when they press the add record button?
  6. X

    Are cascade updates neccessary when all your foreign keys are autonumbers?

    SOrry i said it wrongly yea my foreign keys are numbers.. and the datatype is set to the same as the autonumber
  7. X

    Are cascade updates neccessary when all your foreign keys are autonumbers?

    Hi, Even if your foreign keys are all autonumbers, it doesnt matter if you tick or do not tick the cascade update amiright? Since its not advised to change autonumbers/primary keys. I only know that its neccessary to tick the cascade delete so that you are able to delete the related records.
  8. X

    How to create a save and go to new record button without affecting Me.Undo??

    Hm...but i have establish the relationships in the relationships windows. Perhaps i shall attach my database in this post and if possible could you take a look and see if my relationships are properly connected? Also, i noticed that when i deleted a record, it didnt cascade and subform records...
  9. X

    How to create a save and go to new record button without affecting Me.Undo??

    hmm i think the code did not work the way i wanted. I think this code still has problems. The problem that still happens is that whenever i press the add new record button, the message prompt still appears. I just want the messagebox not to appear when i press this add new record button...
  10. X

    How to create a save and go to new record button without affecting Me.Undo??

    Then i would like the sub to not affect the record and go ahead with giving the msgbox. Anyways, i tested the code and it didnt undo the changes when i purposed click to another subform so i went to check your code...it did not have me.undo. So i added it in under the cancel true i Private...
  11. X

    How to create a save and go to new record button without affecting Me.Undo??

    Ok so i just have to add the following code in right?Ill try it now Private Sub Form_BeforeUpdate(Cancel As Integer) 'Ensure that users do not accidentally save records If me.newrecord then exit sub If MsgBox("Do you want to save the updated records?", vbOKCancel, "Save?") = vbCancel...
  12. X

    How to create a save and go to new record button without affecting Me.Undo??

    Ok but how do i add an exception to new records. SInce this code fires whenever the form is dirtied, then this would be a problem as new records are not accidental and are to be added in intentionally. Edit:My previous code works the same as your code right? If so, the sub will surely affect...
  13. X

    How to create a save and go to new record button without affecting Me.Undo??

    I only added the code you gave me.Ok I just want to add my reason for doing this.My form has 2 subforms on it and i intend to add a new record button to each of them so that the only way you can save the records are to click on the buttons.Or maybe i would just add a save button and new record...
  14. X

    How to create a save and go to new record button without affecting Me.Undo??

    Alright i have added in the in code that you gave me. what im going to do now is add a new record button using the wizard. Hope it works Private Sub Form_BeforeUpdate(Cancel As Integer) If Me.Dirty Then 'Ensure that users do not accidentally save records If MsgBox("Do you want to save the...
  15. X

    Can someone help me add an exception argument to my cancel as integer sub?

    So i have this code: Private Sub Form_BeforeUpdate(Cancel As Integer) If Me.Dirty Then 'Ensure that users do not accidentally save records If MsgBox("Do you want to save the updated records?", vbOKCancel, "Save?") = vbCancel Then Me.Undo End If End If End Sub How do i add a code inside that...
  16. X

    What's your best/worst joke?

    7 didnt 8 9, 9 8 7
  17. X

    What's your best/worst joke?

    Why did the chicken cross the road? A: Because there were no cars
  18. X

    How to create a save and go to new record button without affecting Me.Undo??

    Yes is it the cancel before integer? So what do i do with it. Can you give me an example of what i should do and how it relates to the button that i want to create.
  19. X

    How to create a save and go to new record button without affecting Me.Undo??

    How do i create a button that saves the current record and moves to a new one? I want to do it in such a way that microsoft access acknowledges the button. Below is the following codes in my form: Private Sub Form_BeforeUpdate(Cancel As Integer) If Me.Dirty Then 'Ensure that users do not...
  20. X

    How do i minimise/control the size of the form to the centre of the screen?

    Hi, How do i minimise my form so that it is centred in the middle of the screen? I want to have my form all centred in the screen so it maintains consistency. Also if possible, can anyone tell me how to modify the forms size because i want my switchboard to be bigger than my entry forms but...
Back
Top Bottom