Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
175 views
How is the way to add radAjaxPanel programmatically?
I have a MasterPage . I need added in content.
I tried with this in Init event of page:

         RadAjaxPanel radajaxPanel = new RadAjaxPanel();
         radajaxPanel.ID="RadAjaxPanel3";
         radajaxPanel.ClientEvents.OnRequestStart = "conditionalPostback";

         containerUpload.Controls.Add(radajaxPanel);           


but didn't work
thanks!
July
Top achievements
Rank 2
 answered on 03 Aug 2011
1 answer
229 views
Hi,
I have my RadWindow defined in one ascx file for example "controlParent". Content of this window is another ascx file for example "controlChild". How can I close my RadWindow by asp:button in control "controlChild" ?
My aspx file:
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server"/>
 <user:ContolParent runat="server" ID="cParent" />

ContorlParent.ascx:
<telerik:RadWindow ID="selectorPopupWindow" CssClass="rad_window" runat="server" Title="Galeria multimediów" Width="950" EnableEmbeddedSkins="false" Skin="MSIT_sitefinityLocal"
            Height="600" VisibleOnPageLoad="false" Behaviors="Minimize, Move, Maximize, Close"
            OffsetElementID="RadGrid1">
            <ContentTemplate>
                <user:ControlChild runat="server" ID = "cChild" />
            </ContentTemplate>
</telerik:RadWindow>


ContolChild.ascx:
Grids, TextBox etc.
<asp:Button runat="server" ID="btnCancel" Text="Cancel" />


I am thankful for any help,
Mateusz Wajcowicz
Kevin
Top achievements
Rank 2
 answered on 03 Aug 2011
1 answer
89 views

Hi,

We are using RadEditor with Ajax Tab Container.

We have three tabs in tab container.
Tab 1 - RadEditor
Tab 2 - .Net Grid View
Tab 3 - .Net Grid View

In IE browser, we don't face any issue, it is working fine.

In Firefox, we are facing the following issue,
    Whenever working with Rad editor in first tab, we don't have any issue.
    But whenever, we are working with second tab and coming back to first tab, the Editor alignment goes off and the buttons available at top (first row controls - e.g., spell checker ...) are displayed in the single column instead of single row, so the control enlarges and UI is affected. In the same situation, if we hit refresh (F5), then the control regains the original alignment and look & feel.
 
Please let us know, if we are missing something.

Regards,
Guru

Rumen
Telerik team
 answered on 03 Aug 2011
1 answer
125 views
Hi,

I'm using RadBinaryImage to render database stored imagery but, in a notification email i neet it to render instead of this:
<img id="propertyImg" src="Telerik.Web.UI.WebResource.axd?imgid=900376f0988148a1a0cdb64b64d02373&type=rbi" height="50" width="50">

I need it like this:
<img id="propertyImg" src="http://servername:serverport/Telerik.Web.UI.WebResource.axd?imgid=900376f0988148a1a0cdb64b64d02373&type=rbi" height="50" width="50">

Anyone has an idea how to make it happen?

Best Regards,
Vitor Monteiro

Maria Ilieva
Telerik team
 answered on 03 Aug 2011
2 answers
80 views
Hi,
I want to display a new child window(created by me) for creating a new appointment instead of the one which is built in Telerik Scheduler.
I have written java function to open the new window for 'OnClientTimeSlotClick' event. I want the new custom created window to open on double click of the timeslot, right now it is happening for single click as well. If I remove 'OnClientTimeSlotClick' from declaration, I get a small popup window with no controls on it. I want to get rid of that small popup and get my custom created screen as popup on double click of the timeslot. Please suggest.

Thanks,
Navya
Navya
Top achievements
Rank 1
 answered on 03 Aug 2011
4 answers
153 views
Hi
Is there a way to print the radgrid (ie to export and send it to printer) without opening in pdf/tiff files?

Appreciate your support.
Regards,
SR





Mohammed
Top achievements
Rank 1
 answered on 03 Aug 2011
1 answer
90 views
Team Telerik,

I've created a grid programatically and populate it with data.  The first two columns are frozen, and I'm able to scroll left and right with the horizontal scroll bar.  Everything looks wonderful.  However, when I click on any column header to sort the data (Frozen, or Data columns); the horizontal scroll bar disappears and the columns off screen become inaccessible.   Let me know if I've done anything wrong, below you will find my code.  When I remove FrozenColumnsCount from the code, everything works fine.  However... I do need the first two columns to be frozen.

Thanks,
Michael

protected void Page_Init(object source, System.EventArgs e)
{
    DefineGridStructure();
}
 
private void DefineGridStructure()
{
    var someTable = GetSomeTable();
 
    RadGrid radGrid1 = new RadGrid();
     
    radGrid1.ItemCommand += new GridCommandEventHandler(radGrid1_ItemCommand);
 
    radGrid1.PagerStyle.Mode = GridPagerMode.NextPrevAndNumeric;
    radGrid1.AutoGenerateColumns = false;
    radGrid1.ShowStatusBar = true;
    radGrid1.MasterTableView.DataKeyNames = new string[] { "Id" };
    radGrid1.DataSourceID = "ObjectDataSource1";
    radGrid1.AllowSorting = true;
    radGrid1.AllowPaging = true;
    radGrid1.PageSize = 50;
    radGrid1.Width = new Unit(99, UnitType.Percentage);
 
    radGrid1.MasterTableView.TableLayout = GridTableLayout.Fixed;
    radGrid1.ClientSettings.Scrolling.AllowScroll = true;
    radGrid1.ClientSettings.Scrolling.UseStaticHeaders = true;
    radGrid1.ClientSettings.Scrolling.FrozenColumnsCount = 2;
    radGrid1.ClientSettings.Scrolling.SaveScrollPosition = true;
     
 
    GridBoundColumn displayFrozenColumn = new GridBoundColumn();           
    displayFrozenColumn .DataField = "Name";
    displayFrozenColumn .HeaderText = "Name";
    displayFrozenColumn .HeaderStyle.Width = new Unit(200, UnitType.Pixel);
    displayFrozenColumn .ItemStyle.Font.Bold = true;                   
    radGrid1.MasterTableView.Columns.Add(displayFrozenColumn );
 
    displayFrozenColumn = new GridBoundColumn();               
    displayFrozenColumn .DataField = "Id";
    displayFrozenColumn .HeaderText = "Id";
    displayFrozenColumn .HeaderStyle.Width = new Unit(50, UnitType.Pixel);
    displayFrozenColumn .ItemStyle.Font.Bold = true;           
    radGrid1.MasterTableView.Columns.Add(displayFrozenColumn );
 
    foreach (DataColumn dataColumn in someTable.Columns)
    {
        if (dataColumn.ColumnName == "Name" || dataColumn.ColumnName == "Id")
            continue;
 
        GridButtonColumnWithFilteringSorting displayDataColumn = new GridButtonColumnWithFilteringSorting();               
        displayDataColumn .HeaderText = dataColumn.ColumnName;
        displayDataColumn .DataTextField = dataColumn.ColumnName;
        displayDataColumn .SortExpression = dataColumn.ColumnName;
        displayDataColumn .UniqueName = dataColumn.ColumnName;
        displayDataColumn .HeaderStyle.Width = new Unit(75, UnitType.Pixel);              
 
        radGrid1.MasterTableView.Columns.Add(displayDataColumn );
    }
     
 
    PlaceHolder placeHolder1 = (PlaceHolder)RadPanelBar1.FindItemByValue("PanelItem1").FindControl("PlaceHolder1");
    placeHolder1.Controls.Add( radGrid1 );
}
Pavlina
Telerik team
 answered on 03 Aug 2011
1 answer
87 views
I have a RadPanelBar that is databound.  Based on the values contained in the datasource, certain controls will be added to each child item.  Controls such as dropdown, listbox, multiple labels, textboxes and buttons are added.  On clicking a button or dropdown selectedindexchanged the controls disappear.  I have tried creating dynamic controls in PanelBar_prerender event and they are created appropriately and displayed on the initial page_load,

On the subsequent pages, unless I do a PanelBar.DataBind, I get weird situation where the first child item disappears and the last child item repeats.  On the next postback what was now the first child item will disappear and the last child item will now appear three times.

I have seen the example where panelitems are created in the page_load event.  However, what I have is a databound PanelBar.  I have seen references to "templateneeded" event, but none of the links seem to work to get to that article.

Can you provide an example of where controls are added dynamically to child panelitem when the PanelBar itself is databound and the dynamically created controls need to postback.

Thanks
Sumith
Kate
Telerik team
 answered on 03 Aug 2011
2 answers
150 views
I have 2 List Boxes. One with State the other with City. The City Listbox has Checkboxes. 
I am trying to find a way to have all the checkboxes 'checked' as the default when the page opens with a State Default selected.
For example ... When the page opens the State Selected Value is 'WA' and all the cities in Washington are displayed with checkboxes. Works fine.
But I want them displayed with Checkboxes 'Checked'

I have tried the collection method:
If Not Page.IsPostBack Then
    rlbAreas.SelectedValue = "F50"
    Dim collection As IList(Of RadListBoxItem) = rlbSubAreas.Items
    For Each item As RadListBoxItem In Collection
       item.Checked = True
   
Next End If

But the collection at this point returns 0 items. I tried rebinding the rlbSubAreas listbox but that didn't work either.

Anyone?
Thad
Top achievements
Rank 2
 answered on 03 Aug 2011
1 answer
195 views
I am trying to display the items inserted into the destination listbox when multiple items are selected from the source but the items inserted is only the ones that are not duplicates since allow dupliates is set to false.  Below is my code.  However,  I am getting the items selected.  How do I get only the items that were actully inserted since it is not adding the duplicates.

Protected

Sub rlDestinationGroup_Inserted(sender As Object, e As Telerik.Web.UI.RadListBoxEventArgs) Handles rlDestinationGroup.Inserted

  'gets the selected employee name

  Dim empName As String = rdCBEmpList.SelectedItem.Text

   lblMsg.Text = empName & " was added to the following group(s): "

 ' returns the list of items selected from the Source List

  For Each item As RadListBoxItem In rlGroupListSource.SelectedItems

 lblMsg.Visible = True

 lblMsg.Text += item.Text & ", "

 Next

 End Sub

Your assistance is appreciated.

 

Genady Sergeev
Telerik team
 answered on 03 Aug 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Jesse
Top achievements
Rank 2
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Jesse
Top achievements
Rank 2
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?