Click here to Skip to main content
15,892,809 members

Comments by Yatin Bhagat (Top 27 by date)

Yatin Bhagat 10-Nov-11 4:23am View    
Dim url As String = Me.txtUrl.Text.Trim()
Dim port As String = Me.txtPort.Text.Trim()

'If the port was provided, then insert it into the url.
If port <> "" Then

'Insert the port into the Url
'https://www.example.com:80/fileToDownload.dat
Dim u As New Uri(url)

'Get the host (example: www.example.com)
Dim host As String = u.Host

'Replace the host with the host:port
url = url.Replace(host, host & ":" & port)

End If


'Create the request
Dim request As HttpWebRequest = _
DirectCast(System.Net.HttpWebRequest.Create(url), HttpWebRequest)

'Set the User Name and Password
request.Credentials = New NetworkCredential(Me.txtUserName.Text.Trim(), Me.txtPassword.Text.Trim())
request.Method = WebRequestMethods.Http.Get



Dim response As HttpWebResponse = Nothing

Try
'Get the response
response = DirectCast(request.GetResponse(), HttpWebResponse)

Catch ex As Exception

MessageBox.Show("An error occurred while attempting to retrieve data from the remote server. " & _
"The following error occurred while attempting to retrieve the data:" & vbCrLf & vbCrLf & _
ex.Message)

End Try


this is my code and it will show messeage 'Remote Server Not responding'
Yatin Bhagat 14-Sep-11 6:07am View    
i have created a seperate class for database operations only
Yatin Bhagat 1-Jul-11 6:04am View    
Deleted
it will not sort dates by dt.DefaultView.Sort
Yatin Bhagat 7-May-11 1:20am View    
actully i am not reffring any web site,i have designed my own html file and placed it in root directory,in this what should be the steps???
Yatin Bhagat 21-Apr-11 8:54am View    
like it!!!!!
my clients use a dos based software developed in foxpro and they the flow is very fast on arrow keys and enter key...and they got habbited of using that way....so place such kind of requirments