Webbrowser Control - Copy contents of one control to the other

Hi,

I've got a windows form with two webbrowser controls; wb1 and wb2
I navigate to "webform1.htm" in wb1  

wb1.navigate("webform1.htm")

I programmatically fill out some details in webform1 and now comes the tricky part. I want to either...

Post webform1 and get the result to appear directly in the browsercontrol wb2

or

Post webform1 and then copy the result from webform1 to webform2

Can anyone help? Thanks in advance!
siono7Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

armoghanCommented:
see the following link for posting data
http://support.microsoft.com/default.aspx?scid=kb;EN-US;313068
0
armoghanCommented:
and instead of using axWebBrowser1 of Form1, use the object of form2 to get the results in that
0
siono7Author Commented:
Thanks for your answer armoghan, it seems to be the right solution but when I post the form to the second browser control with all the post data and the header information, I get an error saying that I have to enable cookies. Have you any idea why this is?
0
armoghanCommented:
Ok actually WebBrowser control handles cookies at the backend.. so what you need to do is get cookies and send it to the navigate method of the other control

see this link for sending the cookies by adding it to header. Cookies are just name value pair

string sCookies = "MyCookie=MyCookieValue";

   object o         = null;
   object oHeader    = "Cookie: " + sCookies + "\r\nMyItem: YES\r\n";

   browser.Navigate(sURL, ref o, ref o, ref o, ref m_oHeader);

ref
http://www.devdex.com/vb/message.asp?p=1120&r=4555642
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
armoghanCommented:
Accept armoghan
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic.NET

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.