Zum Inhalt springen
View in the app

A better way to browse. Learn more.

Fachinformatiker.de

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

[vb.net] HttpRequest/Response

Empfohlene Antworten

Veröffentlicht

Servus

Also.. Es geht darum, mittels HttpRequest/Response auf eine Seite ein PostFormular abzuschicken. Was ich hier versucht habe, allerdings scheint damit was nicht zu stimmen (Wenn ich 2. Brwoser öffne und auf die Seite gehe, muss ich mich trotzdem einloggen, was der Code eigentlich hätte machen sollen)


    Dim strUrl As String = "url"

    Dim username As String = "name"

    Dim password As String = "password"

    Dim encoding As ASCIIEncoding = New ASCIIEncoding()

    Dim postData As String = "name=" + username

    postData += "&password=" + password


    Dim data() As Byte = encoding.GetBytes(postData)


    'Prepare web request... 

    Dim myRequest As HttpWebRequest = WebRequest.Create(strUrl)


    With myRequest

      .Method = "POST"

      .ContentType = "application/x-www-form-urlencoded"

      .ContentLength = data.Length

    End With


    Dim newStream As Stream = myRequest.GetRequestStream

    ' Send the data. 



    newStream.Write(data, 0, data.Length)

    newStream.Close()

Das wäre der 1. Teil.

Hätte noch wer Tips wie ich dann noch folgendes umsetzten kann?

Nach erfolgreichem Login eine bestimmte Url Aufrufen und in dieser dann einen Wert Raussuchen.

Das Problem bei dem 2. Teil ist im Moment immer, das die SessionID verloren geht. Hat jemand bei sowas schon Erfahrung?

MfG

Archiv

Dieses Thema wurde archiviert und kann nicht mehr beantwortet werden.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.