-
Jul 24th, 2016, 04:06 AM
#1
Thread Starter
Enjoy the moment
[RESOLVED] Drag Drop ListView Object Variable not set why?
hey,
i have a code using drop and drag in a listview
i put all the variables that is needed but still i get a error why?
this is the code i am using
Code:
Private DraggedOverItem As XtremeSuiteControls.ListViewItem
Private MovedItem As XtremeSuiteControls.ListViewItem
Private DraggedItem As XtremeSuiteControls.ListViewItem
Private SubItemIndex As Long
Code:
Private Sub LsVw_DragDrop(Source As Control, x As Single, y As Single)
With LsVw
Set DraggedOverItem = .HitTest(x, y)
With LsVw.ListItems
If DraggedOverItem Is Nothing Then
Set MovedItem = .Add(, , DraggedItem.Text)
Else
Set MovedItem = .Add(DraggedOverItem.Index, , DraggedItem.Text) ' Here Error
Set DraggedOverItem = Nothing
End If
With MovedItem
For SubItemIndex = 1 To LsVw.ColumnHeaders.Count - 1
.SubItems(SubItemIndex) = DraggedItem.SubItems(SubItemIndex)
Next
.Selected = True
End With
Set MovedItem = Nothing
.Remove DraggedItem.Index
End With
Set DraggedItem = Nothing
Set .DropHighlight = Nothing
.Drag vbEndDrag
End With
End Sub
Private Sub lsvw_DragOver(Source As Control, x As Single, y As Single, State As Integer)
With LsVw
If State = ccEnter Then Set .DropHighlight = .HitTest(x, y)
End With
End Sub
Private Sub LsVw_ItemClick(ByVal Item As XtremeSuiteControls.ListViewItem)
Set DraggedItem = Item
Item.Selected = False
With LsVw
.Drag vbBeginDrag
End With
End Sub
tnx for any help
regards
salsa
-
Jul 24th, 2016, 04:11 AM
#2
Re: Drag Drop ListView Object Variable not set why?
Sure that ListView control is part of Codejock.Controls activex?
In this case you should ask for help in Codejock ActiveX forum.
-
Jul 24th, 2016, 04:32 AM
#3
Thread Starter
Enjoy the moment
Re: Drag Drop ListView Object Variable not set why?
Originally Posted by gibra
Sure that ListView control is part of Codejock.Controls activex?
In this case you should ask for help in Codejock ActiveX forum.
yes sir correct
i asked a long time ago it take them ages to answer
can you help me please figure this one out?
-
Jul 24th, 2016, 10:13 AM
#4
Re: Drag Drop ListView Object Variable not set why?
Give me the link that you opened on Codejock forum...
-
Jul 24th, 2016, 10:31 AM
#5
Thread Starter
Enjoy the moment
Re: Drag Drop ListView Object Variable not set why?
Originally Posted by gibra
Give me the link that you opened on Codejock forum...
what do you mean the link?
you want the demo version of the controls?
-
Jul 24th, 2016, 11:56 AM
#6
Re: Drag Drop ListView Object Variable not set why?
If have written that you has asked help on Codejock forum, then send me the link of this thread. So I can reply to it.
Please note that: VBForum isn't the official forum of Codejock products.
Your request, here, is off topic.
-
Jul 24th, 2016, 12:10 PM
#7
Thread Starter
Enjoy the moment
Re: Drag Drop ListView Object Variable not set why?
no link sir i send them a email
never mind i'll try to find another solution
tnx
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|