I first had an interest in VB6, it wasn't a very good relationship. She was one of those types your mom tells you not to hang around with, always teaching bad things. I graduated from VB6 onto VB.net, it was one of those short relationships. It lasted maybe a couple of weeks, until I was smitten by C#. C#, now that was love at first sight. We met about 6 years ago I believe, and I have been head over heels in love with her ever since. Although I am pretty sure it is a one sided love. :((
C
Cardon Fry
@Cardon Fry
Posts
-
First True Love? -
getting data from internetIf I am understanding the question right he will also need a GetStringInBetween method.
public static string[] GetStringInBetween(string strBegin, string strEnd, string strSource, bool includeBegin, bool includeEnd)
{
string[] result = { "", "" };
int iIndexOfBegin = strSource.IndexOf(strBegin);
if (iIndexOfBegin != -1)
{
if (includeBegin)
{ iIndexOfBegin -= strBegin.Length; }
strSource = strSource.Substring(iIndexOfBegin
+ strBegin.Length);
int iEnd = strSource.IndexOf(strEnd);if (iEnd != -1) { if (includeEnd) { iEnd += strEnd.Length; } result\[0\] = strSource.Substring(0, iEnd); if (iEnd + strEnd.Length < strSource.Length) { result\[1\] = strSource.Substring(iEnd + strEnd.Length); } } } else { result\[1\] = strSource; } return result;
}
It is a very generic method you can find it anywhere on the internet, because why would you reinvent the wheel.
-
Something I've been thinking about recently...I take and art class and I play the violin.