Paypal button in VB 2010. RRS feed

  • Question

  • Hi, I'm looking to add a Paypal button to one of my forms in VB.NET 2010.  I have the following code


    <form action="https://www.paypal.com/cgi-bin/webscr" method="post">

    <input type="hidden" name="cmd" value="_s-xclick">

    <input type="hidden" name="hosted_button_id" value="9DEYCYTRCA7YW">

    <input type="image" src="https://www.paypal.com/en_GB/i/btn/btn_paynowCC_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online.">

    <img alt="" border="0" src="https://www.paypal.com/en_GB/i/scr/pixel.gif" width="1" height="1">


    How can I place this HTML code into a VB.NET form?

    Any help would be welcomed.

    Tuesday, November 2, 2010 11:46 AM


  • Hi philipfox,

    You should rely on the System.Net.HttpWebRequest class. Populate it's properties to model the post method and the values that are need to be sent. Then call the GetResponseStream() to send your request and get a reference to a NetworkStream to read the response of your request.


    Hope this helps



    Matteo Marcianò ByteStorms
    • Proposed as answer by Chao Kuo Friday, November 5, 2010 7:09 AM
    • Marked as answer by Chao Kuo Tuesday, November 9, 2010 10:03 AM
    Tuesday, November 2, 2010 12:03 PM