Results 1 to 14 of 14
  1. #1
    planick36 is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Nov 2016
    Posts
    6

    Macro didin't work properly

    Hi,

    I am new to this forum and access 2010. I have created a table in which I imported an Excel file (it included all the info I needed). I have also created a query and a form. I used the Split Form, so far so good. I added a Text Search Field and a Search button. I chose the Search button, clicked on it, chose macro but somehow I couldn't make it work with two statements in Where Condition.

    For example: the code I wrote in Where condition was [COMPANY] Like "*" & [Forms]![qr-BWTS]![Text87] & "*"

    When this code was by itself it worked great but when I added a second statement it ignored the second one and didn't show any results.

    For example: [COMPANY] Like "*" & [Forms]![qr-BWTS]![Text87] & "*" Or [STATUS] Like "*" & [Forms]![qr-BWTS]![Text87] & "*" ignored the "Or" statement and didin't return anything when I typed something from the STATUS field...

    I did one more thing which was that: I deleted the second statement and I left the first one, only I replaced COMPANY with STATUS. It didn't work either!!!

    The macro was: [STATUS] Like "*" & [Forms]![qr-BWTS]![Text87] & "*"

    COMPANY is the second column (first is the ID) and STATUS is the 12th column... Something wrong with the macro or the columns ?



    Any help would be really appreciated

  2. #2
    CJ_London is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,412

  3. #3
    Micron is offline Virtually Inert Person
    Windows 7 32bit Access 2007
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,793
    Ajax, that link doesn't seem to work.

    Planck36, as a newcomer, I'd advise you to read this
    http://www.excelguru.ca/content.php?184
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  4. #4
    planick36 is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Nov 2016
    Posts
    6
    Gee... My question is very specific so why are you sending me these irrelevant replies?

    I would appreciate a solution to the problem I mentioned above, do not leave meaningless messages.

    Thank you

  5. #5
    CJ_London is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,412
    works for me!

    I didn't include the excelguru link since OP has been advised on the other thread. Seems like the OP isn't bothered about wasting peoples time, so I shan't be bothering to try to answer his question

  6. #6
    planick36 is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Nov 2016
    Posts
    6
    How genuine!

  7. #7
    Micron is offline Virtually Inert Person
    Windows 7 32bit Access 2007
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,793
    Quote Originally Posted by planick36 View Post
    Gee... My question is very specific so why are you sending me these irrelevant replies?

    I would appreciate a solution to the problem I mentioned above, do not leave meaningless messages.

    Thank you
    Well, the link doesn't work for me thus I has no idea you were already called out for cross posting. Let's see how much help your attitude gets you here. You can have the last word.
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  8. #8
    planick36 is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Nov 2016
    Posts
    6
    Another irrelevant reply.

    Well genius, I left a question seeking for a solution to my problem. A very kind and speific message. All I got was irrelevant replies with attitude. Since you replied with an attitude, attitude you will get. Being ops of a forum doesn't mean you must insult or do whatever you like...

    The wise thing would be not to reply since you don't have the answer

  9. #9
    planick36 is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Nov 2016
    Posts
    6
    Have dealt with rude ops before. No wonder why forums are dying these days

  10. #10
    ssanfu is offline Master of Nothing
    Windows XP Access 2010 32bit
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    @Ajax, the link didn't work for me either.

    @Micron, Agree with you about the attitude. Amazing how letting some people know about forum etiquette makes them get..... well, Pissy!
    They want help but don't want to understand WHY double posting wastes time.


    @planick36, At a minimum 3 of us know the answer to your question, but I'm not going to waste my time because of the attitude. Good luck.......

  11. #11
    CJ_London is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,412
    the link didn't work for me either
    @Micron/Ssanfu

    Determined the reason is the OP has deleted the thread which is allowed on the other forum.

  12. #12
    planick36 is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Nov 2016
    Posts
    6
    I deleted the post on the other forum not the op, since you know the answer and don't tell me shows you have no respect to the readers and strengthens my opinion you have the so called attitude. That's what I was talking about.

  13. #13
    CJ_London is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,412
    This forum (most if not all forums) is a community who help for free, not a business. If you want to be rude and demanding, go to a resource where you pay for the help - our price is simply an understanding for how the community works. This forum has nearly 50,000 members. Of these perhaps 1 or 2% are online at any one time. And of these perhaps 2 or 3% are regular responders who have a wide and deep understanding of Access and related apps. Twice you have been advised how the community works and rather than acknowledge that you become insulting. So please explain what is your contribution to this community and why we should help you?

    There is a saying 'when you are in a hole, stop digging'. Suggest this is the time to stop digging and climb back out the hole and start again.

  14. #14
    ssanfu is offline Master of Nothing
    Windows XP Access 2010 32bit
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    @planick36, This is in response to the PM you sent me.

    For clarity, OP is shorthand for "Original Poster" (ie who started the thread), just as PM is shorthand for "Private Message".

    OK, your first post in this forum was when you asked your question. It is highly probable that you were unaware of forum etiquette.

    There are many responders in this forum that monitor many other Access forums. When Ajax responded that the question was cross-posted on the access-programmers.co.uk forum, it was to let everyone know to check the other forum to see if there was an answer there, BEFORE they wasted their time responding to an already answered question.

    Then Micron responded with a link to the excelguru.ca site to let you know why cross-posting is frowned upon. You CAN still post (ask the question) on both forums, just put a link/comment to the other form so everyone knows about the other forum.


    Your responses WERE rude. You never acknowledged reading the "ExcelGuru" link!!! The following are your responses (highlighting/color is mine):
    In Post #4
    Quote Originally Posted by planick36 View Post
    Gee... My question is very specific so why are you sending me these irrelevant replies?

    I would appreciate a solution to the problem I mentioned above, do not leave meaningless messages.

    Thank you
    In Post #6
    Quote Originally Posted by planick36 View Post
    How genuine!
    In Post #8
    Quote Originally Posted by planick36 View Post
    Another irrelevant reply.

    Well genius, I left a question seeking for a solution to my problem. A very kind and speific message. All I got was irrelevant replies with attitude. Since you replied with an attitude, attitude you will get. Being ops of a forum doesn't mean you must insult or do whatever you like...

    The wise thing would be not to reply since you don't have the answer

    My post
    Quote Originally Posted by ssanfu View Post
    <snip>
    @planick36, At a minimum 3 of us know the answer to your question, but I'm not going to waste my time because of the attitude. Good luck.......
    was referring to Ajax, Micron and me. Look at the total number of posts between us - over 10,000 posts over many years on this forum!


    As Ajax stated: the responders on the forums are volunteers, trying to give back what they have learned from earlier volunteers.

    It would have been so much better if you had responded with something like: "Thanks for the link (to excelguru). I didn't know."
    Rude posters, or perceived rude posters, tend NOT to get answers.
    IRL, do you help people that are rude to you????

    Maybe read Post # 13 a couple more times???


    Again, Good luck with your project...

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 5
    Last Post: 06-09-2015, 08:45 PM
  2. Append doesn't work properly
    By fluppe in forum Access
    Replies: 3
    Last Post: 10-17-2014, 12:50 AM
  3. Replies: 10
    Last Post: 11-20-2013, 04:18 PM
  4. Combo box doesn't work properly
    By joe1987 in forum Forms
    Replies: 9
    Last Post: 11-10-2011, 04:34 PM
  5. 2007 to 2010 macro won't work
    By lmnnt in forum Programming
    Replies: 6
    Last Post: 08-10-2011, 01:55 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums