Search results

  1. Notiophilus

    What do the events Form_CommandExecute, CommandChecked, CommandBeforeExecute etc actually DO?

    Access 2010. Trying to understand more about event order on forms, I ran into the Form events CommandBeforeExecute, CommandChecked, CommandEnabled, and CommandExecute. They look intriguing and possibly useful, but what do they actually do, and what triggers them? According to Microsoft's help...
  2. Notiophilus

    Bypass Form_BeforeUpdate validation when switching to a subform

    I have a bound parent form with two subforms. If the user tries to leave a record without having entered certain key data (title, summary, link), the form challenges them: they can either cancel and stay on the record to enter the missing data, or keep going, and the incomplete record will be...
  3. Notiophilus

    Solved Nz(control.DefaultValue) returns Null, not 0 or "". Why?

    ETA: IGNORE EVERYTHING, I'M AN IDIOT I have some filter controls on my form whose values I save to a bookmarks table on Form_Unload. I save them if and only if the control value (stored in .Tag) <> the default value. Some default values are null, e.g. triple-state checkboxes, so I stuck a Nz on...
  4. Notiophilus

    Solved On Error Resume Next : Exit Sub... why?

    Going through my spaghetti code I find the following error handler: ExitHandler: On Error Resume Next Exit Sub ErrHandler: Call LogError Resume Next End Sub What's the purpose of "Resume Next" right before exiting? Can Exit Sub throw an error? I see this all over the place...
  5. Notiophilus

    Run code ONLY on record change/close

    Access 2010. I want to run some code when you change record or exit the form: check if title AND summary AND link are blank, and if they are discard the record check if record is a duplicate and then do stuff if everything is OK, then commit unbound fields Form_BeforeUpdate / AfterUpdate...
  6. Notiophilus

    Mimicking hyperlink behaviour (tooltip, cursor) in VBA

    [SOLVED] Mimicking hyperlink behaviour (tooltip, cursor) in VBA I want to use my own VBA hyperlink function, which is just FollowHyperlink + error handling to copy broken links to clipboard, to replace the default =[Title]#[Link]#. It works perfectly, but is there a way to mimic, in a...
  7. Notiophilus

    Trouble with WITH... and report

    Access 2010. I have a subform which dynamically shows either a form or a report. On the main form there is a button to clear the recordset and filters of each, and for clarity's sake I used a with... end with statement. Access disnae like it. With the form, this works: If...
  8. Notiophilus

    Query for duplicates across two tables

    I have two tables in a one-to-many relationship, tblBooks and tblBookAuthor. A book may have multiple authors, and several books may have the same title. [tblBook] [tblBookAuthor] BookID (PK) Title BookID (PK) AuthorID (PK) ----------- --------------...
  9. Notiophilus

    Strange behaviour - filters are not remembered between loads

    I have a search form which suddenly stopped remembering filters between loads. I managed to accidentally replicate the behaviour on a second database where I knew the filters worked - in this case the code was Private Sub Form_Unload(Cancel As Integer) Me.Filter = "(False)"...
  10. Notiophilus

    Control with values from a query OR a table

    I have an option group which should display a value from a table if txtWords is null, but the result of a query if txtWords is not null. But though it shows the right results when I load the form, updating txtWords gives me all sorts of errors. Can someone help me work through this? txtWords is...
  11. Notiophilus

    Sort the combobox displayed value

    Combobox displayed value Hello! New user here :) and quite new to databases, too, so forgive me if this is an easy question :o I have a combobox which lets you select from a list of pseudonyms. Each pseud belongs to an author; authors can have multiple pseudonyms and exactly one main...
Top Bottom