Telerik Forums
UI for ASP.NET AJAX Forum
7 answers
323 views
Hello

I wonder if there is an easy way to get a radwindow confirmation on a RadButton like there is on RadGrid's GridButtonColumn.

Regards
Mihai
Jonx
Top achievements
Rank 2
 answered on 18 Jan 2011
2 answers
72 views
Hi, I just upgraded my controls in my working DNN 5.6 project from 2010.3.1215.35 to 2010.3.1317.35.  After the upgrade the SelectedItems collection is always empty.  I have a grid control and respond to NeedDataSource.  The data displays properly and I can select a few rows after which I enter a button event handler where I retrieve the selected items.  Inspection of the control shows the data source is null, however, a 2nd request for data is never issued by the control.  After doing nothing in the button's event handler the page is displayed with the original data.

Telerik.Web.UI is not in the GAC

The proper dll version is in the DNN\bin folder

I cleared all Telerik.Web.UI dlls from C:\Windows\Microsoft.NET

I have a updated the binding redirect:
        <bindingRedirect oldVersion="2010.2.929.35" newVersion="2010.3.1317.35" xmlns="urn:schemas-microsoft-com:asm.v1" />

This was working perfectly before the upgrade.  Any ideas as to what happened and how to fix it?

Ed
Top achievements
Rank 1
 answered on 18 Jan 2011
5 answers
254 views
I'm running Dot Net Nuke 5.6, VS 2010 and Telerik 2010.3 and have a catch 22.  It seems that I have multiple web.config files and maybe some conflicts.

I have the Telerik tag defined in my web.config located in the virtual directory of my site.

To use a Telerik control on my page in the VS 2010 designer I need to have a web.config file local to the project that defines the Telerik tag:

<configuration>
  <system.web>

    <pages>

    <controls>

      <add tagPrefix="telerik" namespace="Telerik.Web.UI" assembly="Telerik.Web.UI"/>


Without it I get the error:

Error Creating Control - radGridCustomerPoolThis control cannot be displayed because its TagPrefix is not registered in this Web Form.

However, with a local web.config in the project folder I get the following error on my page in a browser outside the VS environment.

DotNetNuke.Services.Exceptions.ModuleLoadException: It is an error to use a section registered as allowDefinition='MachineToApplication'  beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS.

Why isn't VS picking up the tag definition in the virtual directory?

Any ideas?
Ed
Top achievements
Rank 1
 answered on 18 Jan 2011
1 answer
54 views
I am trying to set the content and I am getting a ReadFile error. BC30451: 'ReadFile' is not declared. It may be inaccessible due to its protection level.
On a different page, the code works. But whenever I create a new page, it will not allow me to enter the code. I dont know what is going on.


Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
    If Not Page.IsPostBack Then
        Dim temp As String = Request.QueryString("temp")
        Dim path As String = Server.MapPath("~") & "/Admin/Templates/Template" & temp & ".htm"
        RadEditor1.Content = ReadFile(path)
    End If
End Sub

Please help.
Chad Canterbury
Top achievements
Rank 1
 answered on 18 Jan 2011
3 answers
72 views
Firstly let me state my problem, which has recurred a lot of times over several years of telerik product usage.

Because Telerik tools are so reliable, I seldom upgrade. I have never had a problem within telerik tools being created by installing a newer version. Maybe I am unique in this, but I doubt it.
So, this brings me into a situation where I download and evaluate new versions very seldom, in regard to the release cycles.

The problem, is that there is no place, as far as I can see, where I can download ALL release notes between versions X and Y. Not that by stating as far as I can see I am intentionally leaving the door open for flames, being semi-blind, and a moron. I willingly agree to all this to get the list I need.

Because frequently (every 6mo or so) I find myself needing a bugfix or feature, and googling will show that the fix has been implemented in version X.
Like today, I was looking for radeditor width fix in IE8 and FF4.
http://www.telerik.com/community/forums/aspnet-ajax/editor/radeditor-width-problem.aspx
So. Then I find that it is indeed possible to update, and my specific problem has already been fixed.
Now in order to evaluate my update from earlier versions, I can tell that the version I have is Y (Q2 2010) from the excellent version listing at:
http://www.telerik.com/products/aspnet-ajax/whats-new/release-history.aspx

In order to evaluate, I would need to find all applicable changenotes, in ONE GO, and then evaluate those against the used features in our current err 9 sites.
However, there is no apparent or easy way to find all radeditor only applicable release or change notes between Q2 2010 and Q3 2010 SP1.
I always go for the latest to alleviate my next need for a fix.

Without a means to do this, I manually have to compile a huge list of changes, then evaluate the radeditor specific changes against my sharepoint 2007, 9 existing sites and each of their used features. They all have separate custom editor toolfiles, skins, css files, everything.

Otherwise of course I won't get the stakeholders (site owners and editors) approval for the new version. By the time I get agreement there's probably a new version out again.
And, yes, this is in part due to our being a government entity.
Then there's deployment, testing, integration testing, QA testing and production.


So, please Telerik take into consideration a way to make documentation regarding changes available for customers with valid support contracts at least, where some page would pull change and fix notes from version  X upgrading to version Y, for download or reading.

At least in customers with multiple stakeholders and formal approval processes, this would REALLY make my day. Err year. And next year too.
Pavel
Telerik team
 answered on 18 Jan 2011
1 answer
92 views
I have a basic menu placed on a page with the menu being loaded in the Page_Load event.  Currently, whenever I start the menu in the latest IE or Firefox, only the last menu item (furthest to the right) is visible and selectable.  The rest of the menu does not appear until after I either resize the browser or hover over the last menu item, then the menu appears and works correctly going forward.

The page is fairly simple and is as follows:
<form id="form1" runat="server" style="height:100%;width:100%;">
  
<telerik:RadScriptManager ID="ScriptManager" runat="server" />
<div style="margin:0; width:100%; display:block; background-color:Black;">
    <telerik:RadMenu ID="RadMenuMain" runat="server" EnableRoundedCorners="true" EnableShadows="true" OnClientItemClicked="menuItemClicked">
    </telerik:RadMenu>
</div>
<iframe id="Iframe1" scrolling="auto" width="100%" height="100%" frameborder="0">
</iframe>
</form>

Any help or ideas are welcome.

Thank you.
Justin
Top achievements
Rank 1
 answered on 18 Jan 2011
1 answer
97 views
I just upgraded to the latest release ASP.NET AJAX Q3 v2010.3.1317.40.
When I right click on a scheduler item to access the menu, I get the following error:

"Microsoft JScript runtime error: 'findItemByValue(...)' is null or not an object"

And debugging takes me to this line in ScriptResource.axd...
"l.findItemByValue("CommandEdit").set_enabled(true);"

Any ideas? Thanks for any info.

Peter
Telerik team
 answered on 18 Jan 2011
1 answer
188 views
Hi,

I have created a combo box that has custom item template. Each item is visualized as a checkbox and the value is kept as a hidden field, also inside the item template. The purpose is to allow multiple items to be selected at once (don't ask why, it was a client requirement). Also, we should not do any postback to the sever on each selection, instead, when the server code first attempts to get the selected items, each item is looped and depending on the state of the checkbox, a collection of selected items is being assembled. So far, everything works as expected, but the only issue I am having is when I click on the label of a checkbox item, or on the page right after blurring the items list, a postback event occurs. I have set both the RadComboBoxand the checkboxes AutoPostBack to 'false'. Any idea where this postback comes from and a way to disable it?

Here is a quick code example:
<telerik:RadComboBox ID="RadComboBox" runat="server" AllowCustomText="false" AutoPostBack="false">
    <ItemTemplate>
        <asp:CheckBox
            ID="CheckBox"
            runat="server"
            Text='<%# Eval(DataTextField ?? "Text") %>'
            AutoPostBack="false"
            ClientIDMode="Predictable"
            />
        <asp:HiddenField ID="HiddenField" runat="server" Value='<%# Eval(DataValueField ?? "Value") %>' ClientIDMode="Predictable" />
        <asp:HiddenField ID="CheckedHiddenField" runat="server" Value='False' ClientIDMode="Predictable" />
    </ItemTemplate>
</telerik:RadComboBox>

Here is how I collect the items:

private ICollection<RadComboBoxItem> GetItems()
        {
            return RadComboBox.Items.Aggregate(
                new List<RadComboBoxItem>(),
                (list, item) =>
                {
                    var checkBox = item.Controls.OfType<CheckBox>().First();
                    var hidden = item.Controls.OfType<HiddenField>().First();
                    var selectedHidden = item.Controls.OfType<HiddenField>().Last();
 
                    if (bool.Parse(selectedHidden.Value))
                    {
                        list.Add(new RadComboBoxItem(checkBox.Text, hidden.Value) { Selected = true });
                    }
                    return list;
                });
             
        }

And here is the clientside function that I am attaching to the checkbox event:
protected override void OnPreRender(EventArgs e)
        {
            base.OnPreRender(e);
             
            RadComboBox.Items.ToList().ForEach(ProcessItem);
        }
 
        private void ProcessItem(RadComboBoxItem item)
        {
            var checkbox = item.Controls.OfType<CheckBox>().Single();
            var hidden = item.Controls.OfType<HiddenField>().First();
            var selectedHidden = item.Controls.OfType<HiddenField>().Last();
            checkbox.InputAttributes["onchange"] = string.Format(
                "multiselectComboBoxItemClick('{0}', '{1}', '{2}', '{3}', '{4}');",
                RadComboBox.ClientID,
                checkbox.ClientID,
                hidden.ClientID,
                selectedHidden.ClientID,
                checkbox.Text);
        }
and the js code:
function multiselectComboBoxItemClick(comboBoxID, checkBoxID, valueHiddenFieldID, stateHiddenFieldID, itemText) {
    var combo = $find(comboBoxID);
    var checkbox = document.getElementById(checkBoxID);
    var hidden = document.getElementById(valueHiddenFieldID);
    var selectedHidden = document.getElementById(stateHiddenFieldID);
 
    if (!combo || !checkbox || !hidden) {
        return;
    }
 
    if (!combo['__SelectedItems']) {
        combo['__SelectedItems'] = [];
    }
    if (!combo['__SelectedItemsMap']) {
        combo['__SelectedItemsMap'] = {};
    }
 
    var value = hidden.value.toString();
                         
    if (checkbox.checked == true) {
        var item = combo['__SelectedItemsMap'][value];
        if (!item) {
            item = new Telerik.Web.UI.RadComboBoxItem();
            item.set_text(itemText);
            item.set_value(value);
            combo['__SelectedItemsMap'][value] = item;
            Array.add(combo['__SelectedItems'], item);
        }
        selectedHidden.value = 'True';
    } else {
        var item = combo['__SelectedItemsMap'][value];
        if (item) {
            var index = $telerik.$.inArray(item, combo['__SelectedItems']);
            if (index != -1) {
                combo['__SelectedItems'].splice(index, 1);
                combo['__SelectedItemsMap'][value] = null;
            }
        }
        selectedHidden.value = 'False';
    }
 
    var text = '';
    if (combo['__SelectedItems'].length > 0) {
        text = combo['__SelectedItems'][0].get_text();
        for (var i = 1; i < combo['__SelectedItems'].length; i++) {
            text = text + ', ' + combo['__SelectedItems'][i].get_text();
        }
    }
    combo.set_text(text);
}
Simon
Telerik team
 answered on 18 Jan 2011
2 answers
186 views
I am using a menu control to track a 5 step process where the user views 5 web pages. The menu corresponds to the 5 pages but I am using the menu as "step 1", "step2", etc..

So when the user views a page, I want the corresponding menu graphic to show as completed. This would mean that by the time they reach step 5/page 5 ...all of the menu steps will show the completed graphic for the menu item

Every time the user views one of the pages, I was just going to write a bool to a cookie. Here is an example:

   public Boolean Step1Status
        {
            get
            {
                if (HttpContext.Current.Request.Cookies["Step1"] != null)
                {
                    return Convert.ToBoolean(HttpContext.Current.Request.Cookies["Step1"].Value);
                }
                else
                {
                    return false;
                }

            }
            set
            {
                //Write Cookie &  Timeout
                HttpCookie StepStatus = new HttpCookie("Step1");
                StepStatus.Value = value.ToString();                
                HttpContext.Current.Response.Cookies.Add(StepStatus);
            }
        }
Then I was going to write an if statement that checks to see if  each of the steps exist and for the ones that do exist, change:
currentItem.Selected = true;

How do I get each of the menu items so I can set its selected value to true?

Also, is this over complicating things or is there a better way to track the pages the user has viewed and change the menu item to a different graphic?

Thanks for any advice.


MissioDei
Top achievements
Rank 1
 answered on 18 Jan 2011
2 answers
224 views
What can I do to address this issue?

Thanks.



<%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %>
<!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></title>
    <style type="text/css">
       
          
        .myRadButton.rbToggleButton
        {
            color: #000;
            font-size: 10px !important;
            text-decoration: none !important;
        }
          
        .myRadButton.rbToggleButton:hover
        {
            color: #863d02;
        }
          
        .myRadButton.rbToggleButton .rbText
        {
            text-align: left !important;
            padding-left: 20px !important;
            font-size: 10px !important;
        }
          
        .myRadButton.rbToggleButton.rbDisabled, .myRadButton.rbToggleButton:hover
        {
            color: #6a6a6a;
            font-size: 10px !important;
            text-decoration: none !important;
        }
    </style>
</head>
<body>
    <form id="form1" runat="server">
    <asp:ScriptManager ID="ScriptManager1" runat="server">
    </asp:ScriptManager>
    <telerik:RadButton ID="btnOffice" runat="server" ButtonType="ToggleButton" ToggleType="CustomToggle"  CssClass="myRadButton" Enabled=false
       Width="100%" Text="CheckBox">
        <ToggleStates>
            <telerik:RadButtonToggleState PrimaryIconCssClass="rbToggleCheckbox"
                Text="test" />
            <telerik:RadButtonToggleState PrimaryIconCssClass="rbToggleCheckboxChecked"
                Text="test" />
        </ToggleStates>
    </telerik:RadButton>
    </form>
</body>
</html>
Adam
Top achievements
Rank 1
 answered on 18 Jan 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?