Results 1 to 7 of 7

Thread: Little Help

  1. #1
    Join Date
    Mar 2008
    Location
    New Jersey
    Posts
    1,673
    Mentioned
    1 Post(s)
    Quoted
    9 Post(s)

    Default Little Help

    Sorry, this is probably a noobish question, but I been gone for a while and wanna start scripting again, but a little rusty. I wanna have the bank be searched for something and I wanna use GetBlackChatMessage to see if any results come back or not. How would I do it, I'm not really sure. Would it be something like:

    Code:
    if (GetBlackChatMessage = Search for '(whatever you searched for)' returned 0 results)
    or do you have to do something different with strings and not use = ? Help please, sorry, I can't think of how to do this.

  2. #2
    Join Date
    Jun 2007
    Location
    Wednesday
    Posts
    2,446
    Mentioned
    3 Post(s)
    Quoted
    1 Post(s)

    Default

    Assuming you have the right text and function, it would be:
    SCAR Code:
    if GetBlackChatMessage = 'Search for ' + searchString + ' returned 0 results' then
    With searchString being the string you searched for
    By reading this signature you agree that mixster is superior to you in each and every way except the bad ways but including the really bad ways.

  3. #3
    Join Date
    Mar 2008
    Location
    New Jersey
    Posts
    1,673
    Mentioned
    1 Post(s)
    Quoted
    9 Post(s)

    Default

    yea I know, I'd have to make searchstring a var or const and set it equal to what I'm searching for, I'm not a complete noob lol, just a little rusty, and ok that's what I was thinking last night but it was late and I was getting tired and for some reason I thought it might not work. and do you know how to put a ' in there because I forgot how to do it but I know you cant just put a ' in there because it's used to begin and end a string so you have to use a code.

  4. #4
    Join Date
    Mar 2007
    Posts
    3,042
    Mentioned
    1 Post(s)
    Quoted
    14 Post(s)

    Default

    Using a double apostrophe allows you to add one to the string.

    SCAR Code:
    MyString := 'It''s me!';
    :-)

  5. #5
    Join Date
    Mar 2008
    Location
    New Jersey
    Posts
    1,673
    Mentioned
    1 Post(s)
    Quoted
    9 Post(s)

    Default

    really? I didn't know that, that's pretty cool. has it always been like that?

  6. #6
    Join Date
    Nov 2007
    Location
    Chile
    Posts
    1,901
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Or:
    SCAR Code:
    String := 'I' + #39 + 'm'


  7. #7
    Join Date
    Mar 2008
    Location
    New Jersey
    Posts
    1,673
    Mentioned
    1 Post(s)
    Quoted
    9 Post(s)

    Default

    that's the way I used to know, thanks to both of you

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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