Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
257 views
I have a radMenu on a Master Page. I need several of the menu items to open radWindows when clicked while the rest handle window clicks normally using the NavigateURL property of the Menu Item.

So my question is how can I achieve this client side using javascript. I have tried all the samples that appear about this topic but not one of them works for the Prometheus RadWindow/RadMenu. I have added a RadWindowManager with several radWindows that display "custom dialogs from aspx pages".  These custom pages allow the user to set report parameters which I then  pass along to build a Crystal Report.

Any samples would be greatly appreciated.

Thanks
Georgi Tunev
Telerik team
 answered on 09 Apr 2008
7 answers
316 views
Hello,

I am attempting to display appoinment information in a radtooltip and am running into a strange problem.

First off, I am using the Scheduler's AppointmentCreated event to dynamically create the tooltips:
    protected void Scheduler_AppointmentCreated(object sender, AppointmentCreatedEventArgs e)  
    {  
        RadToolTip tooltip = new RadToolTip();  
        tooltip.ID = "tooltip";  
        tooltip.TargetControlID = e.Appointment.ClientID;  
        tooltip.IsClientID = true;  
        tooltip.Animation = ToolTipAnimation.Resize;  
        tooltip.Sticky = true;  
        tooltip.ContentScrolling = ToolTipScrolling.Auto;  
        tooltip.RelativeTo = ToolTipRelativeDisplay.Mouse;  
 
        StringBuilder sb = new StringBuilder();  
        sb.AppendFormat(e.Appointment.Subject);  
        sb.Append(" ");  
        sb.AppendFormat("{0}{1}{2}", e.Appointment.Start.ToShortTimeString(), " - ",  
            e.Appointment.End.ToShortTimeString());  
 
        e.Appointment.ToolTip = string.Empty;  
 
        tooltip.Text = "Something wonderful!";  
          
        e.Container.Controls.Add(tooltip);        
          
    } 

Nothing to fancy here and everything at this point works like a charm.

The problem starts when I start adding controls to the tooltip control collection:

    protected void Scheduler_AppointmentCreated(object sender, AppointmentCreatedEventArgs e)  
    {  
        RadToolTip tooltip = new RadToolTip();  
        tooltip.ID = "tooltip";  
        tooltip.TargetControlID = e.Appointment.ClientID;  
        tooltip.IsClientID = true;  
        tooltip.Animation = ToolTipAnimation.Resize;  
        tooltip.Sticky = true;  
        tooltip.ContentScrolling = ToolTipScrolling.Auto;  
        tooltip.RelativeTo = ToolTipRelativeDisplay.Mouse;  
 
        StringBuilder sb = new StringBuilder();  
        sb.AppendFormat(e.Appointment.Subject);  
        sb.Append(" ");  
        sb.AppendFormat("{0}{1}{2}", e.Appointment.Start.ToShortTimeString(), " - ",  
            e.Appointment.End.ToShortTimeString());  
 
        e.Appointment.ToolTip = string.Empty;  
 

        Button button = new Button();  

        button.ID = "btnA";  

        button.Text = "Button in a ToolTip";  

        tooltip.Controls.Add(button);  

          
        e.Container.Controls.Add(tooltip);        
          
    } 

Basically, when I start adding controls to the tooltip control collection, instead of poping up normally, the tooltip pops up inside what I believe is the appointment container (appointment div?). If I knew how to attach files I would include a screenshot of what I am talking about.

Please let me know what you find. Also, please provide me with a server side solution as this simple example is only the tip of the iceberg of what I need to do.

If you need more information I will try to provide a better description of the problem.

Thank you.
Peter
Telerik team
 answered on 09 Apr 2008
1 answer
88 views
Hello,

I need to do a real postback  from a DockCommand button with a response redirect, how to obtain this ?

Thanks
CS
Obi-Wan Kenobi
Top achievements
Rank 1
 answered on 09 Apr 2008
3 answers
286 views
Hello guys,


I have a problem with the Prometheus combobox when trying to set a datasource dynamically.  Here how I'm set up:  I have a combo box that is part of an update panel and the combo box list of items can be very very long (many thousands items).  Since I dont want to transfer all these items (accessed by web service) and set it to the combobox datasource, I'm trying to set the datasource in the OnItemsRequested server side method when the user type 3 or more charaters in the combobox (the allow custom text is set to true and when there is 3 characters or more that are typed, in the OnItemsRequested method I call the web service and set the datasource).

The server side code that set the datasource id very simple, it looks like this:

try
{
      RadComboBox combo = (RadComboBox)o;
      combo.Items.Clear();
      conditionDTO[] dtos = searchConditions(e.Text);
       if (dtos != null)
       {
            foreach (conditionDTO dto in dtos)
            {
                RadComboBoxItem item = new RadComboBoxItem(dto.name);
                item.Value = dto.code.ToString();
                combo.Items.Add(item);
              }
        }

        combo.DataSource = dtos;
        combo.DataBind();
        ((UpdatePanel)Page.FindControl("UpdatePanelPop")).Update();
}




I make a call to the web service, set the datasource to the combobox, call databind and update my update panel. On the UI, the dropdown contains the proper items, but if I select one from the list and do a callback,  the SelectedItem on the combobox is always null (and the combobox datasource also).

Here's what the combobox definition looks like:

<telerik:RadComboBox Width="239px" Height="200px" EnableEmbeddedSkins="False" ID="selNoBlankPatientConditions" AllowCustomText="true" runat="server" DataTextField="name" DataValueField="code" EnableLoadOnDemand="true" MarkFirstMatch="True" MaxLength="50" OnItemsRequested="conditions_ItemsRequested" Text="Type or select your condition here..." >
     <CollapseAnimation Duration="200" Type="OutQuint" />
     <ExpandAnimation Type="OutQuart" />
</telerik:RadComboBox>


I really need help on this one!

Thx,
Phil
Simon
Telerik team
 answered on 09 Apr 2008
2 answers
170 views

It only works in my javascript function - Telerik.Web.UI.InputErrorReason.OutOfRange.  But the actual calendar still let's me pick between 1980 and 2099. 

Even though the mindate is set to 01/01/2008 and the maxdate is set to 03/29/2008.  I'm passing 2 parameters/properties into the usercontrol.  

public
DateTime DateFrom

{

get { return this.RadDatePicker1.MinDate; }

set { this.RadDatePicker1.MinDate = value; }

}

public DateTime DateTo

{

get { return this.RadDatePicker1.MaxDate; }

set { this.RadDatePicker1.MaxDate = value; }

}




 

Maria Ilieva
Telerik team
 answered on 09 Apr 2008
5 answers
141 views
I am trying to get a node in a tree view to have a back color that spans all the way across the page. But when i applie the background color it only goes as far as the text. Is there a way to do this? I have also tried to change the size of the node but that seems to make no difference.
Nikolay
Telerik team
 answered on 09 Apr 2008
3 answers
267 views

I want to do this dynamically in the codebehind.  Is that possible?

<
HeaderTemplate>

<div>

<table style="width: 100%;" border="0" cellspacing="0" cellpadding="0">

<tr>

<td style="width: 25%;">

User Id

</td>

<td style="width: 25%;">

Name

</td>

<td style="width: 50%;">

Depart

</td>

</tr>

</table>

</div>

</HeaderTemplate>

<ItemTemplate>

<table style="width: 100%;" cellspacing="0" cellpadding="0">

<tr>

<td style="width: 25%;">

<div >

<%

# DataBinder.Eval(Container.DataItem, "id")%>

</div>

</td>

<td style="width: 25%;">

<div >

<%

# DataBinder.Eval(Container.DataItem, "name") %>

</div>

</td>

<td style="width: 50%;">

<div >

<%

# DataBinder.Eval(Container.DataItem, "dep")%>

</div>

</td>

</tr>

</table>

</ItemTemplate>

Rosi
Telerik team
 answered on 09 Apr 2008
3 answers
163 views
I have a RadComboBox control with some special logic in its ItemsRequested event. I would like to encapsulate this logic into a server control that I can reuse within my solution. If I simply derive from RadCombBox and wire up this event my custom logic, it clearly does not work as the ItemsRequested event never fires. How would I go about solving this one?
Rosi
Telerik team
 answered on 09 Apr 2008
1 answer
370 views
Hi,

For some reason, if an IFRAME is present on an ASPX page with a RadWindow declared, the window cannot be detected. This problem happens in both FF and IE7.

In the code below, oWnd always returns null. If the IFRAME line is commented out, the popup appears fine when the link is clicked on.

Any idea what might be the problem?


<%@ Page Language="C#" AutoEventWireup="true" CodeFile="testradwindowiframe.aspx.cs" Inherits="Test_testradwindowiframe" %> 
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %> 
 
<html> 
<head> 
</head> 
<body> 
<form id="form1" runat="server"> 
    <script language="javascript" type="text/javascript"> 
        var oWnd; 
        function Test(wizardID) 
        { 
            oWnd = $find( '<%= TestPopupWindow.ClientID %>' ); 
             
            oWnd.setUrl('http://www.yahoo.com'); 
            oWnd.show();   
        }     
         
        function TestClientCallBack(radWindow, returnParameters) 
        { 
         
        } 
               
    </script> 
 
 
 
    <asp:ScriptManager ID="ScriptManager1" runat="server" />  
    <telerik:RadWindowManager id="Singleton" runat="server" Skin="Vista"> 
        <windows> 
            <telerik:RadWindow ID="TestPopupWindow" runat="server" Height="300" Width="300"  
                DestroyOnclose="false"     
                Modal="true" 
                VisibleStatusbar="false" 
                VisibleTitlebar = "true" 
                NavigateUrl=""     
                Title = "Test"          
                Behaviors="Close,Move" 
                ClientCallBackFunction="TestClientCallBack" 
            /> 
        </windows> 
         
         </telerik:RadWindowManager> 
 
    <a href="javascript:void(0)" onclick="javascript:Test(0)">Test(0)</a>   
 
    <iframe id="ViewWizardSummaryIFrame" width="20" height="20"/>  
 
    <p>Test Page</p> 
    </form> 
</body>         
 
</html> 




Georgi Tunev
Telerik team
 answered on 09 Apr 2008
1 answer
307 views
I am using a RadGrid that has up to 30 skinny columns with 3 characters each.  When I ExportToPDF() they overlap themselves and they appear stacked.  I read the documentation and altered the ItemStyle and AlternatingStyle but no change even with IgnorePaging set to true.  I am using a Skin on the Grid itself for appearance which is the Vista skin.  Is there anyway to have the export PDF use a small font for export purposes but still use skin for visual appearance?

Also.....can I force it to be landscape orientation?

Using Telerik.Web.UI 2007.3.1425.20

Thanks in advance.
Doug
Steve
Telerik team
 answered on 09 Apr 2008
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jake
Top achievements
Rank 1
RBarnes
Top achievements
Rank 1
Iron
Iron
Rami
Top achievements
Rank 1
Iron
Veteran
Nathan
Top achievements
Rank 1
Kumeri
Top achievements
Rank 1
Iron
Veteran
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?