Recent content by tsteinh

  1. T

    Most recently recreated autonumber.

    Wayne: Here is my code: Dim holdid As Long, rst As Recordset Set rst = CurrentDb.OpenRecordset("tblTest", dbOpenDynaset) rst.AddNew rst!Remarks = "testing" rst.Update holdid = rst!TestID ' <<--- always returns 1, not last autonumber rst.Close Set rst = Nothing I set a breakpoint at the...
  2. T

    Most recently recreated autonumber.

    Retrieving autonumber value Does anyone know if there is a way to do this in Access97? I tried this code and I get "Invalid object or no longer set" if I try to get the value of the autonumber field after the recordset.close operation. If I try to get the value before the close, then I get a...
  3. T

    Autonumber start at 500

    Autonumber starting at a set value Ok, I need to use this code, but what is ADOX.Catalog and how do I include it in my code? I am using Access 2000 Thanks!
  4. T

    InStr problem

    I found the problem with a little assistance from another user. In case someone else runs into this, you must specify the start position if you also want to indicate the type (vbBinaryCompare). The pos variable needs to be a Long type. In my case, I had to specify both the starting position and...
  5. T

    InStr problem

    Here is some test code that illustrates my real problem: SID = "b90e09s00" pos = InStr(SID, "B") 'look for B If pos > 0 Then pos = InStr(pos, SID, "E") 'look for E If pos > 0 Then pos = InStr(pos, SID, "S") 'look for S If pos > 0 Then 'have a BES format...
  6. T

    InStr problem

    Harry: I will look at the problem in debug mode again. If your code works I must have another problem that I am just not seeing. Thanks for the assistance! At least I know that this should work!
  7. T

    InStr problem

    Harry: SID is defined as a String and pos is an Integer. I added the vbBinary to make sure it only found the upper case B. It appeared to me that the lower case B was also being found when I left off the vbBinary. Do you have another idea I should try? I just want pos to have a value if the...
  8. T

    InStr problem

    Can someone tell me why this statement fails in Access97 when the string SID contains CTRLTH232099 pos = InStr(SID, "B", vbBinaryCompare) I simply want to know if the string contains a capital B. I keep getting a type mismatch error. Thanks!
  9. T

    Allowing blank entry in combo box

    I have a combo box that is populated from an Access table. This is working fine, except that I want the user to be able to use a barcode reader to wand in a selection. In order to do this, I'd like to be able to clear the combo box entry on an Add so that they can either wand the value or select...
  10. T

    Need to make Do loop stop

    Joe and Alexandre: Thanks to both of you! I will try both options and see which one works best. This is the best forum for Access questions that I have found! I spend a lot of time searching for advise here! Keep up the good work!
  11. T

    Need to make Do loop stop

    Let me explain a little better :-) txtMass, txtTare, and txtNetMass are on the same form. txtMass will be updated within the do loop whenever tblReadings (updated from another process, not on this form) Mass field becomes nonzero. The loop is waiting for this event to occur. When it does, the...
  12. T

    Need to make Do loop stop

    I am having some problems with my code and could use some insight. I am waiting for a field in a one-record file to be filled by an outside process. Once this field is filled, I can retrieve the value and continue processing. There are 2 sides on the screen and this code is operating on the...
  13. T

    Page Headers and Subreports

    I have an Access97 report that consists of several subreports. I found that in order for each subreport to show its headers, I need to use the page header in each subreport. The problem I am having is that when one of these subreports continues on another page, I lose the page header for the...
Top Bottom