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

Content is invisible in RadContextMenu

2 Answers 82 Views
Menu
This is a migrated thread and some comments may be shown as answers.
Thomas Michael
Top achievements
Rank 1
Thomas Michael asked on 24 May 2010, 07:06 PM
I am using a RadContextMenu and RadGrid in combiation. The RadContextMenu is showing possible actions for a row in the RadGrid. Some of the actions are loading using a WCF service.

After upgrading to .NET 4.0 this has stopped working.

Using Firebug I can see that the RadContextMenu is getting the extra actions from the WCF service and the menu that appears is sized as if there is something to display, but its all blank and nothing happens when I click in it.

I am using VS2010, IIS7, the latest Telerik version, ASP.NET 4.0.

Hope someone can offer some help.

Regards
Thomas

My menu:
<telerik:RadContextMenu ID="rcmLines" runat="server" OnItemClick="rcmLines_ItemClick" >
  <WebServiceSettings Path="~/BudgetServices.svc" Method="GetEntryAccountMenuItems" />
  <Items>
    <telerik:RadMenuItem Text="Ignore" Value="I" />
    <telerik:RadMenuItem Text="Locate pair" Value="P" />
    <telerik:RadMenuItem Text="Set entry account" ExpandMode="WebService" >
      <GroupSettings Height="300px" />
    </telerik:RadMenuItem>
  </Items>
</telerik:RadContextMenu>

The JavaScript invoked from the RadGrid:
    function PopLineMenu(sender, eventArgs) {
      var menu = $find("<%= rcmLines.ClientID %>");
      var evt = eventArgs.get_domEvent();

      if (evt.target.tagName == "INPUT" || evt.target.tagName == "A") {
        return;
      }

      var index = eventArgs.get_itemIndexHierarchical();
      document.getElementById("lineIndex").value = index;

      sender.get_masterTableView().selectItem(sender.get_masterTableView().get_dataItems()[index].get_element(), true);

      menu.show(evt);

      evt.cancelBubble = true;
      evt.returnValue = false;

      if (evt.stopPropagation) {
        evt.stopPropagation();
        evt.preventDefault();
      }
    }
 
The method being called:
        [OperationContract]
        public RadMenuItemData[] GetEntryAccountMenuItems() {
            var list = AppContext.DefaultAccountPlan.NonSumEntryAccounts;
            var array = list.ConvertAll(x => new RadMenuItemData {Text = x.NameAndNumber, Value = "Id:"+x.Id}).ToArray();
            
            return array;
        }


2 Answers, 1 is accepted

Sort by
0
T. Tsonev
Telerik team
answered on 27 May 2010, 03:26 PM
Hi Thomas,

I've tested with a similar setup and everything seems to be working fine. Please make sure that you're using the 4.0 build of RadControls.

Maybe something else on the page is interfering with the menu. It will be great if you can send us a running site with this page alone, so we can try to debug the problem.

I hope this helps.

Kind regards,
Tsvetomir Tsonev
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
0
Marco
Top achievements
Rank 1
answered on 15 Feb 2011, 04:29 PM
I got a similar problem in ie. when i set the property "isSeparator" to true. the separator becomes transparent
I'm using net framework 3.5 and telerik Q2 2009 SP1
Tags
Menu
Asked by
Thomas Michael
Top achievements
Rank 1
Answers by
T. Tsonev
Telerik team
Marco
Top achievements
Rank 1
Share this question
or