Quantcast
Channel: VBForums - Visual Basic .NET
Viewing all articles
Browse latest Browse all 27569

VS 2008 How to convert some simple lines into new ones.

$
0
0
Hello there,
Today I came here with a problem which I couldn't solve for long.

The problem is: I want to convert a link(a site actually) from old to new.

In example:

Code:

If TextBox1.Text.Contains("http://www.mysite.com/forum/index.php?topic=(Numbers)"

            TextBox2.Text = "http://www.mysite/archive/index.php?" & "topic=(here should appear Numbers from the textbox1.text topic=)"

I successfully converted the /forum/index.php? to /archive/index.php? but now I don't know how to make the topic=248786.0 to appear in the textbox2.text.

So, in simple words what I want is:

If I type: http://www.mysite.com/forum/index.php?topic=248786.0
it should be converted in: http://www.mysite/archive/index.php?topic=248786.0

NOTE: Each topic has its own unique numbers. XXXXX.X
So I need somehow to make it to identify the topic and paste the numbers in the textbox2.text

I thought of creating 2 texts boxes 1 for the http://www.mysite.com/forum/index.php? and 1 for the topic (topic=238786.0)
but it's too time consuming and I wouldn't prefer it.

Hope you can guys help me out, thanks!

Viewing all articles
Browse latest Browse all 27569

Trending Articles