Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!
Imports System.IO Imports System.Net Partial Class response Inherits System.Web.UI.Page Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load Dim strDataToPost As String Dim myWebRequest As WebRequest Dim myRequestStream As Stream Dim myStreamWriter As StreamWriter Dim myWebResponse As WebResponse Dim myResponseStream As Stream Dim myStreamReader As StreamReader ' Create a new WebRequest which targets that page with which we want to interact. myWebRequest = WebRequest.Create("response.aspx") ' Set the method to "POST" and the content type so the server knows to expect form data in the body of the request. With myWebRequest .Method = "POST" .ContentType = "application/x-www-form-urlencoded" End With myResponseStream = myWebResponse.GetResponseStream() myStreamReader = New StreamReader(myResponseStream) Dim FILENAME As String = Server.MapPath("TextFile.txt") File.Delete(FILENAME) Dim objStreamWriter As StreamWriter objStreamWriter = File.AppendText(FILENAME) objStreamWriter.WriteLine(myStreamReader.ReadToEnd()) objStreamWriter.Close() myStreamReader.Close() myResponseStream.Close() ' Close the WebResponse myWebResponse.Close() End Sub
|Needing an event fired when a row is added on a datagridview||4||36|
|vb.net - How to check if current user is an administrator?||6||34|
|how to read json value||2||31|
|Need help with setting the location of a Navigate.URL for an asp.net web form.||4||10|
Join the community of 500,000 technology professionals and ask your questions.
Connect with top rated Experts
14 Experts available now in Live!