Search results

  1. dcx693

    Required fields

    I would put the code into a different event. Since the problem is occurring with updates to records, perhaps the Before Update event instead of the On Current event.
  2. dcx693

    vba not recognizing str = " "

    Why do you have rst0![SchoolComments]=" " four times in your If statement? And, it's been a while, but I don't think rst0![SchoolComments] = Null will work. I don't think you can set the value of a text field to Null. You should try to set it to "" (two double quote marks with nothing in...
  3. dcx693

    calc in a query

    Don't forget to close Mile's parentheses. :)
  4. dcx693

    vba not recognizing str = " "

    What is lenstr?
  5. dcx693

    How to use reports with comboxes Access 2002

    And you're sure the report's source query (or table) contains the fields: [yourname], [customer] and [status] ?
  6. dcx693

    Text Box Reference - there must be a way !!

    Why do you want to do this? If you must, Mile's suggestion sounds cool.
  7. dcx693

    How to use reports with comboxes Access 2002

    What type of data is contained in the bound column of the 3 combo boxes? Are they all text, or numeric possibly?
  8. dcx693

    Most effective way of coding

    If you call a piece of code more than once, it's best to reference that piece of code using a call rather than having the same code in your program twice. If you need to alter the code, you'll just change it once.
  9. dcx693

    Removing Queries with Code

    If you look at my question above, I asked the user if he/she needed ADO or DAO. The user replied with "DAO". That's the problem. :)
  10. dcx693

    Removing Queries with Code

    I thought we were looking for DAO code. :confused:
  11. dcx693

    Removing Queries with Code

    Using DAO or ADO? If you're not sure, which version of Access are you using?
  12. dcx693

    How to I check to see if a field exists in a table using VB?

    I honestly don't know what's wrong with the code, but I can suggest something that might do the job just as well. Why not attempt to run the code and use an On Error Resume Next statement to ignore the error if the field does not exist? You can use something like:Sub DeleteMyField On Error...
  13. dcx693

    delete certain variables from string

    If you're using Access 2000 or higher, you can use the Replace function like this: Replace("05605080","0","") If you're using Access 97 (or earlier), you'll need to use code like Fofa's. If speed is not an issue, and you're lazy :), and you have Excel also installed on the same computer, you...
  14. dcx693

    A Simple VB problem - I think

    I think a simple change would do the trick: process=process(subDir, tempInt) VB is complaining, as Mile rightly points out, because a function when returning a value must be assigned a value. (You can call a function that doesn't return a value and never assign a return value. I often do this...
  15. dcx693

    Problem with FINDFIRST

    How is rsNewDirs defined?
  16. dcx693

    AutoNumber

    First step is to search the forums to see if someone has already answered your question. :) You might have found pointers to articles like this: How to Use an Append Query to Set Initial Value of an AutoNumber Field
  17. dcx693

    MCount - Faster than DCount?

    I didn't really look too closely at the code. Just thought there might be something of interest in there for you. Oh well. ?
  18. dcx693

    MCount - Faster than DCount?

    Mile, don't know if this would interest you, but I recalled that on the Access web someone had previously created replacements for the DLookup, DCount, DSum, DMax & DMin functions. Here is the link: Domain Aggregate Functions Replacements I quickly looked at the code, and it is also in DAO. The...
  19. dcx693

    Query by name AND last record

    Yes, it's possible, but do you really need to repeat the ID field in the final results? If not, you save yourself a step with this: SELECT tblRoomUsage.Room, Last(tblUsage.Hours) AS LastOfHours FROM tblUsage GROUP BY tblRoomUsage.Room; if you need the ID number, just join that query back to...
  20. dcx693

    Create Database

    Can't you just make a call to the sub from your existing code? Or paste the code into your existing sub? Are you unsure of how to do that. Note that code in both examples is written using DAO, the default data access technology in Access 97 and previous. If you're using Access 2000 or higher...
Back
Top Bottom