版权声明: https://blog.csdn.net/eds124/article/details/85842057
Partial Class _Default
Inherits System.Web.UI.Page
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
Response.Cookies("login")("username") = "aaa"
Response.Cookies("login")("password") = "bbb"
Request.Cookies.Clear()
Dim hc As HttpCookie = Request.Cookies("login")
'Dim s As String = Request.Cookies("login").ToString()
If Nothing IsNot hc Then
Dim username As String = hc("username").ToString()
Dim password As String = hc("password").ToString()
Response.Write(username)
Response.Write(password)
End If
End Sub
End Class