Posting data to another application in ASP.NET 2.0

Discussion in 'ASP .Net Web Controls' started by Peter Afonin, Jan 7, 2007.

  1. Peter Afonin

    Peter Afonin Guest

    Hello,

    I have a form with several buttons, and I need to post this data to several
    different applications. In ASP.NET 1.1 it was quite easy - I just used HTML
    controls (text or hidden), then assigned the action to each button on
    Page_Load event:

    Me.ibPayWM.Attributes.Add("onclick",
    "noPostBack('https://merchant.webmoney.ru/lmi/payment.asp');")
    Me.ibPayRx.Attributes.Add("onclick",
    "noPostBack('https://www.roboxchange.com/ssl/calc.asp');")
    Me.ibPayRupay.Attributes.Add("onclick",
    "noPostBack('http://www.rupay.com/rupay/pay/index.php');")

    I thought that in ASP.NET 2.0 this should be even much easier, because each
    button has PostBackUrl property. However, it seems that I can use this
    property to post data only within my application, because the page I'm
    posting data to has to use PreviousPage property.

    The method I was using in ASP.NET 1.1 also doesn't seem to be working, for
    some reason I'm posting data to the same page.

    So now I'm stuck - how to post the data to another application in ASP.NET
    2.0?

    I would appreciate your advice.

    Thank you,

    --
    Peter Afonin
     
    Peter Afonin, Jan 7, 2007
    #1
    1. Advertising

  2. Why the x-posting?

    --
    Regards,
    Alvin Bruney
    ------------------------------------------------------
    Shameless author plug
    Excel Services for .NET is coming...
    OWC Black book on Amazon and
    www.lulu.com/owc

    "Peter Afonin" <> wrote in message
    news:...
    > Hello,
    >
    > I have a form with several buttons, and I need to post this data to
    > several different applications. In ASP.NET 1.1 it was quite easy - I just
    > used HTML controls (text or hidden), then assigned the action to each
    > button on Page_Load event:
    >
    > Me.ibPayWM.Attributes.Add("onclick",
    > "noPostBack('https://merchant.webmoney.ru/lmi/payment.asp');")
    > Me.ibPayRx.Attributes.Add("onclick",
    > "noPostBack('https://www.roboxchange.com/ssl/calc.asp');")
    > Me.ibPayRupay.Attributes.Add("onclick",
    > "noPostBack('http://www.rupay.com/rupay/pay/index.php');")
    >
    > I thought that in ASP.NET 2.0 this should be even much easier, because
    > each button has PostBackUrl property. However, it seems that I can use
    > this property to post data only within my application, because the page
    > I'm posting data to has to use PreviousPage property.
    >
    > The method I was using in ASP.NET 1.1 also doesn't seem to be working, for
    > some reason I'm posting data to the same page.
    >
    > So now I'm stuck - how to post the data to another application in ASP.NET
    > 2.0?
    >
    > I would appreciate your advice.
    >
    > Thank you,
    >
    > --
    > Peter Afonin
    >
     
    Alvin Bruney [MVP], Jan 8, 2007
    #2
    1. Advertising

  3. Peter Afonin

    Peter Afonin Guest

    Alvin, what do you mean - why?

    I have a form with several buttons and I have to post this data to the
    different applications. I'm afraid I don't understand your question.

    Thank you,

    Peter


    "Alvin Bruney [MVP]" <some guy without an email address> wrote in message
    news:...
    > Why the x-posting?
    >
    > --
    > Regards,
    > Alvin Bruney
    > ------------------------------------------------------
    > Shameless author plug
    > Excel Services for .NET is coming...
    > OWC Black book on Amazon and
    > www.lulu.com/owc
    >
    > "Peter Afonin" <> wrote in message
    > news:...
    >> Hello,
    >>
    >> I have a form with several buttons, and I need to post this data to
    >> several different applications. In ASP.NET 1.1 it was quite easy - I just
    >> used HTML controls (text or hidden), then assigned the action to each
    >> button on Page_Load event:
    >>
    >> Me.ibPayWM.Attributes.Add("onclick",
    >> "noPostBack('https://merchant.webmoney.ru/lmi/payment.asp');")
    >> Me.ibPayRx.Attributes.Add("onclick",
    >> "noPostBack('https://www.roboxchange.com/ssl/calc.asp');")
    >> Me.ibPayRupay.Attributes.Add("onclick",
    >> "noPostBack('http://www.rupay.com/rupay/pay/index.php');")
    >>
    >> I thought that in ASP.NET 2.0 this should be even much easier, because
    >> each button has PostBackUrl property. However, it seems that I can use
    >> this property to post data only within my application, because the page
    >> I'm posting data to has to use PreviousPage property.
    >>
    >> The method I was using in ASP.NET 1.1 also doesn't seem to be working,
    >> for some reason I'm posting data to the same page.
    >>
    >> So now I'm stuck - how to post the data to another application in ASP.NET
    >> 2.0?
    >>
    >> I would appreciate your advice.
    >>
    >> Thank you,
    >>
    >> --
    >> Peter Afonin
    >>

    >
    >
     
    Peter Afonin, Jan 8, 2007
    #3
  4. You posted this to at least two newsgroups, you only need to post a question
    to one newsgroup.

    If you post to a page using 'https://merchant.webmoney.ru/lmi/payment.asp'
    i'm not sure why it would not go to that page. What error are you seeing?

    --
    Regards,
    Alvin Bruney
    ------------------------------------------------------
    Shameless author plug
    Excel Services for .NET is coming...
    OWC Black book on Amazon and
    www.lulu.com/owc

    "Peter Afonin" <> wrote in message
    news:...
    > Alvin, what do you mean - why?
    >
    > I have a form with several buttons and I have to post this data to the
    > different applications. I'm afraid I don't understand your question.
    >
    > Thank you,
    >
    > Peter
    >
    >
    > "Alvin Bruney [MVP]" <some guy without an email address> wrote in message
    > news:...
    >> Why the x-posting?
    >>
    >> --
    >> Regards,
    >> Alvin Bruney
    >> ------------------------------------------------------
    >> Shameless author plug
    >> Excel Services for .NET is coming...
    >> OWC Black book on Amazon and
    >> www.lulu.com/owc
    >>
    >> "Peter Afonin" <> wrote in message
    >> news:...
    >>> Hello,
    >>>
    >>> I have a form with several buttons, and I need to post this data to
    >>> several different applications. In ASP.NET 1.1 it was quite easy - I
    >>> just used HTML controls (text or hidden), then assigned the action to
    >>> each button on Page_Load event:
    >>>
    >>> Me.ibPayWM.Attributes.Add("onclick",
    >>> "noPostBack('https://merchant.webmoney.ru/lmi/payment.asp');")
    >>> Me.ibPayRx.Attributes.Add("onclick",
    >>> "noPostBack('https://www.roboxchange.com/ssl/calc.asp');")
    >>> Me.ibPayRupay.Attributes.Add("onclick",
    >>> "noPostBack('http://www.rupay.com/rupay/pay/index.php');")
    >>>
    >>> I thought that in ASP.NET 2.0 this should be even much easier, because
    >>> each button has PostBackUrl property. However, it seems that I can use
    >>> this property to post data only within my application, because the page
    >>> I'm posting data to has to use PreviousPage property.
    >>>
    >>> The method I was using in ASP.NET 1.1 also doesn't seem to be working,
    >>> for some reason I'm posting data to the same page.
    >>>
    >>> So now I'm stuck - how to post the data to another application in
    >>> ASP.NET 2.0?
    >>>
    >>> I would appreciate your advice.
    >>>
    >>> Thank you,
    >>>
    >>> --
    >>> Peter Afonin
    >>>

    >>
    >>

    >
    >
     
    Alvin Bruney [MVP], Jan 8, 2007
    #4
  5. Peter Afonin

    Peter Afonin Guest

    Alvin, as I found out later, it actually works. But it doesn't work if I use
    Master page. I've tried different combinations, tried to play with forms -
    cannot figure out how to use it. I'm either getting error that that Form1
    is null or
    not an object, or go to the desired page, but without any data posted.

    Thanks,

    Peter

    "Alvin Bruney [MVP]" <some guy without an email address> wrote in message
    news:...
    > You posted this to at least two newsgroups, you only need to post a
    > question to one newsgroup.
    >
    > If you post to a page using 'https://merchant.webmoney.ru/lmi/payment.asp'
    > i'm not sure why it would not go to that page. What error are you seeing?
    >
    > --
    > Regards,
    > Alvin Bruney
    > ------------------------------------------------------
    > Shameless author plug
    > Excel Services for .NET is coming...
    > OWC Black book on Amazon and
    > www.lulu.com/owc
    >
    > "Peter Afonin" <> wrote in message
    > news:...
    >> Alvin, what do you mean - why?
    >>
    >> I have a form with several buttons and I have to post this data to the
    >> different applications. I'm afraid I don't understand your question.
    >>
    >> Thank you,
    >>
    >> Peter
    >>
    >>
    >> "Alvin Bruney [MVP]" <some guy without an email address> wrote in message
    >> news:...
    >>> Why the x-posting?
    >>>
    >>> --
    >>> Regards,
    >>> Alvin Bruney
    >>> ------------------------------------------------------
    >>> Shameless author plug
    >>> Excel Services for .NET is coming...
    >>> OWC Black book on Amazon and
    >>> www.lulu.com/owc
    >>>
    >>> "Peter Afonin" <> wrote in message
    >>> news:...
    >>>> Hello,
    >>>>
    >>>> I have a form with several buttons, and I need to post this data to
    >>>> several different applications. In ASP.NET 1.1 it was quite easy - I
    >>>> just used HTML controls (text or hidden), then assigned the action to
    >>>> each button on Page_Load event:
    >>>>
    >>>> Me.ibPayWM.Attributes.Add("onclick",
    >>>> "noPostBack('https://merchant.webmoney.ru/lmi/payment.asp');")
    >>>> Me.ibPayRx.Attributes.Add("onclick",
    >>>> "noPostBack('https://www.roboxchange.com/ssl/calc.asp');")
    >>>> Me.ibPayRupay.Attributes.Add("onclick",
    >>>> "noPostBack('http://www.rupay.com/rupay/pay/index.php');")
    >>>>
    >>>> I thought that in ASP.NET 2.0 this should be even much easier, because
    >>>> each button has PostBackUrl property. However, it seems that I can use
    >>>> this property to post data only within my application, because the page
    >>>> I'm posting data to has to use PreviousPage property.
    >>>>
    >>>> The method I was using in ASP.NET 1.1 also doesn't seem to be working,
    >>>> for some reason I'm posting data to the same page.
    >>>>
    >>>> So now I'm stuck - how to post the data to another application in
    >>>> ASP.NET 2.0?
    >>>>
    >>>> I would appreciate your advice.
    >>>>
    >>>> Thank you,
    >>>>
    >>>> --
    >>>> Peter Afonin
    >>>>
    >>>
    >>>

    >>
    >>

    >
    >
     
    Peter Afonin, Jan 9, 2007
    #5
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Newbie
    Replies:
    4
    Views:
    2,533
    Bin Song
    Nov 26, 2003
  2. Ameen
    Replies:
    3
    Views:
    3,397
    Ameen
    Oct 18, 2005
  3. Brian Henry

    posting data to asp.net from a vb.net app

    Brian Henry, Apr 11, 2006, in forum: ASP .Net
    Replies:
    2
    Views:
    471
    Brian Henry
    Apr 11, 2006
  4. Peter Afonin
    Replies:
    4
    Views:
    422
    Peter Afonin
    Jan 9, 2007
  5. Newbie

    Posting ASP .Net web form to another asp page

    Newbie, Nov 17, 2003, in forum: ASP .Net Web Services
    Replies:
    3
    Views:
    145
    Bin Song
    Nov 26, 2003
Loading...

Share This Page