What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » RegExp help/Alternative?

RegExp help/Alternative?
Author: Message:
ArkaneArkade
Full Member
***

Avatar
The One and Only

Posts: 193
Reputation: 5
38 / Male / Flag
Joined: Mar 2007
O.P. RegExp help/Alternative?
Hey guys, as always, stuck again.
I'm trying to sort out some information from a CurrentMedia string using RegExp, but I'm nowhere near good enough at it (or understand it well enough).

code:
XBOXMSGR\0Game\01\0{0}: {1} ({2})\0Xbox 360\0Game Name\0GamerTag\0Web-Link\066262\0\0
code:
ITunes\0Music\01\0{0} - {1}\0Song\0Artist\0Album\0"

Both of these strings are taken from different Media strings by different (yet default MS) apps.  Both of them have different numbers of dividers (the "\0") and I think this is where my problems are occurring.
I was trying to use a function to retrive the information, but because I'm unsure how to make each section optional I can't get it to retrieve the final sections without stopping it working.

Lastly (I know, taking liberties now) I'd like to know if there is a way to return multiple values, so that I could set up the function to get the information I need

For example, after running the RegExp, is there a way to return $1, $2, $3, falling back onto $1, $2 if there is no $3 (etc all the way up to the 10 or whatever the value is).  The on the other end, to get just the one I want from the function (ie if the function is RunReg(), to do something such as "var variable = RunReg(2) to retrieve the second value?

can anyone help me with any of this?  I would be extremely grateful...
Cheers guys
Leroux
[Image: adsig.jpg]
01-12-2009 02:39 AM
Profile E-Mail PM Web Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
RegExp help/Alternative? - by ArkaneArkade on 01-12-2009 at 02:39 AM
RE: RegExp help/Alternative? - by Spunky on 01-12-2009 at 03:00 AM
RE: RE: RegExp help/Alternative? - by ArkaneArkade on 01-12-2009 at 03:32 AM
RE: RegExp help/Alternative? - by Spunky on 01-12-2009 at 03:44 AM


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On