Search results

  1. D

    Useless error when setting a value

    Pat, I solved this by changing the name of the control. I think it was an Access quirk, that by changing the name of the control to something other than the control SOURCE it was able to work. The fact that it was two words might not have helped. And yes - I tried all .s and all !s. Didn't...
  2. D

    Useless error when setting a value

    Yes, both forms are open.
  3. D

    Useless error when setting a value

    I have the following code: [Forms]!components.[Serial Number] = [Forms]![serials]![Serial Number] and get the attached error when it runs. Why? The error is totally useless. I've checked my control names and everything is fine.
  4. D

    Is there a more elegant way of deleting records from VB than this? >>>

    Any way of physically removing the data from the table by code wihtout referring to menu commands?
  5. D

    Is there a more elegant way of deleting records from VB than this? >>>

    DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70 DoCmd.DoMenuItem acFormBar, acEditMenu, 6, , acMenuVer70
  6. D

    Form asks for query criteria on loading (listbox problem)

    So do you have any other ideas Rick? I can email the database to you but would prefer not to post it. Thx
  7. D

    Form asks for query criteria on loading (listbox problem)

    Rick, the reference is definitely named correctly. There's a field with associated textbox called 'Fault Ref', and the box prompts me to enter forms!support!Fault Ref which is right there on the form!
  8. D

    Form asks for query criteria on loading (listbox problem)

    I have a listbox that uses a query to reference a value in the current form. The problem is for some reason Access is trying to fill this listbox before even showing the form, so I get prompted to manually enter the query criteria when it should be picking it up from the form. This is bizarre...
  9. D

    Bizarre problem opening form

    I have a form that opened perfectly before from a click event with a standard link criteria lookup function, and...it's suddenly stopped working! Before the form opens I get a small query box asking: Forms!support!fault ref In other words it's asking me to enter the value it should've got from...
  10. D

    How good is the upsizing wizard?

    If you have a fairly complex web of forms with functions going on all over the place, can the upsizing wizard redirect all the queries and control sources? Is it possible to continue using the same VBA front end with a database that's been migrated to SQL Server?
  11. D

    Listboxes with carriage return entries

    I have listboxes sourced from a table with string entries that are 255 chars long, and I've found that if the entry contains a carriage return then it can't open the form with the listbox. stLinkCriteria = "[Note]=" & "'" & Me![lstNotes] & "'" DoCmd.Close DoCmd.OpenForm "Notes", ...
  12. D

    Dlookup prob

    RuralGuy, I took your advice and moved the function to the AfterUpdate even instead. After what you've said I'm a little worried that speed might become an issue as the database grows, because I have Dlookups going on all over the place, enabling and disabling buttons etc.
  13. D

    Dlookup prob

    RuralGuy - thanks. I'm being a dunce! I just changed the code to this: Dim Asset As Variant Dim Host As Variant Asset = DLookup("[Serial Number]", "Serials", "[Serial Number]=" & "'" & Me![Serial Number] & "'") cmdSerial.Enabled = Not IsNull(Asset) If...
  14. D

    Dlookup prob

    This is odd, because here's the code I have on the field's change event: Private Sub Serial_Number_Change() Dim Asset As Variant Dim Host As Variant Asset = DLookup("[Serial Number]", "Serials", "[Serial Number]=" & "'" & Me![Serial Number] & "'") If IsNull(Asset) =...
  15. D

    Dlookup prob

    I have the following code: Asset = DLookup("[Serial Number]", "Serials", "[Serial Number]=" & "'" & Me![Serial Number] & "'") ...but the problem with this is it finds a match even based on partial data. E.G. if I have a serial number CK99901, and someone enters CK999... then the above...
  16. D

    Any way of numbering the entries in a listbox?

    Ah, I was hoping there was an easier way than actually adding the numbers as data. Thanks anyway Pat.
  17. D

    Any way of numbering the entries in a listbox?

    Better still, any way of inversely numbering them from top to bottom?
  18. D

    "hyperlink" data type for email addresses?

    Is there an easy way to have Access format all values in a particular field with the hyperlink data type to add the mailto: prefix so you can just click on the links to email someone?
  19. D

    Enable/disable button based on lookup on another table

    Thanks Ken. Can you help with the syntax? I've got Dim CarePackExists As Variant CarePackExists = DLookup("[Care Pack ID]", "Care Packs", "[Care Pack ID] = " _ & Forms!Serials![Care Pack ID]) cmdViewCarePack.Enabled = Not IsNull(CarePackExists) Am I right in thinking this...
  20. D

    Enable/disable button based on lookup on another table

    I have an 'associated' button on one form that jumps to another form and shows the associated record via the common field. However, that data may not necessarily be there - in other words, it'll be in the first form but the matching data may not be present in the other form, meaning it opens...
Back
Top Bottom