LEADTOOLS Support
General
General Questions
Re: Remove the multiple selection in annotations ?
This topic and its replies were posted before the current version of LEADTOOLS was released and may no longer be applicable.
#1
Posted
:
Tuesday, May 23, 2006 8:16:57 AM(UTC)
Groups: Registered
Posts: 7
Hello,
I would like to know if it's possible to remove the possibility to select several AnnObject in an automation manager. I've seen the MultiSelectModifierKey property to prevent from selecting several objects with the shift key.
Can anyone help me please ?
Thank you very much,
#2
Posted
:
Sunday, May 28, 2006 12:05:45 AM(UTC)
Groups: Registered, Tech Support
Posts: 1,326
Was thanked: 1 time(s) in 1 post(s)
Hello,
You are right. To stop the multi-select ability you need to disable the AnnAutomationManager.MultiSelectModifierKey Property as follows:
+---------------------+
manager.MultiSelectModifierKey = Keys.None
+---------------------+
Please let me know if I can be of further assistance.
Thanks,
Maen Badwan
LEADTOOLS Technical Support
#3
Posted
:
Sunday, May 28, 2006 11:09:44 PM(UTC)
Groups: Registered
Posts: 7
Thank you for your answer.
But I would like to know if it's possible to remove the multiselection with the mouse when I select several objects. By default, It's creates an AnnGroupObject but I don't want this kind of object.
How can I do without that ?
Thank you,
#4
Posted
:
Tuesday, June 6, 2006 4:58:07 AM(UTC)
Groups: Registered, Tech Support
Posts: 1,326
Was thanked: 1 time(s) in 1 post(s)
Hello,
You may try doing this by controlling the AnnGroupEditDesigner. You need to handle the AnnAutomation.BeforeObjectChanged event.
The code will be something as follows (I didn't try to use the following code, but you can make use of it):
+------------------------+
...
AddHandler AutomationAnn.BeforeObjectChanged, AddressOf automation_BeforeObjectChanged
...
Private Sub automation_BeforeObjectChanged(ByVal sender As Object, ByVal e As Leadtools.Annotations.AnnBeforeObjectChangedEventArgs)
Dim autiomation As AnnAutomation
autiomation = DirectCast(sender, AnnAutomation)
If (Not IsNothing(autiomation.CurrentDesigner) AndAlso TypeOf (autiomation.CurrentDesigner) Is AnnGroupEditDesigner) Then
Dim EditDesigner As AnnGroupEditDesigner = DirectCast(autiomation.CurrentDesigner, AnnGroupEditDesigner)
AddHandler EditDesigner.Edit, AddressOf AnnEditDesigner_Edit
End If
End Sub
...
Private Sub AnnEditDesigner_Edit(ByVal sender As Object, ByVal e As Leadtools.Annotations.AnnEditDesignerEventArgs)
e.Cancel = True
e.Object.Group = Nothing
End Sub
+------------------------+
Please let me know how it goes.
Thanks,
Maen Badwan
LEADTOOLS Technical Support
LEADTOOLS Support
General
General Questions
Re: Remove the multiple selection in annotations ?
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.