?
Solved

calling methods (which appears to execute ok) -- is not updating display

Posted on 2008-10-06
3
Medium Priority
?
141 Views
Last Modified: 2013-12-17
calling methods (which appears to execute ok) -- is not updating display

Form #1 (which opened Form #2)

public bool SetWebPane(string webURL)
        {
            try
            {
                webBrowserIncompleteDIPs.Navigate(webURL);
                documentPane_IncompleteDIPs.Activate();

                radLabel1.Text = "I should be working OK !";
                return true;
            }
            catch (COMException ex)
            {
                showError(ex);
                return false;
            }
        }

____________________

Form #2

private void radButton1_Click(object sender, EventArgs e)
        {
            FormCentral openForm = new FormCentral();
            openForm.SetWebPane("http://www.123.com");
        }  

problem is that Form #1 does not appear to be updating the screen with visual upates / or processing any of the methods commands such as navigate etc. -- yet in debug I can see the url value being passed across the 2 winforms ok and those lines of code being called ... but nothing on-screen (winform #1) is updating.

what could this? and how fixable?
0
Comment
Question by:amillyard
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 13

Expert Comment

by:SameerJagdale
ID: 22658058
try to spawn a thread for updating UI..
0
 

Author Comment

by:amillyard
ID: 22674288
SameerJagdale:  apologies -- could you explain a little further, an example to assist my understanding if possible?
0
 
LVL 13

Accepted Solution

by:
SameerJagdale earned 1500 total points
ID: 22677703
well, I initially thought of it but don't think it will work !
the reason is you are trying to update controls on another form from one form. The best would be pass the object of Form1 to Form2 in contructor and then try calling the methods on this object.
Further, WebBrowser may have issue since, it is an wrapper to a com component..
let me know if i can help you with more...
0

Featured Post

Learn by Doing. Anytime. Anywhere.

Do you like to learn by doing?
Our labs and exercises give you the chance to do just that: Learn by performing actions on real environments.

Hands-on, scenario-based labs give you experience on real environments provided by us so you don't have to worry about breaking anything.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

IP addresses can be stored in a database in any of several ways.  These ways may vary based on the volume of the data.  I was dealing with quite a large amount of data for user authentication purpose, and needed a way to minimize the storage.   …
Welcome my friends to the second instalment and follow-up to our Minify and Concatenate Your Scripts and Stylesheets (http://www.experts-exchange.com/Programming/Languages/.NET/ASP.NET/A_4334-Minify-and-Concatenate-Your-Scripts-and-Stylesheets.html)…
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question