Search results

  1. Z

    Error -2147467259 Outlook doesn't recognize one or more names

    I have a database for weekly timesheets. It contains a function I created the can be used each week to send reminder emails to those who have not completed a timesheet. The database and function have worked fine for years, but recently it has stopped working on one users machine. When the...
  2. Z

    Collation Error Issue

    Thanks for your suggestion, I have managed to solve it. It wasn't anything to do with nvarchar vs varchar it was to do with the "Employees database" had been set up in US-English and the "Actions database" set up in British English, this caused the join problem. I solved it by changing the...
  3. Z

    Collation Error Issue

    I have just spotted that one table uses varchar(10) data type, the other nvarchar(10). Which I am guessing is the problem. I assume though if I change the datatype on one of the tables it will then create a similar problem with all other relations to that field in the same database...
  4. Z

    Collation Error Issue

    I have a recently created SQL database for actions called "Actions", there is already an existing database on the same server for "Employees". I wish to pull the Employee name via their staff number into the actions database (every action has a "By_Who" field of same data type as the staff...
  5. Z

    issues with Split function

    So varValues() as Variant needs to be a strValues() as string. Thanks.
  6. Z

    issues with Split function

    I am trying to write a procedure that takes an string array of field names and a tab delimited string and then splits the appropriate value for each field from the string so it can be appended with a querydef. The code suffers a runtime error on line 30 type mismatch but I cannot work out why...
  7. Z

    Solved Autonumber Advice

    I am thinking on my feet a little, but from an operational perspective, it would make little difference whether parts were "related" many to many with "orders" or many to many with a child table of orders called "dispatches" it could still be used to reduce your stock. Alternatively a...
  8. Z

    Solved Autonumber Advice

    I would be tempted to look at your problem from a different perspective. It sounds like each order can have multiple deliveries. I would be inclined to have a child table for deliveries rather than split a single order up into 3 separate orders. If you still wish to have separate orders with...
  9. Z

    problems replacing or splitting on a tab contained in a string

    Just tried your code, it works, thanks for that. I am now wondering if the problem was caused by the immediate window converting vbTab to chr(32) chr(32) chr(32). I was testing my function in the immediate window rather than feeding it the contents of a file. Will do a bit more digging...
  10. Z

    problems replacing or splitting on a tab contained in a string

    I am not sure about anything anymore to be honest. I will checkout your code later today, have a busy morning. I have modified my sub, see below. I need to use three chr(32) rather than vbTab: Public Sub SplitStringByTab(strInput As String) 'vbTab doesn't appear to recognise a tab, neither...
  11. Z

    problems replacing or splitting on a tab contained in a string

    SOLVED! After a bit of reverse engineering it appears that Access recognises tabs from an excel generated tab delimited file as chr(32) not chr(9) and not vbTab. Weirdly, even if the tabs are cut and pasted from another application such as Notepad++ it converts them to chr(32). Gasman and Minty...
  12. Z

    problems replacing or splitting on a tab contained in a string

    I decided to go back to basics as you have here, below is step by step what I did. What is clear is Access on my machine will not create tabs and will not recognise tabs in text strings. I am completely confused! In the example below I have used the vb immediate window and cut and pasted...
  13. Z

    problems replacing or splitting on a tab contained in a string

    "Project Task" is not part of the problem, because I do not include it in my real import, just got lazy when I posted the txt file example and left it in.
  14. Z

    problems replacing or splitting on a tab contained in a string

    I may have to resort to that, but I was hoping I wouldn't need to because I don't like things that don't work when it looks like they should.
  15. Z

    problems replacing or splitting on a tab contained in a string

    The file is a tab delimited text file which has been output from Excel. I have attached an example. I tried copying and pasting a single line (third one down) as an argument to the function & sub in the VBA immediate window. I also tried typing a string into the function and sub...
  16. Z

    problems replacing or splitting on a tab contained in a string

    I am trying to process a tab delimited text file, the ultimate aim to populate a table in access with the contents of each line. But I am unable to detect the "tabs" in the test file. I have tried using the split function with various arguments and also strReplace with various argument. None of...
  17. Z

    Problems using arrays

    Managed to get the principal working changed it to a sub. I will raise a separate issue on that with an appropriate title. Thanks for the help
  18. Z

    Problems using arrays

    I am calling it from the immediate window using ?splitstringbytab ("This is a test string")
  19. Z

    Problems using arrays

    Thanks that gets me further it now runs but I am getting a runtime error 13 type mismatch, but it isn't triggering my error trapping routine! It gets to line 60 then goes to 70. Public Function SplitStringByTab(strInput As String) As Variant 10 On Error GoTo err_SplitStringByTab...
  20. Z

    Problems using arrays

    As I said, I haven't even progressed to tabs yet, I can't even get it running with spaces. I understood the second argument was optional and if omitted it defaults to space, hence I left it off. I have tried adding , " " after strInput but I still get a compile error.
Back
Top Bottom