This is a migrated thread and some comments may be shown as answers.

How to disable drop before and drop after parent node?

6 Answers 39 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
Ivo
Top achievements
Rank 1
Ivo asked on 25 May 2009, 06:11 PM
Hi,
I have the following tree schema:
With one tree node that acts as a parent and 3 child nodes
A
--B
--C
--D

I want to be able to only do operations like for example drop D before B or after B, exchanging therefore only the nodes order.So I set in Node A to IsDropAllowed = true and Node B,C and D  to IsDropAllowed = false.This solved the problem, but i'm capable of putting node B before or after node A and this is not desirable, how can i disable this behaviour?
As a work around I tried to cancel the before\after node A action, using the PreviewDragEnded but the TargetDropItem is null as I reported also in a previous thread, even if this worked it's not desirable for the user to see the "drop before A" and "drop after A" tag.
Is it possible to have this kind of behaviour, am I missing something?
Some feedback would be quite welcome, thanks in advance.
Regards,
Ivo
 

6 Answers, 1 is accepted

Sort by
0
Dimitrina
Telerik team
answered on 27 May 2009, 02:14 PM
Hi Ivo,

Thank you for your feedback. The example I'm sending shows the correct way to accomplish the task. The problem is that the TardetDropItem property returns "null". We are aware of this glitch and we will address it with the upcoming Q2 release due the at end of June/beginning of July.

Sincerely yours,
Dimitrina
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
James
Top achievements
Rank 1
answered on 01 Jun 2009, 01:44 PM
Argh, I've just run into this problem now. e.TargetDropItem is null when I'm dropping before or after (but ok when dropping 'in'). Is this fixed in the latest internal build? (Or is there a workaround?)

Thanks, James.
0
Tihomir Petkov
Telerik team
answered on 01 Jun 2009, 04:19 PM
Hi James,

The issue is not fixed yet. Can you please take a look at the sample attached to the previous post and see if it doesn't solve your problem. If not, can you please give me some more details about your scenario?

Greetings,
Tihomir Petkov
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
James
Top achievements
Rank 1
answered on 01 Jun 2009, 08:40 PM
Hi Tihomir,

Thanks for your answer. I tried the example, and it works as far as it goes, but I need information from the TargetDropItem, which stays null. Don't worry about my particular use case though. I can wait until July (assuming the TargetDropItem will not be null afterwards?).

Thanks for your help, James.
0
Bobi
Telerik team
answered on 03 Jun 2009, 12:12 PM
Hello James,

The problem with TargetDropItem is already fixed and the change will be reflected in the next internal build.


Best wishes,
Boryana
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
James
Top achievements
Rank 1
answered on 03 Jun 2009, 05:30 PM
Thanks - that's good to know.
Best wishes, James.
Tags
TreeView
Asked by
Ivo
Top achievements
Rank 1
Answers by
Dimitrina
Telerik team
James
Top achievements
Rank 1
Tihomir Petkov
Telerik team
Bobi
Telerik team
Share this question
or