|
-
Aug 1st, 2012, 01:25 PM
#1
Thread Starter
Hyperactive Member
[RESOLVED] Parsing String to match my Pattern
I am developing a client/server application.
How can I parse a string (message from client) to match with my required string pattern.
Let say my pattern required is:
RESULT Acct. Number Year Part
Sample: RESULT 1063-12 2012 1st
I need to check incoming message if it is in correct format. if not correct my server will reply a correction message.
Server must accept correct format of message only. Coz strings from message is use to query my database for reply of result.
I have no initial code for now here. Im just wondering an idea now how to do it in a code.
I'm thinking if it is best to use regex split or match.
Anyone have sample of working code using regex?
Im also googling it now.
Thanks.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|