Wrox Programmer Forums
Go Back   Wrox Programmer Forums > C# and C > C# 1.0 > C#
C# Programming questions specific to the Microsoft C# language. See also the forum Beginning Visual C# to discuss that specific Wrox book and code.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the C# section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old November 7th, 2008, 10:06 PM
Registered User
Join Date: Oct 2008
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Default extracting multi-line text.

Im still fairly new at this im currently reading Beginning C# 2008 and have learned some basics on string manipulation.

I can look for text in a single line text box and extract set # of letters after it but I have no idea how to use that knowledge to accomplish the following objective.

I have a file thats got text pretty much all over the place its kind of chaotic however its got enough consistancy to where I know this can be accomplished.

some lines have the following: ["texthere"] = {

other lines have [rank] = "texthere",

they alternate, so I want to search for [" and grab all text until "] = { then I want to continue until find a line with [rank] = " and grab all text until ",

Edit: Apparently the knowledge I have is enough to handle this task...sort of. Im finding the index of [" and then the index of "] using that info to grab the text from inside then deleting the text. Since I have no idea how to find the next result without deleting the text.

Similar Threads
Thread Thread Starter Forum Replies Last Post
Extracting a flexibel amount of text part 2 jmaronilla PHP Databases 0 July 28th, 2008 08:22 PM
Regular Expression Validator on Multi-Line TextBox wagswvu General .NET 1 June 4th, 2008 09:24 AM
Help extracting text from a regular expression crazymanju BOOK: Beginning Regular Expressions 0 April 10th, 2007 05:43 AM
Extracting Text Jeff Mason BOOK: Beginning Regular Expressions 1 October 24th, 2006 06:38 AM
Extracting text between tags aware Classic ASP Professional 4 December 24th, 2003 04:25 AM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.