Latest Tutorials| Questions and Answers|Ask Questions?|Site Map



Home Answers Viewqa Java-Beginners Regular Expression Help Help HELP!!!!
Login         

View Questions and Answers by Category

Advertisements


 
Have Programming Question? Ask it here!
 
 
 


harish
Regular Expression Help Help HELP!!!!
0 Answer(s)      4 years and 4 months ago
Posted in : Java Beginners


HI all

I am very new to java, but i have this problem i got a string e.g

Courses['07001'].Title = "International Students 1";

So i need to extract only the "international Students", i did that by using this expression String regex = "Courses\[\'[^\']+\'\]\.Title *= *\"([^\"]+)\";";

But the problem now is, say i got string like

Courses['07001'].CO = new Array("MR","","Harish Ram","Not Available","M.R Harish","hotmail.com");

so i need to extract"07001", "MR Harish Ram " and extract "M.RHarish @ hotmail.com" note that i need to add the @ when compiling. got any ideas if you could help me to give a solution of how to retrieve the name and email add seperately...

So my final output should look in the form given below and including the quotes

""07001", "MR Harish Ram","M.RHarish @ hotmail.com""

Help is greatly appreciated

Thanks in advance!!!!!

Please Help!!

harish


Advertisement
View Answers

Related Tutorials/Questions & Answers:
Advertisements
 

 

 

DMCA.com