FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


Visual Basic Problem





fromegame
Hello,

I'm making a program (how surprising..) and I need to get a webpage with it.

I do this using this:
Code:

    Public Function GetPageHTML( _
           ByVal URL As String) As String
        ' Retrieves the HTML from the specified URL
        Dim objWC As New System.Net.WebClient()
        Return New System.Text.UTF8Encoding().GetString( _
           objWC.DownloadData(URL))
    End Function


The program gets the page, and I split the page in pieces, because then I have the pieces that I need Smile

After a few splits I have this left:

Code:

<td>
TEXTINEED</td>


I split the </td> of:

Code:

<td>
TEXTINEED


Then I split the <td> of....

Code:


TEXTINEED


Then:

Code:

            If (MYNEEDEDTEXT = "xxxxxx") Then
                asfdsadf = "ljgaeihioupqe"
            End If


Well, I think you can see the problem, there's still a new line (return, enter whatever) out there.

Now my question: How can I split this new line out of the string Sad ?
fromegame
Really no one can answer Crying or Very sad?
fromegame
Solved!

I use this:
Code:
if(myString.Contains("xxx") = True) Then


This can be -closed-
Related topics
Visual Basic Build Problem
Visual Basic Tutorial - Control Arrays: What, Why and How
help me ..,.,about visual basic
VB 6 problem executing a .exe program via a visual basic app
Visual Basic RUles
Visual Basic 6 vs Visual Basic 2010
Microsoft Visual Basic help
C#,Visual Basic.NET,Visual Studio.NET Videos
visual basic.net
MS Visual Basic Studio 2005 Express Edition
Visual Basic Tutorial - File I/O in VB: Text Files
Visual Basic Tutorial - Looping
Visual Basic Express Addition
Visual Basic programming tutorial
Reply to topic    Frihost Forum Index -> Scripting -> Others

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.