We help IT Professionals succeed at work.

Check out our new AWS podcast with Certified Expert, Phil Phillips! Listen to "How to Execute a Seamless AWS Migration" on EE or on your favorite podcast platform. Listen Now

x

help posting xml data to remote web form

nuvium
nuvium asked
on
Medium Priority
419 Views
Last Modified: 2012-05-11
I need help in posting xml data to a remotely hosted webform in a C# application. The mechanics of it aren't too complex. On my end, I've got an asp.net/c# web app which needs to communicate with a remote application. Basically, a button is pushed and the application will pop open a new window, and post xml data to a remotely hosted webform.

I've got the beginnings finished and working. First, I call a web service which returns a session ID. I store that in a local variable. Then I collect local data in MY form into an xml object which is converted to a string (NOT stored as a file, it stays in memory).

The next step is to pop the window locally, and in that new window, post the data to a given url, so that the new window has a pre-populated form on the remote end. I don't have to worry about any of the data once its there, what I am getting stuck on is the actual posting of the xml data to this webform. Can anyone lend me a hand?

One suggestion that was given to me by a co-worker is to create a holder/proxy page. We'll call it "dummy.aspx". I collect the xml data that will be posted, and the url that will eventually be posted TO in session variables. Using a simple JS window.open(), I pop the dummy.aspx in a window.

On the dummy.aspx side, I run a window.navigate or something to the URL to be posted to, along with the xml data as multi-part in the form. So the dummy.aspx kind of acts like a "placeholder" for the real stuff after the post happens.

This seems to be really roundabout though... isnt there an easier way to do this?

So to summarize:

My end - web form, collected data in xml string, url to be posted to
Their end - remotely hosted webform, expecting a post from me with xml data
The goal - pop the window on my webform, posting the xml data I collected to the url to be posted to

Thanks! Let me know if I can be more specific with anything.
Comment
Watch Question

CERTIFIED EXPERT
Commented:
Unlock this solution and get a sample of our free trial.
(No credit card required)
UNLOCK SOLUTION
Unlock the solution to this question.
Thanks for using Experts Exchange.

Please provide your email to receive a sample view!

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.