troubleshooting Question form not refreshing when changing label.text

Avatar of Jarrod
JarrodFlag for Australia asked on
.NET ProgrammingVisual Basic.NET
14 Comments1 Solution3804 ViewsLast Modified:
Hello experts

Im a bit of an amateur when it comes to programming and have hit a snag with my app. I originally wrote it in .net 2003 and have since learnt a fair bit about better coding practices. One of the objectives I wanted with my recoding to the new version was to restrict my app to a single instance, which seemed easy enough by going to the app properties and turning on application framework and ticking allow single instance.

My problem became that I was using a Sub Main located in a moduile where 90% of my code is to start my app and required a windows form as my startup object. This wasnt to much of a drama as I used more or less a loading splash screen form that showed status updates as the software started (Open connection to db, run command 1, authenticate user etc). Ive got the single instance part working properly but now on my form that is the startup object whenever I do a label.text change for the status label it doesnt refresh during the applications startup procedures (At the end of starting my loader form closes and opens a main form) so it sits on the original status which is Starting App Version xxxx

So my question is should I be looking at different thread modes (Ie having a seperate thread for the status changes) to resolve this issue ? Im currently using a form.refresh command after each label.text change which worked prior to changing to the application framework mode (Ive also tried the doevents as well without success).

Additionally on a side note, can someone confirm that when im using single instance via the method listed above that it applies to the logged on users session only (I have this app on both users workstation and a terminal server or two and this would pointless for me if it only allows one copy for all currently logged on users). Any help is greatly appreciated
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 14 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 14 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros