|
-
Jan 14th, 2000, 04:40 AM
#1
I am trying to get the html source code of a webpage and put it in a text box. The problem is the text box doesn't hold it all. It gets cut off. Anyone know how to either get all of the info into a spot where i can search through it all or how to take chunks of the source code off of the webpage?
-
Jan 14th, 2000, 04:44 AM
#2
Hyperactive Member
As far I remember, a normal text box only holds 255 chars, this is probably the problem you're having.
-
Jan 14th, 2000, 04:49 AM
#3
then how can i get around this problem?
I am using:
Text1.Text=Inet1.OpenURL("mywebsite.com")
to get the source code is there a way to either write the code to a file directly so i get it all or is there a way extract it by parts from the web page source code?
-
Jan 14th, 2000, 04:49 AM
#4
actually a textbox holds i believe up to 65k but with html source this can be exceeded quickly. make sure you set the multiline property equal to true(then set the scrollbars so you can scroll, I would used the Rich Text Box though as it holds WAY more than the textbox control and it's default is multiline = true.
-
Jan 14th, 2000, 04:51 AM
#5
actually i think when i used a rtb it held less. i think.
-
Jan 14th, 2000, 04:59 AM
#6
i need it to hold about 37 kb worth of source code, and i retract my last statement about the rtb
-
Jan 14th, 2000, 05:14 AM
#7
Lively Member
Hi dmartin17,
I found this in MSDN Help in VB. I haven't tried it, but it should work. It writes the source code to a text file:
Code:
Dim strURL As String ' URL string
Dim intFile As Integer ' FreeFile variable
IntFile = FreeFile()
strURL = "http://www.microsoft.com"
Open "c:\temp\MSsource.txt" For Output _
As #IntFile
Write #IntFile, Inet1.OpenURL(strURL)
Close #IntFile
HTH.
Chris
[This message has been edited by ChrisJackson (edited 01-14-2000).]
-
Jan 14th, 2000, 08:21 AM
#8
ok ive tried writing directly to a file ive also tried using a rich text box and a regular text box. the bottem line is that it never gets the entire amount of source code, it always stops before finishing.
any other suggestions on was to get the source code? I need to search through it for specific words and numbers? please let me know
-
Jan 14th, 2000, 08:23 AM
#9
ok ive tried writing directly to a file ive also tried using a rich text box and a regular text box. the bottem line is that it never gets the entire amount of source code, it always stops before finishing.
any other suggestions on was to get the source code? I need to search through it for specific words and numbers? please let me know
-
Jan 14th, 2000, 10:42 PM
#10
Addicted Member
i got a ideal make it where it saves to it own file like something.web cuase usaly that might make it be bigger try it and see
-
Jan 14th, 2000, 11:58 PM
#11
hi,
i had the same problem. i think u use the MSINET ocx, right ?
-
Jan 15th, 2000, 03:01 AM
#12
Ive tried all of these thigns but for some reason i can not get all of the text. Thanks for the help. i still just cant get it to work.
-
Jan 15th, 2000, 12:33 PM
#13
Guru
from MSDN:
the RichTextBox control doesn't have the same 64K character capacity limit of the conventional TextBox control.
-
Jan 16th, 2000, 09:26 PM
#14
I still have had no success with this anymore ideas?
-
Jan 16th, 2000, 09:39 PM
#15
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|