Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8298311
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T15:43:33+00:00 2026-06-08T15:43:33+00:00

I have a form with labels A, B and C. In static void Main()

  • 0

I have a form with labels A, B and C. In static void Main(), I say:

Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Form1 form1 = new Form1();
Application.Run(form1);

Form1 constructor calls

InitializeComponent();
updateForm();

where updateForm reads a log ((FtpWebRequest)WebRequest) from a remote machine and updates the labels appropriately.

I would like to constantly update the form, because the remote log file is changing every few minutes.

I tried calling form1.updateLog() in while(true) loop in the main method, but the form doesn’t refresh. Also, form1.Refresh() doesn’t seem to work.

Any hints?
Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T15:43:35+00:00Added an answer on June 8, 2026 at 3:43 pm

    When you’re doing that in a loop then most likely on the UI thread. This means that you constantly tell the Form to repaint yet don’t give it time or an opportunity to do so (remember: you’re blocking the thread on which it would do that).

    Instead use a timer and refresh from there, e.g. every 100 ms or so.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a simple login form and have jQuery validate replacing the field labels
I have many buttons and labels on my c# form. I have a button
I have to do a user registration form (classical layout with two columns, labels
Okay so say I have a form element like this: HTML: <div class=form-item> <label>Current
I have window with some STATIC labels and BUTTONs on it. I make all
Hi am new to java and have been trying to create a form for
I have this problem: My web application has a form where the users can
I have a form with about ~400 Labels with random names such as '1',
I have a form on which there are three labels, whose values change when
I have a form (todo list) containing labels/checkboxes (todos) as follows: <form class=tasklist> These

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.