Can someone please compile a really simple program for me?
Author |
Message |
GlobeTrotter
|
Posted: Sat Apr 08, 2006 3:01 pm Post subject: Can someone please compile a really simple program for me? |
|
|
I would really appreciate it if someone could compile this and upload it. Not really sure why, but I can't use some controls (eg. Inet).
Could someone please great a form, drag on an Inet control and then simply paste this into its code.
code: |
Private Sub Form_Load()
Dim strWebAddress As String
Dim strOutputFile As String
Dim strSource As String
Dim ArrArguments() As String
ArrArguments = Split(Command, "|")
If UBound(ArrArguments) = 1 Then
strWebAddress = Trim(ArrArguments(0))
strOutputFile = Trim(ArrArguments(1))
If Mid(strWebAddress, 1, 1) = Chr(34) And Right$(strWebAddress, 1) = Chr(34) Then
strWebAddress = Mid(strWebAddress, 2, Len(strWebAddress) - 2)
End If
If Mid(strOutputFile, 1, 1) = Chr(34) And Right$(strOutputFile, 1) = Chr(34) Then
strOutputFile = Mid(strOutputFile, 2, Len(strOutputFile) - 2)
End If
strSource = Inet1.OpenURL(strWebAddress)
Open strOutputFile For Output As #1
Print #1, strSource
Close #1
End If
End
End Sub
|
Thanks.
It's just a program that takes command line arguments to download a certain HTML source code and print it to a certain file.
|
|
|
|
|
![](images/spacer.gif) |
Sponsor Sponsor
![Sponsor Sponsor](templates/subSilver/images/ranks/stars_rank5.gif)
|
|
![](images/spacer.gif) |
cool dude
![](http://www.taylorstrategicmarketing.com/images/king.jpg)
|
Posted: Sat Apr 08, 2006 5:40 pm Post subject: (No subject) |
|
|
can't u just upload your form here?
|
|
|
|
|
![](images/spacer.gif) |
GlobeTrotter
|
Posted: Sat Apr 08, 2006 5:55 pm Post subject: (No subject) |
|
|
Theoretically, I could, but:
A: there would be nothing on the form, so someone may as well just start a new project.
B: someone would still have to drag the control onto the form, since I can't.
Therefore, there I see no advantage to uploading a blank form, which simply has some code, when I could just post the code.
|
|
|
|
|
![](images/spacer.gif) |
Brightguy
![](http://compsci.ca/v3/uploads/user_avatars/527435178485ad4c287538.gif)
|
Posted: Thu Apr 13, 2006 9:12 pm Post subject: Re: Can someone please compile a really simple program for m |
|
|
Ok, give it a try...
|
|
|
|
|
![](images/spacer.gif) |
GlobeTrotter
|
Posted: Thu Apr 13, 2006 10:25 pm Post subject: (No subject) |
|
|
Thank you very much!
|
|
|
|
|
![](images/spacer.gif) |
|
|