Solved

Help with selecting data from combobox using VB.NET

Posted on 2015-02-08
9
106 Views
Last Modified: 2015-02-09
Hi,
What is the first property activated when you select a row from a  combobox? I included a code to display label indicating code is processing in the selectindex property bu the label does not display when I select a row, until search code is completed.

Victor
0
Comment
Question by:vcharles
  • 5
  • 2
  • 2
9 Comments
 
LVL 3

Expert Comment

by:Shane Kahkola
ID: 40597500
I believe it's combobox.click()

Then it should be SelectedIndexChanged()
0
 

Author Comment

by:vcharles
ID: 40597590
Hi,

Problem with Click is the label appears before I select a row.

Thanks
0
 
LVL 3

Expert Comment

by:Shane Kahkola
ID: 40597648
Right, I was confirming order of events during operation.  Are you sure it's not just happening so fast you're not seeing it?
0
Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

 

Author Comment

by:vcharles
ID: 40597709
Hi,
It is happening but after the code executes for example, code  in selectindexchanged

Label1.visible = True
Code
Label1.visible  = false

Code takes about 10 seconds to complete execution, meanwhile the label to indicate code is processing does not appear, until the code completes its execution.
0
 
LVL 35

Accepted Solution

by:
Miguel Oz earned 500 total points
ID: 40597719
Your code must force the label to be refreshed in the UI. For win forms, use the Refresh method as shown below:
Label1.visible = True
Label1.Refresh()
 Code
 Label1.visible  = false

Note: Your initial code does not work because label UI changes will not be applied until the event runs all your event code. Keep in mind that windows queue all your UI events for processing.
0
 

Author Closing Comment

by:vcharles
ID: 40598015
Thank you.
0
 

Author Comment

by:vcharles
ID: 40598018
Hi,

Is there a way to show the label blinking?
Thanks,
Victor
0
 
LVL 35

Expert Comment

by:Miguel Oz
ID: 40599420
Victor:
I do not think it is feasible to do it with your current implementation. Most label blinking implementations relied on timer events.
You could open another question in case other experts may have different advice.
0
 

Author Comment

by:vcharles
ID: 40599522
Ok. Thanks.
0

Featured Post

Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

Question has a verified solution.

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

Suggested Solutions

For those of you who don't follow the news, or just happen to live under rocks, Microsoft Research released a beta SDK (http://www.microsoft.com/en-us/download/details.aspx?id=27876) for the Xbox 360 Kinect. If you don't know what a Kinect is (http:…
Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

828 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