Results 1 to 5 of 5

Thread: Is it possible to create a VBA code that would recognize phrases out of context ?
Thanks Thanks: 0 Likes Likes: 0

  1. #1
    Board Regular
    Join Date
    Jun 2018
    Posts
    53
    Post Thanks / Like
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Default Is it possible to create a VBA code that would recognize phrases out of context ?

    So far I know how to extract certain words and potentially even match it into phrases without using VBA, but it is very crippled.
    But is it possible to teach/have VBA recognize the phrases out of text.

    Example: we need to recognize when paper was not in stock

    I went to store and did not find paper in stock
    I went to store: paper was out of stock
    I went to store and no paper in stock
    No paper found in stock. I had to go to another store.

    As you see we cannot just rely on finding "paper not in stock". And there are hundreds and thousands more records, that have nothing to do with paper not being stock, but can also have something else not in stock, or have paper but being used or obtained.

    You can assume some other data like: only certain stocks have a paper, thus other stocks cannot have this phrases. But don't narrow it down to being very specific, as we still need to have VBA be able to recognize the phrase out of context.


    Is there any other way to teach VBA recognize times when there is no paper in stock ?

    Thank you

  2. #2
    MrExcel MVP
    Moderator
    Fluff's Avatar
    Join Date
    Jun 2014
    Location
    Chippenham
    Posts
    28,177
    Post Thanks / Like
    Mentioned
    470 Post(s)
    Tagged
    47 Thread(s)

    Default Re: Is it possible to create a VBA code that would recognize phrases out of context ?

    There's no simple way that I know of to do something like this, so I think that you are out of luck.
    Adding to your examples, how would this be treated.
    I went to store and bought my paper but yours was out of stock
    That would be both a true & false.
    - Posting Data try one of these tools
    - Posting guidelines, forum rules and terms of use
    - Read the FAQs

    Running Office 365 on Win 10

  3. #3
    Board Regular
    Join Date
    Jun 2018
    Posts
    53
    Post Thanks / Like
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Default Re: Is it possible to create a VBA code that would recognize phrases out of context ?

    Yeah, I was suspecting something like that, but still decided to try my luck
    Thank you for letting me know though.

  4. #4
    MrExcel MVP
    Moderator
    Fluff's Avatar
    Join Date
    Jun 2014
    Location
    Chippenham
    Posts
    28,177
    Post Thanks / Like
    Mentioned
    470 Post(s)
    Tagged
    47 Thread(s)

    Default Re: Is it possible to create a VBA code that would recognize phrases out of context ?

    You're welcome
    - Posting Data try one of these tools
    - Posting guidelines, forum rules and terms of use
    - Read the FAQs

    Running Office 365 on Win 10

  5. #5
    MrExcel MVP mikerickson's Avatar
    Join Date
    Jan 2007
    Location
    Davis CA
    Posts
    22,591
    Post Thanks / Like
    Mentioned
    20 Post(s)
    Tagged
    15 Thread(s)

    Default Re: Is it possible to create a VBA code that would recognize phrases out of context ?

    You could identify those phrases have one or more of these conditions ("paper" and "not") or ("paper and "no") or ("paper" "stock" and "no"). (Consider the sentence "No problem, we have paper in stock")

    As Fluff alluded to, how complex are the sentences that you are looking at.

Some videos you may like

User Tag List

Tags for this Thread

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •