Telerik Forums
UI for ASP.NET AJAX Forum
6 answers
155 views
I have the following RadEditor:

<telerik:RadEditor ID="RadEditor1" runat="server" EditModes="Design, Preview" Skin="Outlook" EnableResize="true">
    <CssFiles>
        <telerik:EditorCssFile Value="StyleSheet.css" />
    </CssFiles>
    <Content>
        Editor content 1
    </Content>
</telerik:RadEditor>

The css inside StyleSheet.css is applied to the content of the RadEditor as expected. However, when this RadEditor is placed inside a RadWindow the css doesn't work.

How can I get the css to work when the RadEditor is inside a RadWindow?
Dean
Top achievements
Rank 1
 answered on 21 May 2012
2 answers
224 views
EDIT: I just realize The title is misleading. The OnAjaxUpdate DOES fire, but I get the error: 'Sys.ArgumentNullException: Sys.ArgumentNullException: Value cannot be null.Parameter name: panelsUpdated[0]'.


I have a RadGrid inside a panel and I Ajaxify the panel as an AjaxSetting using an RadAjaxManager. A popup window let's the user add items to the grid on closing via javascript, which then calls the RadAjaxManager's AjaxRequest. This all works great.

I have a couple RadToolTipManager's that are wired to elements in the RadGrid. On page load or reload, the tooltips work great. However, if the user adds an item via the popup window which calls the RadAjaxManager's AjaxRequest, the tootips don't work (unless the page is refreshed which defeats the purpose). All the user gets is the native tooltip text and nothing else.

So, after reading the forums, I realized I needed to add each RadTooltipManager as AjaxSettings in the RadAjaxManager. I did that and the tooltip begins to fire now, but after a few seconds it tosses an error: 'Sys.ArgumentNullException: Sys.ArgumentNullException: Value cannot be null.Parameter name: panelsUpdated[0]'.

Here's the HTML side of things...
<telerik:RadCodeBlock>
    <script type="text/javascript">
        function OnClientClose(oWnd, args) {
            var arg = args.get_argument();
            if (arg) {
                var retValue = arg.ReturnValue;
 
                if (arg.ReturnValue == "ONE" || arg.ReturnValue == "TWO") {
                    var ajaxManager = $find("<%= RadAjaxManager1.ClientID %>");
                    ajaxManager.set_enableAJAX(true);
                    ///this calls RadAjaxManager1_AjaxRequest() server side
                    ajaxManager.ajaxRequest(arg.ReturnValue); 
                }
                else {
                    __doPostBack('__Page', 'REFRESH|' + retValue)
                }
            }
        }
    </script>
</telerik:RadCodeBlock>
<des:PageManager ID="PageManager1" runat="server" AJAXFramework="TelerikRadAJAX"
    AJAXControlID="ScriptManager1">
    <ChangeMonitor Enabled="True" UseValidationGroups="True" />
</des:PageManager>
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" OnAjaxRequest="RadAjaxManager1_AjaxRequest">
    <AjaxSettings>
        <telerik:AjaxSetting AjaxControlID="pnlONE">
            <UpdatedControls>
                <telerik:AjaxUpdatedControl ControlID="pnlONE" LoadingPanelID="AjaxLoadingPanel1" />
            </UpdatedControls>
        </telerik:AjaxSetting>
        <telerik:AjaxSetting AjaxControlID="pnlTWO">
            <UpdatedControls>
                <telerik:AjaxUpdatedControl ControlID="pnlTWO" LoadingPanelID="AjaxLoadingPanel1" />           
                <telerik:AjaxUpdatedControl ControlID="RadToolTipManager1" />
                <telerik:AjaxUpdatedControl ControlID="RadToolTipManager3" />
            </UpdatedControls>
        </telerik:AjaxSetting>           
    </AjaxSettings>
</telerik:RadAjaxManager>
<telerik:RadAjaxLoadingPanel ID="AjaxLoadingPanel1" runat="server" Transparency="55"
    BackColor="#E0E0E0">
    <div style="text-align: center">
        <asp:Image ID="imgPanelImage" runat="server" AlternateText="Loading..." ImageUrl="~/Images/ajax-loader.gif" />
    </div>
</telerik:RadAjaxLoadingPanel>

And the C# side....
protected void RadAjaxManager1_AjaxRequest(object sender, AjaxRequestEventArgs e)
{
    RadToolTipManager1.TargetControls.Clear();
    RadToolTipManager3.TargetControls.Clear();
 
    //this is called from ajaxRequest() client side
    if (e.Argument == "ONE")
        grdONE.DataBind();
    else if (e.Argument == "TWO")
        grdTWO.DataBind();
}
 
protected void grdTWO_ItemDataBound(object sender, GridItemEventArgs e)
{
    ...
    this.RadToolTipManager1.TargetControls.Add(...)
    this.RadToolTipManager3.TargetControls.Add(...)
    ...
}
 
protected void OnAjaxUpdate(object sender, ToolTipUpdateEventArgs args)
{
 
    this.UpdateToolTip(args.Value, args.UpdatePanel);
}
private void UpdateToolTip(string elementID, UpdatePanel panel)
{
    ...
}


Any ideas?

Thanks for any help,
Robert 






Robert Helm
Top achievements
Rank 1
 answered on 21 May 2012
1 answer
66 views
When I click on the grid drag drop column, it highlights but is twice the size of the normal row.

What is the CSS responsible for the changing of this design?

.rgDragCol  ?

Richard
Top achievements
Rank 1
 answered on 21 May 2012
5 answers
114 views
How can i hide the control of detailview grid in hierarchical radgrid during the edit mode.
I have used the below cdoe to hide the control in itemdatabound event of grid:
  RadNumericTextBox t1 = (RadNumericTextBox)editItem["StartAge"].Controls[0];
                    t1.NumberFormat.DecimalDigits = 0;
                    t1.NumberFormat.GroupSeparator = "";
                    t1.NumberFormat.AllowRounding = false;
                    editItem["StartAge"].Visible = false;

it is hiding the control but how to hide the header: See below screenshot:

i.e. how to hide the Start Age caption.
Jayesh Goyani
Top achievements
Rank 2
 answered on 21 May 2012
3 answers
428 views
Hello,
I have a grid on Form A. I have data in the session variable which is set as the datasource in the grid's needdatasource

RadGridItems.DataSource = Session[cKIWebHelper.SelectListSessionVariables.const_Session_GridData];

Now, i display a popup form B

window.showModalDialog


then when I am finished doing what I have to do in the popup form I update data into the Session[cKIWebHelper.SelectListSessionVariables.const_Session_GridData]; (add records, remove records etc)

immediatlyl after I close the popup I would like to refresh the grid in Form A. How do I do FormA.RadGridItems.Databind() ?

Richard
Top achievements
Rank 1
 answered on 21 May 2012
1 answer
175 views
Hi 
   I have used Rad Grid where all the Column are set in ASPX page and the data for the grid is set from DataSource from the Server Side .After setting the data source i need to re arrange the column at different position which will be distinct compare to sequence which is set in the ASPX page .

ASPX page sequence is the default one but some time the sequence of the Column should be changed Programmatically after setting the DataSource 



Thanks in advance ,
Chethan Rajashekaraiah
Eyup
Telerik team
 answered on 21 May 2012
5 answers
124 views
hey guys, i noticed that on the RadFilter (not Grid Radfilter) - that when there's a drop down list and something is selected - it stays highlighted - i assume this is by design until of course you click the "Apply" button. in my scenario - i'd like to attach an Enter Key event to the page - which i've done & it works fine. However, when using the DropDown List - this isn't the case. it holds the focus until you say "tab" or do another action.
is there some client code that will give the control back to the page when something is selected??
thanks again for any suggestions on this.
rik
Tsvetina
Telerik team
 answered on 21 May 2012
1 answer
112 views
I need a timeline view just as your examples. categories type on rows, date on columns.
I want to bind their datasources to my businness object, I'm missing something cause nothing happens on the rows
I did this:

getAllTimeLineType and getAllAppointments return collections having IDCategory in common. I guess this is not what needed.

<telerik:RadScheduler runat="server" ID="RadScheduler1" SelectedView="TimelineView"
            OverflowBehavior="Expand"            
            Localization-HeaderMultiDay="Work Week"
            OnNavigationComplete="RadScheduler1_NavigationComplete"
            OnAppointmentInsert="RadScheduler1_AppointmentInsert"
            OnAppointmentUpdate="RadScheduler1_AppointmentUpdate"
            OnAppointmentDelete="RadScheduler1_AppointmentDelete"
            DataKeyField="ID"
            DataSubjectField="Subject"
            DataStartField="StartDate"
            DataEndField="EndDate"
            DataRecurrenceField="RecurrenceRule"
            DataRecurrenceParentKeyField="RecurrenceParentId"
            DataReminderField="Reminder"
            >
 
 
            <ResourceTypes>
                <telerik:ResourceType AllowMultipleValues="true" KeyField="IDCategory" Name="IDCategory" TextField="IDCategory" ForeignKeyField="IDCategory" />
            </ResourceTypes>
            
 
            <AdvancedForm Modal="true" />
             
              <Localization HeaderMultiDay="Work Week" />
 
            <TimelineView UserSelectable="true"
                        GroupBy="IDCategory"
                        GroupingDirection="Vertical" />
            <MultiDayView UserSelectable="true" />
            <DayView UserSelectable="false" />
            <WeekView UserSelectable="false" />
            <MonthView UserSelectable="false" />
              <Reminders Enabled="false" />
        </telerik:RadScheduler>
 
 
 
 
  Private Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
        Try
 
                Dim myBusinessResObj = New ADEPT.CScheduleResource(myConn)
                Dim resType1 As New ResourceType("IDCategory")               
                resType1.DataSource = myBusinessResObj.getAllTimelineType()
                resType1.KeyField = "IDCategory"
                resType1.TextField = "IDCategory"
                resType1.ForeignKeyField = "IDCategory"
                RadScheduler1.ResourceTypes.Add(resType1)
                RadScheduler1.GroupBy = "IDCategory"
 
 
 
                myBusinessObj = New ADEPT.CScheduler(myConn)
                RadScheduler1.DataSource = myBusinessObj.getAllAppointments
                myBusinessObj = Nothing
 
        Catch ex As Exception
             
        End Try
    End Sub
Ivana
Telerik team
 answered on 21 May 2012
1 answer
54 views

My RadGrid's used to display Page and Item counts in the bottom right of each Grid.  I recently upgraded Telerik from v2011.3.1305 to v2012.1.411.

The markup is as follows:

<telerik:RadGrid ID="AssetGrid" runat="server" AllowFilteringByColumn="True" AllowPaging="True"
    AllowSorting="True" GridLines="None" GroupingSettings-CaseSensitive="false" Skin="Web20"
    AutoGenerateColumns="False" OnPageIndexChanged="AssetGrid_PageIndexChanged" OnItemCreated="AssetGrid_ItemCreated"
    OnItemDataBound="AssetGrid_ItemDataBound"
    OnPreRender="AssetGrid_PreRender" OnSortCommand="AssetGrid_SortCommand" OnNeedDataSource="AssetGrid_NeedDataSource"
    EnableLinqExpressions="false">
    <ClientSettings EnableRowHoverStyle="true">
        <Selecting AllowRowSelect="true" />
        <ClientEvents OnRowDblClick="RowAssetSelected" />
    </ClientSettings>
    <MasterTableView EditMode="InPlace" AllowFilteringByColumn="true" ShowFooter="false"
        EnableColumnsViewState="true" AutoGenerateColumns="false" CellSpacing="-1" DataKeyNames="AsId"
        Font-Size="90%" AllowCustomSorting="true" AllowCustomPaging="true" Width="100%">
        <PagerStyle Mode="NextPrevAndNumeric" Visible="true" AlwaysVisible="true" />
        <!-- RowIndicatorColumn, ExpandCollapseColumn, Columns, etc -->
    </MasterTableView>
</telerik:RadGrid>
                

    The NeedDataSource event is as follows:

protected void AssetGrid_NeedDataSource(object source, GridNeedDataSourceEventArgs e)
{
    var collection = getAssets()
    AssetGrid.VirtualItemCount = collection.Count;
    AssetGrid.DataSource = collection.Skip(AssetGrid.PageSize *
        AssetGrid.CurrentPageIndex).Take(AssetGrid.PageSize);
}

Sorry if I've missed anything important.

The grid however, is displaying the pager row like this:

PageCountMissing

Is there a setting I've missed to enable the page/item counts in the bottom right?

Tsvetina
Telerik team
 answered on 21 May 2012
3 answers
126 views

Having problems with labels showing up in the right place or at all. I have multiple charts on one page and one chart has 4 series in it and I am using this code to set the lables positions but some of them dont show up at all.

Series2_3.Items[0].Label.Appearance.LabelLocation = Telerik.Charting.Styles.

 

StyleSeriesItemLabel.ItemLabelLocation.Outside;

 

Series2_3.Items[0].Label.Appearance.Position.AlignedPosition = Telerik.Charting.Styles.

 

AlignedPositions.Left;

also I am setting the label text  color to black but that doesn't work either

 

Series2_1.AddItem(itm2.AdministrativeServices,

 

"Administrative Services", Color.Black);


any suggestions?
Thanks!

 

Evgenia
Telerik team
 answered on 21 May 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?