Telerik Forums
UI for ASP.NET AJAX Forum
4 answers
205 views
Hi

I wanted to remove the Size column from the built in Media/Flash/Image Manager dialogs in the editor but on reading this posting it appears that the only solution is to hide it.

I have already customised the built in dialogs by extracting their .ascx files to a folder in my solution and from what I can see it appears that the FileBrowser.ascx is the file that i need to change.  The above posting suggests that I need to use the code below to hide the Size column.  What I cannot determine however is how to hook up this code.  There is no codebehind for fileBrowser.ascx and despite adding an inline Page_Load event to the fileBrowsers.ascx markup I cannot seem to tap into the page load event which would allow me to use the code below

GridColumn SizeColumn = RadFileExplorer1.Grid.Columns.FindByUniqueNameSafe("Size");
SizeColumn.ItemStyle.Width = Unit.Pixel(1);
SizeColumn.HeaderStyle.Width = Unit.Pixel(1);

Any suggestions on how I can achieve this ?

thanks in advance
Rumen
Telerik team
 answered on 06 Jan 2011
1 answer
223 views

Hello,

I have a problem with RadFormDecorator control.

Here is my code:

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default3.aspx.cs" Inherits="Default3" %>
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  
<head id="Head1" runat="server">  
    <title>Test Page</title>  
    <link rel="stylesheet" type="text/css" href="Skins/FormDecorator/00ccff/FormDecorator.00ccff.css" />
    <link rel="stylesheet" type="text/css" href="Skins/FormDecorator/00ff00/FormDecorator.00ff00.css" />
</head>  
<body>  
    <form id="form1" runat="server">  
    <telerik:RadScriptManager ID="RadScriptManager1" runat="server">  
    </telerik:RadScriptManager>  
    <telerik:RadFormDecorator runat="server" ID="RadFormDecorator1" Skin="00ccff" EnableEmbeddedSkins="false" DecoratedControls="CheckBoxes" DecorationZoneID="00ccffZoneID1" />
    <telerik:RadFormDecorator runat="server" ID="RadFormDecorator2" Skin="00ff00" EnableEmbeddedSkins="false" DecoratedControls="CheckBoxes" DecorationZoneID="00ff00ZoneID1" />
                                
    <span id="00ccffZoneID1" >
        <asp:CheckBox ID="CheckBox1" runat="server" />
    </span>
  
    <span id="00ff00ZoneID1">
        <asp:CheckBox ID="CheckBox2" runat="server" />
    </span>
    </form>  
</body>  
</html>

By running the above code using Chrome or Safari then I get the result which is shown in the attached image 1.jpg, and by running the above code using other browsers, I get the result which is shown in 2.jpg.

Here is FormDecorator.00ccff.css:
/* RadFormDecorator for ASP.NET 00ccff Skin */
  
/* CSS class for styling the decoration zone or the <html /> tag of the page */
.RadForm_00ccff.rfdZone
{
    background-color: Green;
    color:#00ccff;
}
  
  
/* Decorate <input type="checkbox" /> */
.RadForm_00ccff .rfdCheckboxUnchecked,
.RadForm_00ccff .rfdInputDisabled.rfdCheckboxUnchecked:hover
{
    background: transparent url('CheckBox/CheckBoxSprites.gif') no-repeat 0 0;
}
  
.RadForm_00ccff .rfdCheckboxUnchecked:hover
{
    background: transparent url('CheckBox/CheckBoxSprites.gif') no-repeat 0 -200px;
}
  
.RadForm_00ccff .rfdCheckboxChecked,
.RadForm_00ccff .rfdInputDisabled.rfdCheckboxChecked:hover
{
    background: transparent url('CheckBox/CheckBoxSprites.gif') no-repeat 0 -420px;
}
  
.RadForm_00ccff .rfdCheckboxChecked:hover
{
    background: transparent url('CheckBox/CheckBoxSprites.gif') no-repeat 0 -640px;
}
  
  
/* the styling of radiobuttons and checkboxes in Safari and Chrome is already fully achieved with CSS */
@media screen and (-webkit-min-device-pixel-ratio: 0)
{
    /* checkboxes */
    .rfdCheckbox input[type="checkbox"],
    .rfdCheckbox input[type="checkbox"][disabled]:hover
    {
        background-image: url('CheckBox/CheckBoxSprites.gif');
    }
}
  
@media screen and (-webkit-min-device-pixel-ratio: 0)
{
    /* checkboxes */
    #cc00ffZoneID1 input[type="checkbox"],
    #cc00ffZoneID1 input[type="checkbox"][disabled]:hover
    {
        background-image: url('CheckBox/CheckBoxSprites.gif');
    }
}

And FormDecorator.00ff00.css:
/* RadFormDecorator for ASP.NET 00ff00 Skin */
  
/* CSS class for styling the decoration zone or the <html /> tag of the page */
.RadForm_00ff00.rfdZone
{
    background-color: Green;
    color:#00ff00;
}
  
  
/* Decorate <input type="checkbox" /> */
.RadForm_00ff00 .rfdCheckboxUnchecked,
.RadForm_00ff00 .rfdInputDisabled.rfdCheckboxUnchecked:hover
{
    background: transparent url('CheckBox/CheckBoxSprites.gif') no-repeat 0 0;
}
  
.RadForm_00ff00 .rfdCheckboxUnchecked:hover
{
    background: transparent url('CheckBox/CheckBoxSprites.gif') no-repeat 0 -200px;
}
  
.RadForm_00ff00 .rfdCheckboxChecked,
.RadForm_00ff00 .rfdInputDisabled.rfdCheckboxChecked:hover
{
    background: transparent url('CheckBox/CheckBoxSprites.gif') no-repeat 0 -420px;
}
  
.RadForm_00ff00 .rfdCheckboxChecked:hover
{
    background: transparent url('CheckBox/CheckBoxSprites.gif') no-repeat 0 -640px;
}
  
  
/* the styling of radiobuttons and checkboxes in Safari and Chrome is already fully achieved with CSS */
@media screen and (-webkit-min-device-pixel-ratio: 0)
{
    /* checkboxes */
    .rfdCheckbox input[type="checkbox"],
    .rfdCheckbox input[type="checkbox"][disabled]:hover
    {
        background-image: url('CheckBox/CheckBoxSprites.gif');
    }
}
  
/* the styling of radiobuttons and checkboxes in Safari and Chrome is already fully achieved with CSS */
@media screen and (-webkit-min-device-pixel-ratio: 0)
{
    /* checkboxes */
    #00ff00ZoneID1 input[type="checkbox"],
    #00ff00ZoneID1 input[type="checkbox"][disabled]:hover
    {
        background-image: url('CheckBox/CheckBoxSprites.gif');
    }
}

Please, I need your help,
It is appreciated to send me the modified code.

Regards,
Bader
Georgi Tunev
Telerik team
 answered on 06 Jan 2011
1 answer
70 views
I would like to specify a start date and an end date, say January 5, 2011 to February 5, 2011. Within this range, I'd like to only show it Mon-Wed, and Sat-Sun. Is there a way to create a single appointment with that start and end date and create some sort of RecurrenceRule for this, or do I have to do a lot of manual work to make this scenario a reality?
Nikolay Tsenkov
Telerik team
 answered on 06 Jan 2011
8 answers
220 views
Hi,

I am using loading panel on one of my page. The problem I am experiencing is strange. When page loads for the first time, loading panel is shown as desired. On another button loading panel is not displayed.

If I click second button first, then loading panel is shown and not shown on the first button where it showed previously.

In short, it shows loading panel once the page loads and then it does not show up.

Please let me know if you need any other information from my end.
Atit Thaker
Top achievements
Rank 1
 answered on 06 Jan 2011
2 answers
85 views
Hi

I have here the following problem, wonder if it is a known issue:

Have a page with RadTabStrip, tabs generated by TabTemplates with DataSource provided. Tab Strip is set to be shorter than required to display all tabs ==> thus scrolling is there. Also there is function set for OnClientLoaded event.
Under normal circumstances:
 1) Tabs are loaded,
 2) tab strip scrollbar is displayed,
 3) function for OnClientLoaded event fires as required.

Now - I have added a RadButton with Text and ImageURL properties set as well as OnClientClicked pointing to existing function.
When I run page now, I see that:
 1) Tabs are loaded,
 2) tab strip scrollbar is NOT displayed, and tabs are NOT scrollable
 3) function for OnClientLoaded event does NOT fire
 4) RadButton is shown

are these two controls are incompatible or I am missing something?
I can set up some small sample demo if needed for investigation

Thanks,
Dmitry
Cori
Top achievements
Rank 2
 answered on 06 Jan 2011
1 answer
124 views
i want to find the textbox..?
aspx page
<EditItemTemplate>
                                        <asp:TextBox ID="txtState" TabIndex="1" Enabled="true" runat="server" Text='<%#Eval("MA")%>'></asp:TextBox>
                                        <asp:RequiredFieldValidator ID="reqFieldValGameState" runat="server" ErrorMessage="RequiredFieldValidator"
                                            ControlToValidate="txtState" Text="Please enter Game state."></asp:RequiredFieldValidator>
                                         <asp:CustomValidator ID="custmValState" runat="server" ControlToValidate ="txtState" OnServerValidate ="custmValState_ServerValidate"
                                        ErrorMessage="Invalid State."></asp:CustomValidator>
                                    </EditItemTemplate>

code behind
  protected void custmValState_ServerValidate(object sender, ServerValidateEventArgs e)
        {
            
            TextBox txtState = (TextBox)grdGameInfo.FindControl("txtState");
            string sGameState = txtState.Text;

            switch (sGameState.ToUpper())
            {
                case "MA":
                    e.IsValid = true;
                    break;
                case "DA":
                    e.IsValid = true;
                    break;
                default:
                    {
                        e.IsValid = false;
                        return;
                    }
            }
        }

How to find the textbox in edittemplate of grid . How to find the textbox ..above event is called OnServerValidate ="custmValState_ServerValidate"

Help Me urgent . how to find textbox  inside the "custmValState_ServerValidate"  function
Shinu
Top achievements
Rank 2
 answered on 06 Jan 2011
1 answer
235 views
How do I set the contenturl in this function?
I thought it would have been: pageView.contenturl = "blah", but this does not compile.

Private Sub AddTab(ByVal tabName As String)
        Dim tab As RadTab = New RadTab
        tab.Text = tabName
        radTabStrip.Tabs.Add(tab)
  
        Dim pageView As RadPageView = New RadPageView
        pageView.ID = tabName
        'pageView.
        RadMultiPage.PageViews.Add(pageView)
  
        radTabStrip.SelectedIndex = tab.Index
        radTabStrip.DataBind()
    End Sub
Shinu
Top achievements
Rank 2
 answered on 06 Jan 2011
1 answer
136 views
I am trying to use the ASP.NET AJAX File Explorer control.  The control loads fine initially, with the correct folders etc but when ever I click a folder to open, the waiting icon appears and then it hangs and the grid doesn't refresh.

I keep getting a Javascript error Sys.WebForms.PageRequestManagerParserErrorException 

I have pretty much copied the markup from the Live Demos page.  I am using the Q2 2009 ( I am unable to upgrade) controls with ASP.NET MVC 2 using Visual Studio 2010.

Can someone help me at all?

Thanks

Barry

Dobromir
Telerik team
 answered on 06 Jan 2011
2 answers
143 views
Hi,

 I am using RadCalendar in my app. While click on the particular date opening the RadWindow. In that RadWindow i am entering three values, After closing that window those entered values are displaying on the particular date.

Now in that main page RadCalendar Page : I have three textboxes...In that after closing that RadWindow. need to display the displayed values on the date....

ex: on the date 3 : has V=1, S=1, O=1 and date 7: has V=2 , S=1, O=2.

 Need to display those values and accumulate in to textboxes in the main pages
like:
  Vacation : 3
  Sick :2
 Other:3

Tell me how to do?
Maria Ilieva
Telerik team
 answered on 06 Jan 2011
10 answers
509 views
Hello,

I have a problem with the tooltip positioning with some elements on my page.  I am using the TooltipManager and geting tooltip using javacript.  It is working fine with the position untill I scroll down the page.After scoll down it is showing tooltip uper side of the element.  Here is my sample code:  
<telerik:RadToolTipManager runat="server" ID="RadTaskToolTipMgr" OffsetY="-3" Width="280" Height="80" Position="BottomCenter" RelativeTo="Element" Animation="None" HideEvent="LeaveToolTip" Text="Loading..." ShowEvent="OnClick" />

<script type="text/javascript">
function
GetTootltip(element, Task_id) {
var tooltipManager = $find("<%= RadTaskToolTipMgr.ClientID %>");
if (!tooltipManager) return;
var tooltip = tooltipManager.getToolTipByElement(element);
if (!tooltip) {
tooltip = tooltipManager.createToolTip(element);
$.ajax({
type:
"POST",
url:
"Get-Members.aspx",
data:
"Id=" + Task_id + "&For=Task",
success:
function(msg) { if (msg == "1") {
window.location =
"../login.aspx";
}
else
    tooltip.set_text(msg);
    element.onclick =
null
    element.onmouseover =
null;
tooltip.show();
}
}
});
}
else {
element.onclick =
null;
element.onmouseover =
null;
tooltip.show();
}
return false;
}
</script>
Svetlina Anati
Telerik team
 answered on 06 Jan 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?