Click here to Skip to main content
15,887,350 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Receiver Image in a VB program Pin
Dave Kreskowiak1-Jun-08 3:50
mveDave Kreskowiak1-Jun-08 3:50 
QuestionGetType on a Referenced Assemble without hardcoding assembly loadfrom values Pin
MartyK200731-May-08 8:19
MartyK200731-May-08 8:19 
AnswerRe: GetType on a Referenced Assemble without hardcoding assembly loadfrom values Pin
Dave Kreskowiak1-Jun-08 4:09
mveDave Kreskowiak1-Jun-08 4:09 
GeneralRe: GetType on a Referenced Assemble without hardcoding assembly loadfrom values Pin
MartyK20072-Jun-08 0:58
MartyK20072-Jun-08 0:58 
GeneralRe: GetType on a Referenced Assemble without hardcoding assembly loadfrom values Pin
Dave Kreskowiak2-Jun-08 1:34
mveDave Kreskowiak2-Jun-08 1:34 
GeneralRe: GetType on a Referenced Assemble without hardcoding assembly loadfrom values Pin
MartyK20072-Jun-08 6:13
MartyK20072-Jun-08 6:13 
GeneralRe: GetType on a Referenced Assemble without hardcoding assembly loadfrom values Pin
Dave Kreskowiak2-Jun-08 15:28
mveDave Kreskowiak2-Jun-08 15:28 
QuestionClipCursor not working Pin
Chris Copeland31-May-08 7:15
mveChris Copeland31-May-08 7:15 
No matter what I do, the ClipCursor function will not work.

I'm using VB.NET and i'm running on Windows Vista (SP1 as far as I know).

Here's a basic outline of my code:

Option Explicit On

Public Class MainBase

    Private Structure POINTAPI
        Dim X As Long
        Dim Y As Long
    End Structure

    Private Structure RECT
        Dim Left As Long
        Dim Top As Long
        Dim Right As Long
        Dim Bottom As Long
    End Structure

    Private Declare Function ClipCursorRect Lib "user32" Alias "ClipCursor" (ByVal lpRect As RECT) As Integer
    Private Declare Sub ClipCursorClear Lib "user32" Alias "ClipCursor" (ByVal lpRect As Long)
    Private Declare Function ClientToScreen Lib "user32" (ByVal hWnd As Long, ByVal lpPoint As POINTAPI) As Long

    Public Function CursorClip(ByVal lLeft As Long, ByVal lTop As Long, ByVal lWidth As Long, ByVal lHeight As Long) As Integer
        Dim tR As New RECT()
        Dim tP As POINTAPI

        'Convert positions into a rectangle in pixels
        tR.Left = lLeft
        tR.Top = lTop
        tR.Right = (lLeft + lWidth)
        tR.Bottom = (lTop + lHeight)
        'Set the cursor clipping rectangle
        Return ClipCursorRect(tR)
    End Function

    Private Sub FormIsClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing
        Call ClipCursorClear(0&)
    End Sub

    Private Sub FormLoad(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        If CursorClip(Me.Left, Me.Top, Me.Width, Me.Height) = 0 Then
            MsgBox("Failed")
        End If
    End Sub

End Class


Any ideas? :\
QuestionI/O leak when using .NET functions Pin
WhiteDog31-May-08 6:13
WhiteDog31-May-08 6:13 
AnswerRe: I/O leak when using .NET functions Pin
Dave Kreskowiak31-May-08 12:14
mveDave Kreskowiak31-May-08 12:14 
GeneralRe: I/O leak when using .NET functions Pin
WhiteDog31-May-08 15:57
WhiteDog31-May-08 15:57 
GeneralRe: I/O leak when using .NET functions Pin
Dave Kreskowiak1-Jun-08 3:57
mveDave Kreskowiak1-Jun-08 3:57 
QuestionpreInsert Trigger Pin
sahar_mal31-May-08 3:44
sahar_mal31-May-08 3:44 
AnswerRe: preInsert Trigger Pin
Dave Kreskowiak31-May-08 11:59
mveDave Kreskowiak31-May-08 11:59 
GeneralRe: preInsert Trigger Pin
sahar_mal1-Jun-08 20:18
sahar_mal1-Jun-08 20:18 
GeneralRe: preInsert Trigger Pin
Dave Kreskowiak2-Jun-08 1:28
mveDave Kreskowiak2-Jun-08 1:28 
GeneralRe: preInsert Trigger Pin
sahar_mal2-Jun-08 19:55
sahar_mal2-Jun-08 19:55 
QuestiondataGridView Chenge with ComboBox Pin
sahar_mal31-May-08 3:39
sahar_mal31-May-08 3:39 
QuestionTransfer Datas Pin
senthilsstil31-May-08 1:34
senthilsstil31-May-08 1:34 
AnswerRe: Transfer Datas Pin
Mycroft Holmes31-May-08 2:00
professionalMycroft Holmes31-May-08 2:00 
GeneralRe: Transfer Datas Pin
senthilsstil31-May-08 2:08
senthilsstil31-May-08 2:08 
Question.Net and touch screens [modified] Pin
The Web Developer30-May-08 11:55
The Web Developer30-May-08 11:55 
AnswerRe: .Net and touch screens Pin
Joe Woodbury30-May-08 12:01
professionalJoe Woodbury30-May-08 12:01 
GeneralRe: .Net and touch screens Pin
The Web Developer30-May-08 12:24
The Web Developer30-May-08 12:24 
GeneralRe: .Net and touch screens Pin
Joe Woodbury30-May-08 12:31
professionalJoe Woodbury30-May-08 12:31 

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.