Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. RevJohn0584

    VBA code for filters

    Last update: All is working well and this tool is doing exactly what we needed. Many thanks again to all who helped!!!!!!
  2. RevJohn0584

    VBA code for filters

    you. guys. rock. It is working very well. That last issue joe addressed was spot on. I do believe we have victory, guys. Thank you sooooo very much for all of your assistance.
  3. RevJohn0584

    VBA code for filters

    OK, it works when it runs alone, but when I combine both ShipDest and PN as a filter criteria set, I get a type mismatch error 13....i.e.: PN: 301154 = returns fine or ShipDest: DTK3A = returns fine PN: 301154 and ShipDes: DTK3A returns "type mismatch error 13" What did I miss or do wrong?
  4. RevJohn0584

    VBA code for filters

    If IsNumeric(Me(Nam)) And CStr(Val(Me(Nam))) = Me(Nam) And Me(Nam).Tag <> "ShipDest" And Me(Nam) And Me(Nam).Tag <> "PN" Then I think I got it!!!!!!!!
  5. RevJohn0584

    VBA code for filters

    If IsNumeric(Me(Nam)) And CStr(Val(Me(Nam))) = Me(Nam) And Me(Nam).Tag <> "ShipDest" And "PN" Then gives a run time error. this line was highlighted in the debug. I am obviously not getting it.
  6. RevJohn0584

    VBA code for filters

    lameid, I am sorry, but I am not sure I have this figured out. The line you posted is the one that we changed earlier on to deal with the ShipDest issue. DO I add an OR and then outline "PN" to be affected as well? If IsNumeric(Me(Nam)) And CStr(Val(Me(Nam))) = Me(Nam) And Me(Nam).Tag...
  7. RevJohn0584

    VBA code for filters

    Ok gentlemen, one last issue. It seems you have been able to rectify all of my issues....now to the final problem I have created with this: In the PN field, when I enter a pure number (much like I had before in the ShipDest issue), I get a data type mismatch error. i.e. 301154 causes this...
  8. RevJohn0584

    VBA code for filters

    joeflorendo - this is probably a huge newbie mistake - but I am seeing a major issue with this whole thing - it is linked directly to a table. When I type in lookup values and apply filters, it is working - however, when i go to type in the next value set, it changes the table! NOT GOOD! I...
  9. RevJohn0584

    VBA code for filters

    the clear filter works on the report (I can watch it change in the background), but the form still has values left in the cbo boxes. That is something I can deal with - I would prefer these also were de-populated when this is clicked, but no great tragedy if they are not. I believe that the PN...
  10. RevJohn0584

    VBA code for filters

    joeflorendo right on the money. that stopped the dialogue form popping up - however, it is still not filtering to expectation. i also have tested every cmd button on the form, and the clear filter button does not work as well. What can I do to help you help me (besides quit using Access =) )...
  11. RevJohn0584

    VBA code for filters

    The SQL statement: Design the report Get the form properties (right click the little black box where the rulers meet in the uper left of the report) On the all tab, the very first item is the recordsource. I am assuming this is a query. Design that query. Switch to SQL view by using the drop...
  12. RevJohn0584

    VBA code for filters

    Current code: Option Compare Database Private Sub cmdApplyFilter_Click() Dim Cri As String, x As Integer, Nam As String Dim strDelimeter As String For x = 1 To 4 Nam = "Filter" & x If Trim(Me(Nam) & "") <> "" Then If IsNumeric(Me(Nam)) And CStr(Val(Me(Nam)))...
  13. RevJohn0584

    VBA code for filters

    yes, thank you, I understand and and or functions. As stated earlier, I grabbed this directly from Microsoft...as i am a very new VBA user. However, it is always good to re-visit the basics in this manner, it allows that the foundation is correct and we are the same page. What I am shy on...
  14. RevJohn0584

    VBA code for filters

    Ok, we seem to have made progress.....when I filter using date and ship dest, works great. When I use PartNumb, FAIL! When I attempt to filter by PartNumb, it still does not show all of the records I know are there. This field also has the ability to have both numeric, alpha or a combination...
  15. RevJohn0584

    VBA code for filters

    sorry for the misnomer - filtering it is. Private Sub cmdApplyFilter_Click() Dim Cri As String, x As Integer, Nam As String Dim strDelimeter As String For x = 1 To 5 Nam = "Filter" & x If Trim(Me(Nam) & "") <> "" Then If IsNumeric(Me(Nam)) And Val(Me(Nam)) =...
  16. RevJohn0584

    VBA code for filters

    Also: When I type in a pure number into ShipDest, i get a "type mismtach" error....i.e. 03116 which is a ship code for a customer. My ship codes are as follows: 17419, AP04A, P025A, SSPO-1, etc. Varied numeric and aplha charcters in each, or all numeric, or in some cases, all aplha character.
  17. RevJohn0584

    VBA code for filters

    I have updated the code as lameid pointed out. That and removing the ? in the tag has opened a new doors - however =) Now the is working, but not as it should. When I sort by, say, ShipDest, it doesn't show the destination I know is there (i.e. P025A), or only a few of many (i.e. DTK3A), or...
  18. RevJohn0584

    VBA code for filters

    joeflando - the ShipDest can have any combination of alpha and numeric characters in it. i.e. AP04A or SSPO-1, etc. etc. Where would I put quotes around that value in the code?
  19. RevJohn0584

    VBA code for filters

    Click the button, hit ctrl+G and at the bottom copy the text in the bottom pane (immediate window) and post it here" PartNumb='100408K' AND ShipDest=08068 AND ShipDate=#8/3/2009# AND Printed?=-1 AND Supervisor='J. Skeen' I have removed the "Printed?" and made it "Printed". Still getting this...
  20. RevJohn0584

    VBA code for filters

    syntax error (missing operator) in query expression '(PartNumb = '100408K' AND ShipDest = 08068 AND ShipDate = #8/3/2009# AND Printed? = -1 AND Supervisor = 'J.Skeen')'. The ' is moving around =)

Part and Inventory Search

Back
Top