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

[Solved] contextMenus and webservice

9 Answers 192 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
jim
Top achievements
Rank 1
jim asked on 08 Jan 2008, 06:54 AM
I want to populate data with webservice. but how can i add contextMenus for those new nodes(the context menus are different of parent node)?

9 Answers, 1 is accepted

Sort by
0
Erjan Gavalji
Telerik team
answered on 08 Jan 2008, 05:27 PM
Hi jim,

We had a small glitch with the RadTreeNodeData class - it did not contain any information for the node ContextMenuID. That will be fixed in the official service pack of the RadControls "Prometheus" suite scheduled for the next week.

Please, bear with us some more.

Best regards,
Erjan Gavalji
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Mark Thomas
Top achievements
Rank 1
answered on 10 Jan 2008, 10:33 AM
Good to hear. I need this aswell.


Regards,
Mark Thomas.
0
Erjan Gavalji
Telerik team
answered on 10 Jan 2008, 12:36 PM
Hi guys,

Please, find attached the latest internal build of the RadControls "Prometheus" suite, having the glitch fixed.

Let me know your experience with it.

Kind regards,
Erjan Gavalji
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Mark Thomas
Top achievements
Rank 1
answered on 18 Jan 2008, 02:04 PM
Hi Erjan,

I have started using the TreeView with a webservice and must say it works brilliantly and fast. The .ContextMenuID is also there, but when I try and retrieve the ID after webservice population it is empty, why?

The ContextMenu is attached, but there is no ID attached to the selectedNode.

Can you confirm this behaviour?

Regards,
Mark Thomas.
0
Erjan Gavalji
Telerik team
answered on 18 Jan 2008, 05:29 PM
Hi Mark,

We missed the proper serialization of the RadTreeNodeData on the client, that's why it does not contain the information about the ContextMenuID. We already fixed that and the fix will be available in the next service pack of the RadControls "Prometheus" suite.

There is a workaround currently which you can use. It is the following:
  • Define a client-side event handler to the OnClientNodePopulating property;
  • Pass the node ContextMenuID to the context object;
  • Get the ContextMenuID server-side from the context.

Please, find attached a rework of our WebService example, demonstrating that.

I hope this helps.

Kind regards,
Erjan Gavalji
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Mark Thomas
Top achievements
Rank 1
answered on 21 Jan 2008, 09:31 AM
Hi Erjan,

Unfortunately the workaround will not work for me, as I need the ContextMenuID onNodeClick, but the ContextMenuID that I save in the OnClientNodePopulating method is the wrong ID as it is the nodes parent.

Can you give me an estimate as to when the service pack will be out?

Regards,
Mark Thomas.
0
Erjan Gavalji
Telerik team
answered on 21 Jan 2008, 12:45 PM
Hi Mark,

I'm sorry I could not understand your scenario. Basically the workaround should work the same way as the actual control implementation.

We haven't determined the exact service pack release date yet, but it will be about two or three weeks from now. Anyways, I just prepared a preliminar fix for you. Please, find it attached.

Let me know if your application works fine now. If not, can you please, prepare a small running page that will demonstrate the problem so that we can find a possible fix or a workaround?

Kind regards,
Erjan Gavalji
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Mark Thomas
Top achievements
Rank 1
answered on 21 Jan 2008, 03:30 PM
Hi Erjan,

The trial hotfix didn't seem to help. I opened a Support Ticket with a running example 117713.

It may be a simple matter of that I cannot do what I want this way. I am no expert at throwing javascript around and client/server-side objects.

Regards,

Mark Thomas.
0
Erjan Gavalji
Telerik team
answered on 22 Jan 2008, 05:14 PM
Hi Mark,

Thanks to your project we found an omission in the RadTreeNode data serialization on postback. The bug is already fixed.

Thanks!

Cheers,
Erjan Gavalji
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
TreeView
Asked by
jim
Top achievements
Rank 1
Answers by
Erjan Gavalji
Telerik team
Mark Thomas
Top achievements
Rank 1
Share this question
or