Search results

  1. nanscombe

    Default Table Value & Unknown Functions Post-Upgrade

    Again on a "real" answer note I've just fired up an old copy of Access 2003, tried to add a default value of =fOSUserName(), using a made up function, and received the error message ... :confused: :confused: Run an Update query, to add the username, after the Import I guess.
  2. nanscombe

    Default Table Value & Unknown Functions Post-Upgrade

    I guess if one migrated to storing the data in Oracle, SQL Server or MySQL those functions wouldn't work so they might have removed the capability to ensure compatibility. Personally, I would either add the fOSUserName() function as the DefaultValue of any controls that are linked to the field...
  3. nanscombe

    Required a Dmax or Dcount solution

    Ok. As long as you've got what you need. :) Just tuck anything else away in case you need it another time. ;)
  4. nanscombe

    Required a Dmax or Dcount solution

    I'm with you now. :) The attached database should allow you to do that. Here is the code I'm using (this is the version with comments) Private Sub getSerialForSelectedRecords_WithComments() ' Same code as "getSerialForSelectedRecords" but with added comments. ' Open a clone of the current...
  5. nanscombe

    Required a Dmax or Dcount solution

    How are you "selecting" the records, by using the record selector on the left hand side of the record or using the ForGRN checkbox? I've added a demo with the functionality connected to double-clicking the Serial field.
  6. nanscombe

    Import txt file using VBA (not DoCmd.TransferText)

    A file with the headings and a couple of lines of dummy data would at least let us know what you are starting with. Even an empty file, with just the headings, and an explanation of the data types would help, from there we could construct some data.
  7. nanscombe

    2014 Programmers Survey - What do you Drink During Work

    That's probably not as daft as it sounds. I've often said that making food and drinks available to employees on site removes the excuse to leave the building and gets them back to their desks quicker than nipping out to the local restaurant, cafe etc. If you eat breakfast at the office and...
  8. nanscombe

    Import txt file using VBA (not DoCmd.TransferText)

    That might have been me with an Update query that uses an Outer join to either add records where a datestamp on the record was non existent or update if it were earlier.
  9. nanscombe

    Required a Dmax or Dcount solution

    Is the value of AUTO added manually for each record? Do have records which are allowed to have a value in AUTO but not have a value in SERIAL? The above code would automatically generate a value for SERIAL based on the value in AUTO if it didn't already have one when the record was saved.
  10. nanscombe

    Import txt file using VBA (not DoCmd.TransferText)

    For a reporting application I had a separate database on the local drive as a repository for any "temporary" results tables. I used a piece of code to check its date when the application started and, if it was not created today or didn't exist, I'd create a fresh one. If it's binned at the...
  11. nanscombe

    Required a Dmax or Dcount solution

    You could achieve it with this code. Private Sub Form_BeforeUpdate(Cancel As Integer) 'If Me.SERIAL is empty then get next value If Len(Me.SERIAL & vbNullString) = 0 Then Me.SERIAL = getNextSerial(Me.AUTO) End Sub Private Function getNextSerial(ByVal gnsAuto As Variant) Dim varTemp As...
  12. nanscombe

    Public variable problem

    I thought it was worth doing a comparison so I powered up my old sub notebook, which has Windows XP and Access 2003 on it, and waited .... :( and waited ... :banghead: and waited ... :D Anyway, I'm glad it proved useful. :)
  13. nanscombe

    Are you an atheist?

    The Bible contains a cunning paragraph for people who are having their faith challenged. Matthew 5:11
  14. nanscombe

    Public variable problem

    I have attached a modified version of ChrisO's database. Form 1, Setting the Default Property of field Text0 to ="""" & [A] & """" on the Property Sheet. Access 2003: "ABC" (Incorrect) Access 2010: #Name (Incorrect) Form 2, using VBA to set the default of Text0 Me.Text0.DefaultValue = """" &...
  15. nanscombe

    Public variable problem

    Repeating Using ChrisO's database Windows XP + Access 2003 (Using the Property Sheet) Default Value [A] (Out of the box) ABC =[A] ABC Changing tack and using VBA. Me.Text0.DefaultValue = A #Name Me.Text0.DefaultValue = """" & A & """" ABC Going back to the original way of doing things...
  16. nanscombe

    Public variable problem

    I'm currently trying to repeat the experiment on an old laptop with Access 2003, it's taking a while. I'll post the results when I've finished.
  17. nanscombe

    Public variable problem

    Using ChrisO's database Windows 7 + Access 2010 (Using the Property Sheet) Default Value [A] (Out of the box) #Name =[A] #Name Changing tack and using VBA. Me.Text0.DefaultValue = A #Name I noticed in the Access help for DefaultValue the following syntax...
  18. nanscombe

    Are you an atheist?

    Not if humans evolved from apes.
  19. nanscombe

    Are you an atheist?

    If you subscribe to the idea that humans evolved from chimp-like creatures then an evolved chimp-like creature has already typed the FIRST LINE of Hamlet .. his name was William Shakespeare.
  20. nanscombe

    Form with multi-criteria searches, uses strings and filters

    Any records with Null fields? If you're using this syntax is it a text field? You could try ... Like "'*" & Nz([Forms]![MyForm]![MyField]) & "*'" Used this way the Nz() function would default any Null values to an empty string.
Back
Top Bottom