Click here to Skip to main content
15,922,315 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Help writing a function Pin
rwestgraham1-Apr-05 13:06
rwestgraham1-Apr-05 13:06 
GeneralDocking Forms Pin
cpod30-Mar-05 16:18
cpod30-Mar-05 16:18 
GeneralRe: Docking Forms Pin
Mr Dabbah1-Apr-05 9:20
Mr Dabbah1-Apr-05 9:20 
GeneralIntercepting a print job Pin
tempgp30-Mar-05 14:58
tempgp30-Mar-05 14:58 
GeneralRe: Intercepting a print job Pin
Dave Kreskowiak30-Mar-05 15:40
mveDave Kreskowiak30-Mar-05 15:40 
GeneralRe: Intercepting a print job Pin
tempgp30-Mar-05 15:50
tempgp30-Mar-05 15:50 
GeneralRe: Intercepting a print job Pin
Dave Kreskowiak31-Mar-05 1:59
mveDave Kreskowiak31-Mar-05 1:59 
GeneralCursors and threads Pin
PaleyX30-Mar-05 12:27
PaleyX30-Mar-05 12:27 
In my main App I run a long running process on a seperate thread so as not to tie up the GUI - while the process is running I want to set the Cursor to the WaitCursor. The first thing the long running process does it fire an event which is handled on the GU thread and sets the cursor to the WaitCursor then when the process has finished it fires another event which is again handled on the GUI thread and sets the Cursor to default - however, the cursor never actually changes to the WaitCursor

The long running process fires off an event every 1000 records or so which is handled on the GU thread thus:

<br />
    Private Delegate Sub xxxDelegate(ByVal sender As Object, ByVal e As xxxEventArgs)<br />
<br />
    Private Sub xxx(ByVal sender As Object, ByVal e As xxxEventArgs) Handles LongProcess.xxx<br />
<br />
        If button.InvokeRequired = False Then<br />
           Console.WriteLine("A - " & Cursor.Current.ToString())<br />
            ...<br />
        Else<br />
            Console.WriteLine("B - " & Cursor.Current.ToString())<br />
            Dim del As New xxxDelegate(AddressOf xxx)<br />
            Me.BeginInvoke(del, New Object() {sender, e})<br />
        End If<br />
    End Sub<br />


When run the following is written to the console:

B - [Cursor: WaitCursor]
A - [Cursor: Default]
B - [Cursor: WaitCursor]
A - [Cursor: Default]
B - [Cursor: WaitCursor]
A - [Cursor: Default]
...

Why is this?
GeneralRe: Cursors and threads Pin
Dave Kreskowiak30-Mar-05 15:02
mveDave Kreskowiak30-Mar-05 15:02 
GeneralRe: Cursors and threads Pin
PaleyX30-Mar-05 23:03
PaleyX30-Mar-05 23:03 
GeneralCrystal Reports problem with OLE images from Access DB Pin
KRadtke30-Mar-05 10:43
KRadtke30-Mar-05 10:43 
Generalclient server application Pin
sam_pune30-Mar-05 2:43
sam_pune30-Mar-05 2:43 
GeneralRe: client server application Pin
Christian Graus30-Mar-05 11:56
protectorChristian Graus30-Mar-05 11:56 
GeneralBest choice for data Pin
Mega130-Mar-05 1:26
Mega130-Mar-05 1:26 
GeneralRe: Best choice for data Pin
Christian Graus30-Mar-05 11:57
protectorChristian Graus30-Mar-05 11:57 
Generalinsert procedure in exe project Pin
a_yosef29-Mar-05 23:59
a_yosef29-Mar-05 23:59 
GeneralRe: insert procedure in exe project Pin
Dave Kreskowiak30-Mar-05 4:13
mveDave Kreskowiak30-Mar-05 4:13 
GeneralRe: insert procedure in exe project Pin
Christian Graus30-Mar-05 11:58
protectorChristian Graus30-Mar-05 11:58 
GeneralRe: insert procedure in exe project Pin
a_yosef30-Mar-05 20:28
a_yosef30-Mar-05 20:28 
GeneralRe: insert procedure in exe project Pin
Christian Graus31-Mar-05 12:01
protectorChristian Graus31-Mar-05 12:01 
GeneralErron in calling GetCursorpos Api Pin
Zakaullah29-Mar-05 23:51
Zakaullah29-Mar-05 23:51 
GeneralRe: Erron in calling GetCursorpos Api Pin
Dave Kreskowiak30-Mar-05 4:09
mveDave Kreskowiak30-Mar-05 4:09 
Generalhello see that problem Pin
Anonymous29-Mar-05 21:09
Anonymous29-Mar-05 21:09 
Questionhow can i edit datagrid ? Pin
sumit2129-Mar-05 19:39
sumit2129-Mar-05 19:39 
Questionhow to know if a tooltip is displayed or not when mouse is moved Pin
Anonymous29-Mar-05 19:18
Anonymous29-Mar-05 19:18 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.