Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
127 views
I have a default loading panel set because I want pretty much everything to use it except for one thing. Is there a way to exclude something? Here's a condensed version of what I'm hoping to make work:

<telerik:RadAjaxManager runat="server" DefaultLoadingPanelID="loadingPanel">
  <AjaxSettings>
    <telerik:AjaxSetting AjaxControlID="btnLoad">
      <UpdatedControls>
        <telerik:AjaxUpdatedControl ControlID="rgResults"/>
        <telerik:AjaxUpdatedControl ControlID="lblResults"/>
      </UpdatedControls>
    </telerik:AjaxSetting>
    <telerik:AjaxSetting AjaxControlID="txtIDs">
      <UpdatedControls>
        <telerik:AjaxUpdatedControl ControlID="rtb1"/>
        <telerik:AjaxUpdatedControl ControlID="rtb2"/>
      </UpdatedControls>
    </telerik:AjaxSetting>
  </AjaxSettings>
</telerik:RadAjaxManager>

I know I can just leave out a default loading panel and explicitly set a loading panel for the ones I want, like so:

<telerik:AjaxUpdatedControl ControlID="rgResults" LoadingPanelID="loadingPanel"/>
<telerik:AjaxUpdatedControl ControlID="lblResults"/>

But if all but one are going to use the loading panel, it's less wordy to do it the other way.
Maria Ilieva
Telerik team
 answered on 15 Jan 2013
1 answer
99 views
Hi,

I have this scenario:
Two controls (say controlA and controlB), both contain some RadButtons. If a click occurs in controlA, it should update controlB and vice versa. But only case 1 works, case 2 doesn't work correctly.

This is my code:
protected override void OnPreRender(EventArgs e)
      {
         base.OnPreRender(e);
 
         RadAjaxManager manager = RadAjaxManager.GetCurrent(Page);
         manager.AjaxSettings.AddAjaxSetting(controlA, controlB, loadingPanel);
         manager.AjaxSettings.AddAjaxSetting(controlB, controlA, loadingPanel);
      }

The second case only works after one click, e.g. the second, third, ... click works correctly and the loading panel will be displayed.
Both controls don't have any conditional controls, all buttons are added in CreateChildControl. EnsureChildControls is called in OnLoad of both controls.

Which of the controls might be erroneous in this case? The control which does the trigger or the control which is updated?
Maria Ilieva
Telerik team
 answered on 15 Jan 2013
3 answers
140 views
Hi there,

In a section of our page, we have three radGrids, each of which control the visibility of a asp:button (for example if rows.count > 0). Now that we are rolling out AJAXified grids across our application, we have reached this page and noticed that there are a number of issues introduced once we apply AJAX on these grids.

We have a function that is called in pageLoad and ItemCreated (for the affected grids) which determines the visibility of the above button. However we have noticed that once the grid is AJAXified, and the button is added as an UpdatedControl of the grid, the visibility of the button is not affected by this function, even if we removed all items in the grid.

However, if I were to reload the page after removing all items in the grid, the button would be hidden as the above visibility function would return a False, but ideally we would like this to be done during the AJAX request of the grid.

Is there something that we are missing here??

Hope you can help

Regards

A.

<telerik:AjaxSetting AjaxControlID="radFScore">
    <UpdatedControls>
        <telerik:AjaxUpdatedControl ControlID="radFScore" LoadingPanelID="RadAjaxLoadingPanel1" />
    </UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="radFScore">
    <UpdatedControls>
        <telerik:AjaxUpdatedControl ControlID="btnPreview"/>
    </UpdatedControls>
</telerik:AjaxSetting>

Maria Ilieva
Telerik team
 answered on 15 Jan 2013
1 answer
88 views
I wonder how easy to persist the uploaded files in ASP.NET Session instead of writing them into the temporary folder?

Btw, is it allowed to prevent writing files into the temp folder? 
Peter Filipov
Telerik team
 answered on 15 Jan 2013
5 answers
110 views
I have a treeview and a context menu based on the examples on this website, with some added functionality.

When right clicking on a node and adding a new node, the node is put into edit mode. If I change the name of the newly created node (I set a default value in code behind), the NodeEdit server side event fires, which is what I want.

However, if I do not change the name, the server side event does not fire. This is likely by design. However, in the case where I am creating new nodes, I need that server event to fire anyway.

Is there a way to do this?

Greg
Martin
Top achievements
Rank 1
 answered on 15 Jan 2013
4 answers
155 views
I have a strange problem with recurring events.

I have a recurring event scheduled once a week with no end date.

When I start my application I open the RadScheduler in week view, and the recurring event is shown as it should. But if I go to the next week the event is not shown.

If I then switch to month view the recurring event is shown, but only the one in the week I was in before I switch to month view.
Then, if I switch back to week view, the event is shown for that week, even if it wasn't before.

In my application I also have a RadCalendar, where the dates with appointments are bold. To do this, in the AppointmentDataBound event of the RadScheduler I use the e.Appointment.RecurrenceRule to add the dates to the SpecialDays collection of the RadCalendar. This works fine, so I don't think there is anything wrong with the recurring event itself, just the way it is displayed in the RadScheduler.

The same behavior also happens if I have recurring event scheduled once a day, and also if I vary the number of occurrences, end dates etc

Any ideas?

Regards, Jill-Connie Lorentsen
Plamen
Telerik team
 answered on 15 Jan 2013
1 answer
129 views
hi everyone, i am new to telerik controls, i have a rad file explorer, code of my explorer is below

 <table cellspacing="4">
        <tr>
            <td rowspan="2" style="vertical-align: top;">
                Browse to an image and double click to preview.
                <telerik:RadFileExplorer runat="server" ID="FileExplorer2" Width="520px" Height="520px"
                    OnClientItemSelected="OnClientItemSelected" 
                    OnClientDelete="OnClientDelete"                     
                    EnableAsyncUpload="True" 
                   >
                    <Configuration ViewPaths="~/Images" UploadPaths="~/Images"
                        DeletePaths="~/Images"></Configuration>
                </telerik:RadFileExplorer>
            </td>
            <td>
                <div id="decoratedZoneFiledset">
                    <fieldset style="width: 230px; height: 220px; margin-top: 14px;">
                        <legend>Preview</legend>
                        <img id="pvwImage" src="Images/Northwind/Flowers/Flower1.jpg" alt="Flower1.jpg"
                            style="display: none; margin: 10px; width: 200px; height: 180px; vertical-align: middle;" />
                    </fieldset>
                </div>
            </td>
        </tr>
        <tr>
            <td valign="top" id="decoratorZone">
               
                <asp:Button ID="Button1" runat="server" Text="Submit" />
            </td>
        </tr>
    </table>
i give uploadpath,viewpath, deletepath initially temperary as the upload button should appear,
i want this, when i click on upload button in code behind i want setting a path from my controls like dropdown.selectedvalue/textbox/imgname how i get this, any help will be appreciated. 
thanks in advance :)
Vessy
Telerik team
 answered on 15 Jan 2013
1 answer
88 views
Hi Team ,
 i have use in my website Telrik conrol and red grid.
but paging is not working in redgird.

aspx code:<telerik:RadGrid ID="gvLookupData" OnPageIndexChanged="gvLookupDataPageIndexChanged" OnSelectedIndexChanged="gvLookupData_SelectedIndexChanged" OnItemDataBound="gvLookupData_ItemDataBound" OnItemCommand="gvLookupData_ItemCommand" runat="server" AllowPaging="True" AutoGenerateEditColumn="false" AutoGenerateColumns="false" CellPadding="3"GridLines="None"PageSize="1"><MasterTableView><Columns> <telerik:GridBoundColumn UniqueName="Key_Id" HeaderText="KeyId" Visible="true"ReadOnly="true" DataField="Key_Id"></telerik:GridBoundColumn></Columns></MasterTableView></telerik:RadGrid>

Cs code:
 protected void gvLookupDataPageIndexChanged(object sender, Telerik.Web.UI.GridPageChangedEventArgs e)
    {
        int index = e.NewPageIndex;
        int current = gvLookupData.CurrentPageIndex;
    }

 public void BindGrid( )
    {
        DataSet ds = (new Linx2DB()).RED_GetLookupHierarchicalData().ExecuteDataSet();
        gvLookupData.DataSource = ds;    
        gvLookupData.CurrentPageIndex = gvLookupData.MasterTableView.CurrentPageIndex;
        gvLookupData.DataBind();
        
    }

 

protected void Page_Load(object sender, EventArgs e)
    {BindGrid();
}

    }

 

Regards
Ashish

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 


Princy
Top achievements
Rank 2
 answered on 15 Jan 2013
1 answer
72 views
I have some users in that for one users set_text property is not working 
for renaming users it is working Hear is my code.Unable to find any 
script errors also.

    var cellMachinery = MasterTable.getCellByColumnUniqueName(row, "MachineryName");
    var cellApplPoint = MasterTable.getCellByColumnUniqueName(row, "ApplPoint");
    var text = cellMachinery.textContent.trim() + "  " + cellApplPoint.textContent.trim();
    var combo = $find("<%= ddlMapModel.ClientID %>");
    combo.set_text(text);
Boyan Dimitrov
Telerik team
 answered on 15 Jan 2013
0 answers
95 views
Hi,

I have 2 projects:

1) Simple test project - I create RadContextMenu that is associated with grid's row and it appears normally. I create it programmatically in Page_Init event. I don't use ContextMenuControlTarget. Telerik's grid and RadContextMenu are inside user control. The code looks as following:

public partial class GridUserControlDynamic : System.Web.UI.UserControl
{
    public RadContextMenu contextMenu = new RadContextMenu();
 
    protected void Page_Init(object sender, EventArgs e)
    {
        contextMenu.ID = this.GridControl.ID + "_RadMenu";
        RadMenuItem item1 = new RadMenuItem("Add");
        RadMenuItem item2 = new RadMenuItem("Edit");
        RadMenuItem item3 = new RadMenuItem("Delete");
        RadMenuItem item4 = new RadMenuItem("Parus");
        contextMenu.Items.Add(item1);
        contextMenu.Items.Add(item2);
        contextMenu.Items.Add(item3);
        contextMenu.Items.Add(item4);
        contextMenu.ItemClick += contextMenu_ItemClick;
        Controls.Add(contextMenu);

2) Complex project - I create RadContextMenu that should be associated with grid's row but it doesn't appear at all. I create it without ContextMenuControlTarget programmatically in OnInit method. But when I use ContextMenuControlTarget it appears but it's available not only on grid's row but in grid's header too. I don't need it in grid's header. The code looks as following:

protected override void OnInit(EventArgs e)
{
    base.OnInit(e);
 
    ...
 
    // Grid context menu section
    var contextMenu = new Parus.Controls.GridContextMenu();
    var target = new ContextMenuControlTarget();
    target.ControlID = this.Grid.ID;
    contextMenu.ID = this.Grid.ID + "_RadMenu";
    CreateContextItems(contextMenu.Items, this.Frame.ViewFrameData.ActionItems);
    contextMenu.LinkedControlClientId = ServerRequest.ClientID;
    contextMenu.OnClientItemClicked = "GridContextMenu_ActionsHandler";
    contextMenu.Targets.Add(target);
    this.PostbackPanel.ContentTemplateContainer.Controls.Add(contextMenu);

The CreateContextItems method add items to context menu.

How to get rid of context menu appearance in grid's header?

Goran
Goran
Top achievements
Rank 1
 asked on 15 Jan 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?