Click here to Skip to main content
15,919,931 members
Home / Discussions / Visual Basic
   

Visual Basic

 
Questionhow to do input validation in VB.NET? Pin
drmzunlimited24-Oct-02 10:38
drmzunlimited24-Oct-02 10:38 
AnswerRe: how to do input validation in VB.NET? Pin
Nick Parker25-Oct-02 5:32
protectorNick Parker25-Oct-02 5:32 
QuestionHow do I display a video file on a form? Pin
James Williams24-Oct-02 8:44
James Williams24-Oct-02 8:44 
AnswerRe: How do I display a video file on a form? Pin
Jerome Conus24-Oct-02 23:14
Jerome Conus24-Oct-02 23:14 
QuestionInterpret Enter as Tab? Pin
dazinith24-Oct-02 3:54
dazinith24-Oct-02 3:54 
AnswerRe: Interpret Enter as Tab? Pin
Anonymous24-Oct-02 15:48
Anonymous24-Oct-02 15:48 
Generallow resource message Pin
Notorious SMC23-Oct-02 20:42
sussNotorious SMC23-Oct-02 20:42 
General[VB.NET] Drag & Drop multiselection on listview Pin
Sebastien Curutchet22-Oct-02 4:20
Sebastien Curutchet22-Oct-02 4:20 
I'm trying to use drag & drop with a multiselection. I would like to copy the listview selected items on an other listview. I tried that :

<br />
    Private Sub lstAllRole_MouseDown(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles lstAllRole.MouseDown<br />
        lstAllRole.DoDragDrop(lstAllRole.SelectedItems, DragDropEffects.Copy)<br />
    End Sub<br />
<br />
    Private Sub lstRole_DragEnter(ByVal sender As Object, ByVal e As System.Windows.Forms.DragEventArgs) Handles lstRole.DragEnter<br />
        '        If e.Data().GetDataPresent("System.Windows.Forms.ListView.ListViewItemCollection", False) Then<br />
        If e.Data().GetDataPresent(lstAllRole.SelectedItems.GetType().ToString(), False) Then<br />
            e.Effect() = DragDropEffects.Copy<br />
        Else<br />
            e.Effect() = DragDropEffects.None<br />
        End If<br />
    End Sub<br />
<br />
    Private Sub lstRole_DragDrop(ByVal sender As Object, ByVal e As System.Windows.Forms.DragEventArgs) Handles lstRole.DragDrop<br />
        Dim obj As ListViewItem<br />
        Dim objCol As Object<br />
<br />
<br />
        For Each obj In e.Data.GetData(lstAllRole.SelectedItems.GetType().ToString(), False)<br />
            lstRole.Items.Add(obj)<br />
        Next<br />
    End Sub<br />



The drag & drop works but not the copy. Does someone already do it ?

Thanks
GeneralHttpSendRequest Pin
Vipul Bhatt21-Oct-02 0:50
Vipul Bhatt21-Oct-02 0:50 
GeneralRe: HttpSendRequest Pin
Richard Deeming22-Oct-02 22:24
mveRichard Deeming22-Oct-02 22:24 
GeneralRetrieving exchange users information Pin
Anonymous19-Oct-02 1:58
Anonymous19-Oct-02 1:58 
GeneralPrinter status Pin
Zulfikar Ali18-Oct-02 11:47
Zulfikar Ali18-Oct-02 11:47 
Generalregistering crystal reports in vb.net Pin
devil66618-Oct-02 11:11
devil66618-Oct-02 11:11 
Questionprint preview? Pin
drmzunlimited17-Oct-02 21:49
drmzunlimited17-Oct-02 21:49 
Questionreports? Pin
drmzunlimited17-Oct-02 21:47
drmzunlimited17-Oct-02 21:47 
AnswerRe: reports? Pin
Nick Parker18-Oct-02 8:13
protectorNick Parker18-Oct-02 8:13 
Questiondifficult problem of importing? Pin
drmzunlimited17-Oct-02 21:32
drmzunlimited17-Oct-02 21:32 
AnswerRe: difficult problem of importing? Pin
chris foote22-Oct-02 16:47
chris foote22-Oct-02 16:47 
Questionimporting data from excel file and storing in Ms-Access database table? Pin
drmzunlimited17-Oct-02 21:24
drmzunlimited17-Oct-02 21:24 
AnswerRe: importing data from excel file and storing in Ms-Access database table? Pin
Megan Forbes24-Oct-02 22:39
Megan Forbes24-Oct-02 22:39 
AnswerRe: importing data from excel file and storing in Ms-Access database table? Pin
Megan Forbes25-Oct-02 3:26
Megan Forbes25-Oct-02 3:26 
Questionimporting an excel file and storing in MS-Access? Pin
drmzunlimited17-Oct-02 21:21
drmzunlimited17-Oct-02 21:21 
AnswerRe: importing an excel file and storing in MS-Access? Pin
Steven Lyons21-Oct-02 12:03
Steven Lyons21-Oct-02 12:03 
Questionenvironment similar to excel??? Pin
drmzunlimited17-Oct-02 21:19
drmzunlimited17-Oct-02 21:19 
Questiondisable close and starting maximized? Pin
drmzunlimited17-Oct-02 21:05
drmzunlimited17-Oct-02 21:05 

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.