Telerik Forums
UI for ASP.NET AJAX Forum
0 answers
97 views
I using a javascript for type farsi (persian) language in textbox field. I add [lang="fa"] to textbox and include my java script file in aspx file
then i can type farsi in text box. but when i refresh or postback my page using radajaxpanel my script not working
see my code and please help me.

<%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default.aspx.vb" Inherits="_Default" %>
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<head runat="server">
    <title></title>
    <script src="FarsiType.js" type="text/javascript"></script>
</head>
<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
        <scripts>
            <%--Needed for JavaScript IntelliSense in VS2010--%>
            <%--For VS2008 replace RadScriptManager with ScriptManager--%>
            <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js" />
            <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js" />
            <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQueryInclude.js" />
        </scripts>
    </telerik:RadScriptManager>
    <script type="text/javascript">
        //Put your JavaScript code here.
    </script>
    <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" BackgroundPosition="Top">
    </telerik:RadAjaxLoadingPanel>
    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
        <ajaxsettings>
            <telerik:AjaxSetting AjaxControlID="button1" >
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="panel1" LoadingPanelID="RadAjaxLoadingPanel1" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </ajaxsettings>
    </telerik:RadAjaxManager>
    <asp:Button Text="refresh panel1" runat="server" ID="button1" />
    <asp:Panel ID="Panel1" runat="server" BackColor="Yellow">
        <p>
            panel1
        </p>
        textbox inside AjaxLoadingPanel:
        <asp:TextBox runat="server" lang="fa" ID="TextBox2" Font-Names="tahoma" />
        <br />
        <br />
    </asp:Panel>
    <p>
    </p>
    <hr />
    <asp:Panel ID="Panel2" runat="server" BackColor="Green">
        <p>
            panel2
        </p>
        textbox outside adAjaxLoadingPanel:
        <asp:TextBox ID="TextBox1" runat="server" lang="fa" Font-Names="tahoma" />
        <br />
        <br />
    </asp:Panel>
    <asp:Button Text="postback page" runat="server" ID="button2" />
    </form>
</body>
</html>

and my script file is : (Farsitype.js)
/*
FarsiType
Version: 1.3.6
 
This script developed to ease typing Farsi (Persian) in web forms where there is no Farsi Keyboard installed on a PC.
Works with Internet Explorer, FireFox, Opera and Chrome.
For more information and getting the using manual please visit the script website (http://www.farsitype.ir).
 
Copyright 2002-2011  Kaveh Ahmadi  (http://www.kavehahmadi.com, email: me@kavehahmadi.com).
Licensed under the GPL (http://www.opensource.org/licenses/gpl-license.php) license.
*/
 
// insertAdjacentHTML(), insertAdjacentText() and insertAdjacentElement() for Netscape 6/Mozilla by Thor Larholm me@jscript.dk
if (typeof HTMLElement!="undefined" && ! HTMLElement.prototype.insertAdjacentElement) {
    HTMLElement.prototype.insertAdjacentElement = function (where,parsedNode) {
        switch (where) {
            case 'beforeBegin':
                this.parentNode.insertBefore(parsedNode,this)
                break;
            case 'afterBegin':
                this.insertBefore(parsedNode,this.firstChild);
                break;
            case 'beforeEnd':
                this.appendChild(parsedNode);
                break;
            case 'afterEnd':
                if (this.nextSibling)
                    this.parentNode.insertBefore(parsedNode,this.nextSibling);
                else
                    this.parentNode.appendChild(parsedNode);
                break;
        }
    }
 
    HTMLElement.prototype.insertAdjacentHTML = function (where,htmlStr) {
        var r = this.ownerDocument.createRange();
        r.setStartBefore(this);
        var parsedHTML = r.createContextualFragment(htmlStr);
        this.insertAdjacentElement(where,parsedHTML)
    }
 
    HTMLElement.prototype.insertAdjacentText = function (where,txtStr) {
        var parsedText = document.createTextNode(txtStr)
        this.insertAdjacentElement(where,parsedText)
    }
}
 
var FarsiType = {
    // Farsi keyboard map based on Iran Popular Keyboard Layout
    farsiKey: [
        32, 33, 34, 35, 36, 37, 1548,   1711,
        41, 40, 215,    43, 1608,   45, 46, 47,
        48, 49, 50, 51, 52, 53, 54, 55,
        56, 57, 58, 1705,   44, 61, 46, 1567,
        64, 1616,   1584,   125,    1609,   1615,   1609,   1604,
        1570,   247,    1600,   1548,   47, 8217,   1583,   215,
        1563,   1614,   1569,   1613,   1601,   8216,   123,    1611,
        1618,   1573,   126,    1580,   1688,   1670,   94, 95,
        1662,   1588,   1584,   1586,   1740,   1579,   1576,   1604,
        1575,   1607,   1578,   1606,   1605,   1574,   1583,   1582,
        1581,   1590,   1602,   1587,   1601,   1593,   1585,   1589,
        1591,   1594,   1592,   60, 124,    62, 1617
    ],
    Type: true,
    counter: 0,
    ShowChangeLangButton: 1,    // 0: Hidden / 1: Visible
    KeyBoardError: 0,           // 0: Disable FarsiType / 1: Show Error
    ChangeDir: 2,           // 0: No Action / 1: Do Rtl-Ltr / 2: Rtl-Ltr button
    UnSupportedAction: 0        //0: Disable FarsiType / 1: Low Support
}
 
FarsiType.enable_disable = function(Dis) {
    var invis, obj;
     
    if (!Dis.checked)  {
        FarsiType.Type = true;
        disable = false;
        color = 'darkblue';
    } else {
        FarsiType.Type = false;
        disable = true;
        color = '#ECE9D8';
    }
 
    if (FarsiType.ShowChangeLangButton == 1) {
        for (var i=1; i<= FarsiType.counter; i++) {
            obj = document.getElementById('FarsiType_button_' + i);
            obj.disabled = disable;
            obj.style.backgroundColor = color;
        }
    }
}
 
FarsiType.Disable = function() {
    FarsiType.Type = false;
    var Dis = document.getElementById('disableFarsiType')
    if (Dis != null) {
        Dis.checked = true;
    }
 
    if (FarsiType.ShowChangeLangButton == 1) {
        for (var i=1; i<= FarsiType.counter; i++) {
            obj = document.getElementById('FarsiType_button_' + i);
            obj.disabled = true;
            obj.style.backgroundColor = '#ECE9D8';
        }
    }
}
 
FarsiType.init = function() {
 
    var Inputs = document.getElementsByTagName('INPUT');
    for (var i=0; i<Inputs.length; i++) {
        if (Inputs[i].type.toLowerCase() == 'text' && (Inputs[i].lang.toLowerCase() == 'fa' || Inputs[i].lang.toLowerCase() == 'fa-ir')) {
            FarsiType.counter++;
            new FarsiType.KeyObject(Inputs[i], FarsiType.counter);
        }
    }
 
    var Areas = document.getElementsByTagName('TEXTAREA');
    for (var i=0; i<Areas.length; i++) {
        if (Areas[i].lang.toLowerCase() == 'fa' || Areas[i].lang.toLowerCase() == 'fa-ir') {
            FarsiType.counter++;
            new FarsiType.KeyObject(Areas[i], FarsiType.counter);
        }
    }
     
    var Dis = document.getElementById('disableFarsiType')
    if (Dis != null) {
        FarsiType.enable_disable (Dis);
        Dis.onclick = new Function( "FarsiType.enable_disable (this);" )
    }
}
 
FarsiType.KeyObject = function(z,x) {
 
    GenerateStr = "";
    if (FarsiType.ShowChangeLangButton == 1) {
        GenerateStr = GenerateStr + "<input type='button' id=FarsiType_button_"+x+" style='border: none; background-color:darkblue; font-size:11; color:white; font-family:tahoma; padding: 1px; margin: 1px; width: auto; height: auto;' value='FA' /> ";
    }
    if (FarsiType.ChangeDir == 2) {
        GenerateStr = GenerateStr  + "<input type='button' id=FarsiType_ChangeDir_"+x+" style='border: none; background-color:darkblue; font-size:11; color:white; font-family:tahoma; padding: 1px; margin: 1px; width: auto; height: auto;' value='RTL' />"
    }
    z.insertAdjacentHTML("afterEnd", GenerateStr);
 
    if (FarsiType.ShowChangeLangButton == 1) {
        z.bottelm = document.getElementById ('FarsiType_button_' + x);
        z.bottelm.title = 'Change lang to english';
    }
    if (FarsiType.ChangeDir == 2) {
        z.Direlm = document.getElementById ('FarsiType_ChangeDir_' + x);
    }
 
    z.farsi = true;
    z.dir = "rtl";
    z.align = "right";
 
    z.style.textAlign = z.align;
    z.style.direction = z.dir;
 
    setSelectionRange = function(input, selectionStart, selectionEnd) {
        input.focus()
        input.setSelectionRange(selectionStart, selectionEnd)
    }
 
    ChangeDirection = function() {
        if (z.dir == "rtl") {
            z.dir = "ltr";
            z.align = "left";
            z.Direlm.value = "LTR";
            z.Direlm.title = "Change direction: Right to Left"
        } else {
            z.dir = "rtl";
            z.align = "right";
            z.Direlm.value = "RTL";
            z.Direlm.title = "Change direction: Left to Right"
        }
        z.style.textAlign = z.align;
        z.style.direction = z.dir;
        z.focus();
    }
 
    ChangeLang = function(e, ze) {
        if(ze)
            z = ze;
 
        if (FarsiType.Type) {
            if (z.farsi) {
                z.farsi = false;
                if (FarsiType.ShowChangeLangButton == 1) {
                    z.bottelm.value = "EN";
                    z.bottelm.title = 'Change lang to persian';
                }
                if (FarsiType.ChangeDir == 1) {
                    z.style.textAlign = "left";
                    z.style.direction = "ltr";
                }
            } else {
                z.farsi = true;
                if (FarsiType.ShowChangeLangButton == 1) {
                    z.bottelm.value = "FA";
                    z.bottelm.title = 'Change lang to english';
                }
                if (FarsiType.ChangeDir == 1) {
                    z.style.textAlign = "right";
                    z.style.direction = "rtl";
                }
            }
            z.focus();
        }
         
        if (e.preventDefault) e.preventDefault();
        e.returnValue = false;
        return false;
    }
 
    Convert = function(e) {
 
        if (e == null)
            e = window.event;
 
        var key = e.which || e.charCode || e.keyCode;
        var eElement = e.target || e.originalTarget || e.srcElement;
 
        if (e.ctrlKey && key == 32) {
            ChangeLang(e, z);
        }
 
        if (FarsiType.Type) {
            if (
                (e.charCode != null && e.charCode != key) ||
                (e.which != null && e.which != key) ||
                (e.ctrlKey || e.altKey || e.metaKey) ||
                (key == 13 || key == 27 || key == 8)
            ) return true;
 
            //check windows lang
            if (key > 128) {
                if (FarsiType.KeyBoardError == 0) {
                    FarsiType.Disable();
                } else {
                    alert("Please change your windows language to English");
                    return false;
                }
            }
 
            // If Farsi
            if (FarsiType.Type && z.farsi) {
 
                //check CpasLock
                if ((key >= 65 && key <= 90&& !e.shiftKey) || (key >= 97 && key <= 122 ) && e.shiftKey) {
                    alert("Caps Lock is On. To prevent entering farsi incorrectly, you should press Caps Lock to turn it off.");
                    return false;
                }
 
                // Shift-space -> ZWNJ
                if (key == 32 && e.shiftKey)
                    key = 8204;
                else
                    key = FarsiType.farsiKey[key-32];
 
                key = typeof key == 'string' ? key : String.fromCharCode(key);
 
                // to farsi
                try {
                 
                    var docSelection = document.selection;
                    var selectionStart = eElement.selectionStart;
                    var selectionEnd = eElement.selectionEnd;
 
                    if (typeof selectionStart == 'number') {
                        //FOR W3C STANDARD BROWSERS
                        var nScrollTop = eElement.scrollTop;
                        var nScrollLeft = eElement.scrollLeft;
                        var nScrollWidth = eElement.scrollWidth;
     
                        eElement.value = eElement.value.substring(0, selectionStart) + key + eElement.value.substring(selectionEnd);
                        setSelectionRange(eElement, selectionStart + key.length, selectionStart + key.length);
         
                        var nW = eElement.scrollWidth - nScrollWidth;
                        if (eElement.scrollTop == 0) { eElement.scrollTop = nScrollTop }
                    } else if (docSelection) {
                        var nRange = docSelection.createRange();
                        nRange.text = key;
                        nRange.setEndPoint('StartToEnd', nRange);
                        nRange.select();
                    }
     
                } catch(error) {
                    try {
                        // IE
                        e.keyCode = key
                    } catch(error) {
                        try {
                            // OLD GECKO
                            e.initKeyEvent("keypress", true, true, document.defaultView, false, false, true, false, 0, key, eElement);
                        } catch(error) {
                            //OTHERWISE
                            if (FarsiType.UnSupportedAction == 0) {
                                alert('Sorry! no FarsiType support')
                                FarsiType.Disable();
                                var Dis = document.getElementById('disableFarsiType')
                                if (Dis != null) {
                                    Dis.disabled = true;
                                }
                                return false;
                            } else {
                                eElement.value += key;                 
                            }
                        }
                    }
                }
 
                if (e.preventDefault)
                    e.preventDefault();
                e.returnValue = false;
            }
        }
        return true;
    }
 
    if (FarsiType.ShowChangeLangButton == 1) { z.bottelm.onmouseup = ChangeLang; }
    if (FarsiType.ChangeDir == 2) { z.Direlm.onmouseup = ChangeDirection; }
    z.onkeypress = Convert;
}
 
if (window.attachEvent) {
    window.attachEvent('onload', FarsiType.init)
} else if (window.addEventListener) {
    window.addEventListener('load', FarsiType.init, false)
}
Jamal Roshan
Top achievements
Rank 2
 asked on 17 May 2012
1 answer
180 views
I need show RadListBox with heigth = 100%
I try some css but does not work.
I have the same problem with Radgrid.

I see like this:


I need like this:


this is my code:

.css
div#container  { height:100%; width:100%; position: absolute;  display: block;}
div#leftContainer  { height:100%; width:25%; float:left;  }
div#middleContainer  { height:100%; width:25%;   float:left;}
div#rightContainer  { height:100%; width:40%;  float:left;  }

.aspx

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="DocumentTypeForm.aspx.cs"
    Inherits="WebSearch.UI.Admin.DocumentTypeForm" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
   
    <link href="../Style/Admin/DocumentType.css" rel="stylesheet" type="text/css" />
    <style type="text/css">
        .listBoxHeaders
        {
            color: Green;
            font-weight: bold;
        }
        
        
        
        
        .RadListBox span.rlbText em
        {
            background-color: #E5E5E5;
            font-weight: bold;
            font-style: normal;
        }
        
        .rbClear
        {
            background-image: url(/UI/Images/cross.png);
            background-position: center;
            background-repeat: no-repeat;
        }
    </style>
    <telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
        <script type="text/javascript">

            function confirmCallBackFn(arg) {

                var ajaxManager = $find("<%= RadAjaxManager1.ClientID %>");
                if (arg == true)
                { ajaxManager.ajaxRequest("Remove"); }

            }

            function CloseAndRebind(args) {

                GetRadWindow().BrowserWindow.refreshGrid(args);
                GetRadWindow().close();
            }

            function GetRadWindow() {
                var oWindow = null;
                if (window.radWindow) oWindow = window.radWindow; //Will work in Moz in all cases, including clasic dialog
                else if (window.frameElement.radWindow) oWindow = window.frameElement.radWindow; //IE (and Moz as well)

                return oWindow;
            }

            function CancelEdit() {
                GetRadWindow().close();
            }



                   
        </script>
    </telerik:RadCodeBlock>
</head>
<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager ID="RadScriptManager2" runat="server">
    </telerik:RadScriptManager>
    <telerik:RadCodeBlock ID="RadCodeBlock2" runat="server">
        <script type="text/javascript">

            function filterList() {
                var listbox = $find("<%= rlbAvailable.ClientID %>");
                var textbox = $find('<%= tbAvailableFilter.ClientID %>');

                clearListEmphasis(listbox);
                createMatchingList(listbox, textbox.get_textBoxValue());
            }

            // Remove emphasis from matching text in ListBox
            function clearListEmphasis(listbox) {
                var re = new RegExp("</{0,1}em>", "gi");
                var items = listbox.get_items();
                var itemText;

                items.forEach
                (
                    function (item) {
                        itemText = item.get_text();
                        item.set_text(itemText.replace(re, ""));
                    }
                )
            }

            // Emphasize matching text in ListBox and hide non-matching items
            function createMatchingList(listbox, filterText) {
                if (filterText != "") {
                    filterText = escapeRegExCharacters(filterText);

                    var items = listbox.get_items();
                    var re = new RegExp(filterText, "i");

                    items.forEach
                    (
                        function (item) {
                            var itemText = item.get_text();

                            if (itemText.match(re)) {
                                item.set_text(itemText.replace(re, "<em>" + itemText.match(re) + "</em>"));
                                item.set_visible(true);
                            }
                            else {
                                item.set_visible(false);
                            }
                        }
                    )
                }
                else {
                    var items = listbox.get_items();

                    items.forEach
                    (
                        function (item) {
                            item.set_visible(true);
                        }
                    )
                }
            }

            function rlbAvailable_OnClientTransferring(sender, eventArgs) {
                // Transferred items retain the emphasized text, so it needs to be cleared.
                clearListEmphasis(sender);
                // Clear the list. Optional, but prevents follow up situation.
                clearFilterText();
                createMatchingList(sender, "");
            }

            function rbtnClear_OnClientClicking(sender, eventArgs) {
                clearFilterText();

                var listbox = $find("<%= rlbAvailable.ClientID %>");

                clearListEmphasis(listbox);
                createMatchingList(listbox, "");
            }

            // Clears the text from the filter.
            function clearFilterText() {
                var textbox = $find('<%= tbAvailableFilter.ClientID %>');
                textbox.clear();
            }

            // Escapes RegEx character classes and shorthand characters
            function escapeRegExCharacters(text) {
                return text.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&");
            }

        </script>
    </telerik:RadCodeBlock>
    <telerik:RadAjaxLoadingPanel runat="server" Skin="Vista" ID="LoadCombo" />
    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" OnAjaxRequest="RadAjaxManager1_AjaxRequest">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="rlbChosen">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="litnow" LoadingPanelID="LoadginPanel1" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManager>
    <div class="TabContainer">
        <telerik:RadTabStrip ID="RadTabStrip1" runat="server" Skin="Vista" MultiPageID="RadMultiPage1"
            SelectedIndex="0" CssClass="tabStrip" Width="698px">
            <Tabs>
                <telerik:RadTab Value="Information">
                </telerik:RadTab>
                <telerik:RadTab Value="Fields">
                </telerik:RadTab>
            </Tabs>
        </telerik:RadTabStrip>
        <telerik:RadMultiPage ID="RadMultiPage1" runat="server" SelectedIndex="0" CssClass="multiPage">
            <telerik:RadPageView ID="RadPageViewInformation" runat="server" Width="100%">
                <div class="TabTitle">
                    <asp:Label ID="lblTitleTab1" runat="server"></asp:Label>
                </div>
                <asp:Table ID="Table3" CssClass="EditFormTable" runat="server">
                    <asp:TableRow>
                        <asp:TableCell CssClass="CellLabelLTW">
                            <asp:Label runat="server" ID="lblName" CssClass="fontLabel" /></asp:TableCell><asp:TableCell
                                CssClass="CellTextBoxL">
                                <asp:TextBox ID="txtName" MaxLength="250" CssClass="TextBoxPopUp" Text='<%# Bind("Name") %>'
                                    runat="server">
                                </asp:TextBox><asp:RequiredFieldValidator ID="rfFirstName" runat="server" ErrorMessage="*"
                                    ControlToValidate="txtName" CssClass="validator" ValidationGroup="Information" />
                                <asp:CustomValidator ID="cvName" runat="server" ValidationGroup="Information" CssClass="validator"
                                    ControlToValidate="txtName" OnServerValidate="cvName_OnServerValidate" />
                            </asp:TableCell>
                        <asp:TableCell CssClass="CellLabelRTW" />
                        <asp:TableCell CssClass="CellTextBoxR" />
                    </asp:TableRow>
                    <asp:TableRow>
                        <asp:TableCell CssClass="CellLabelLTW">
                            <asp:Label runat="server" ID="lblDescription" CssClass="fontLabel" /></asp:TableCell><asp:TableCell
                                CssClass="CellTextBoxL">
                                <asp:TextBox ID="txtDescription" MaxLength="250" CssClass="TextBoxPopUp" Text='<%# Bind("Description") %>'
                                    runat="server">
                                </asp:TextBox><asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server"
                                    ErrorMessage="*" ControlToValidate="txtName" CssClass="validator" ValidationGroup="Information" />
                            </asp:TableCell>
                        <asp:TableCell CssClass="CellLabelRTW" />
                        <asp:TableCell CssClass="CellTextBoxR" />
                    </asp:TableRow>
                </asp:Table>
            </telerik:RadPageView>
            <telerik:RadPageView ID="RadPageViewField" runat="server" Width="100%" >
                <div class="TabTitle">
                    <asp:Label ID="lblFields" runat="server"></asp:Label>
                </div>
                <div class="listBoxHeaders">
                    <span style="margin-left: 50px;">
                        <asp:Literal runat="server" ID="litAvailable" />
                    </span><span style="margin-left: 136px;">
                        <asp:Literal runat="server" ID="litOnDcumentType" /></span> <span style="margin-left: 200px">
                            Properties </span>
                </div>
                <div>
                    <table style="position: relative; left: -3px; margin-bottom: 2px;">
                        <tr>
                            <td>
                                <telerik:RadTextBox ID="tbAvailableFilter" runat="server" Width="187px" autocomplete="on"
                                    onkeyup="filterList();" />
                            </td>
                            <td>
                                <telerik:RadButton ID="rbtnClear" runat="server" Width="22px" AutoPostBack="false"
                                    OnClientClicking="rbtnClear_OnClientClicking">
                                    <Icon PrimaryIconCssClass="rbClear" />
                                </telerik:RadButton>
                            </td>
                        </tr>
                    </table>
                </div>
                <div id="container">
                    <div id="leftContainer">
                        <telerik:RadListBox ID="rlbAvailable" runat="server" Width="100%" AllowTransfer="true"
                            AllowTransferOnDoubleClick="true" TransferToID="rlbChosen" SelectionMode="Multiple"
                            EnableDragAndDrop="true" AllowReorder="true" DataTextField="Header" DataValueField="Id"
                            Sort="Ascending" OnClientTransferring="rlbAvailable_OnClientTransferring" ButtonSettings-ShowTransferAll="true">
                        </telerik:RadListBox>
                    </div>
                    <div id="middleContainer">
                        <telerik:RadListBox ID="rlbChosen" runat="server" Sort="Ascending" Width="100%" AutoPostBack="true"
                            OnSelectedIndexChanged="rlbChosen_SelectedIndexChange" SelectionMode="Multiple"
                            EnableDragAndDrop="true" AllowReorder="true" DataTextField="Header" DataValueField="Id">
                        </telerik:RadListBox>
                    </div>
                <div id="rightContainer">
                         <div> <asp:Label ID="lblDataTypeLabel" runat="server"></asp:Label>
                          <asp:Label ID="lblDataType" runat="server"></asp:Label>
                          </div>
                       
                    
                     <%-- <telerik:RadTabStrip ID="RadTabStrip2" runat="server" Skin="Vista" MultiPageID="RadMultiPage2"
                                SelectedIndex="0" CssClass="tabSubStrip" Width="698px">
                                <Tabs>
                                    <telerik:RadTab Value="Mask">
                                    </telerik:RadTab>
                                    <telerik:RadTab Value="Rules" Enabled="false">
                                    </telerik:RadTab>
                                </Tabs>
                            </telerik:RadTabStrip>--%>
                </div>
                <div class="clear">
                </div>
                </div>
                <div class="clear">
                </div>
                
            </telerik:RadPageView>
        </telerik:RadMultiPage>
    </div>
    <div class="Clear">
    </div>
    <div class="footerSave" runat="server">
        <asp:Table ID="Table2" runat="server" Width="100%" HorizontalAlign="Right">
            <asp:TableRow>
                <asp:TableCell HorizontalAlign="center">
                    <telerik:RadButton ID="btnSave" runat="server" Skin="Vista" Width="100px" OnClick="btnSave_OnClick" />
                    <telerik:RadButton ID="btnCancel" runat="server" Skin="Vista" Width="100px" CausesValidation="False"
                        ToolTip="Cancel" OnClientClicked="CancelEdit" />
                    <telerik:RadButton ID="btnDelete" runat="server" Skin="Vista" Width="100px" CausesValidation="False"
                        ToolTip="Remove current User" OnClick="btnDelete_OnClick" />
                </asp:TableCell></asp:TableRow>
        </asp:Table>
    </div>
    <telerik:RadWindowManager ID="RadWindowManager1" runat="server" EnableShadow="true">
        <Windows>
            <telerik:RadWindow ID="FieldFormDialog" runat="server" Height="600px" Width="900px"
                Skin="Vista" Left="15%" ReloadOnShow="true" ShowContentDuringLoad="false" Modal="true"
                VisibleStatusbar="false" Behaviors="Close" />
        </Windows>
    </telerik:RadWindowManager>
    </form>
</body>
</html>



regards
Dimitar Terziev
Telerik team
 answered on 17 May 2012
3 answers
196 views
I want to know, if exist some way, that i can do a radchart works with a tooltip, and scrolling, because if i enable scroll, tooltips doesnt work anymore.
<telerik:RadChart ID="RadChart1" runat="server" AutoLayout="True" OnItemDataBound="RadChart1_ItemDataBound"
          Skin="Windows7" Width="1200px">
          <ChartTitle TextBlock-Text="Gráficos">
          </ChartTitle>
          <Series>
              <telerik:ChartSeries DataYColumn="Vr_Lcto" Name="Series 1" Type="Line">
                  <Appearance>
                      <TextAppearance TextProperties-Font="Arial, 8.25pt" />
                      <PointMark Visible="True" Border-Width="2" Border-Color="White" Dimensions-AutoSize="false"
                          Dimensions-Height="12px" Dimensions-Width="12px">
                          <FillStyle MainColor="186, 207, 141" FillType="solid">
                          </FillStyle>
                      </PointMark>
                      <LineSeriesAppearance Width="5" />
                  </Appearance>
              </telerik:ChartSeries>
          </Series>
          <PlotArea>
              <XAxis DataLabelsColumn="Cd_Tp_Cnt">
                  <Appearance>
                      <TextAppearance TextProperties-Font="Arial, 8.25pt, style=Bold" />
                      <LabelAppearance RotationAngle="30">
                      </LabelAppearance>
                  </Appearance>
              </XAxis>
              <YAxis AxisMode="Extended">
                  <Appearance>
                      <TextAppearance TextProperties-Font="Arial, 8.25pt, style=Bold" />
                  </Appearance>
              </YAxis>
          </PlotArea>
          <Legend Visible="false"></Legend>
      </telerik:RadChart>
      <telerik:RadToolTipManager ID="RadToolTipManager1" runat="server" Skin="Windows7"
          Width="200px" Animation="Slide" Position="TopCenter" EnableShadow="true" ToolTipZoneID="RadChart1"
          AutoTooltipify="true">
      </telerik:RadToolTipManager>


Thankz in advance!
Giuseppe
Telerik team
 answered on 17 May 2012
2 answers
61 views
hi,

I can not find the package for sharepoint 2010 and sharepoint 2003 of rad editor. can you show me the link of them?

thanks,

Macro
vv
Top achievements
Rank 1
 answered on 17 May 2012
9 answers
220 views
I have created fully dynmic grid with item template as total all through programming code .
Now am facing a difficutly .. i have put a Update buton since i have textboxes where user can change input in dynamic grid
I TRY To update on onclickevent
but am not able to access grid at all 
grid.columns.count is alwazz null ..
i need to loop to get the dynamic ids ... but am not able to access to elements in dynamic grid .


protected void lnkUpdateAll_Click(object sender, EventArgs e)
        {
    for (int OuterCol = 1; OuterCol < gridCntrl.Columns.Count; OuterCol++) -->getting zero :( 
            {
                GridTemplateColumn templateColumn = new GridTemplateColumn();
              string templateColumnName = ds.Tables[0].Columns[OuterCol].ColumnName;

                for (int inner = 0; inner < gridCntrl.Items.Count; inner++)
                {
                    double total;
                    string id;
                    if (true)
                    {
                id = (gridCntrl.Items[OuterCol].FindControl(templateColumnName) as RadNumericTextBox).Text.ToString();
                        total = double.Parse((gridCntrl.Items[OuterCol].FindControl(templateColumnName)as RadNumericTextBox).Value.ToString()); ;

}
                      

                    }
 
Jayesh Goyani
Top achievements
Rank 2
 answered on 17 May 2012
3 answers
306 views
Hi Team Telerik,

On my page, I have 2 user controls (uc1) and (uc2). Both of them are placed inside the panel. This first user control (uc1) is having RadTabStrip. If user clicks on that it’ll allow uc2 to perform action and gets visible then. But, I was getting the full post back, which I don’t want to perform actually. I want that it should have partial post back instead of full page post back.
I have tried implementing this with "RadAjaxManager" to the page so that the entire user control (uc2) will get refreshed. But, when I click on the RadTabStrip which is been bounded programmatically in first user control (uc1), it throws a java script error message. Please refer following error message:
“Webpage error details
User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; GTB7.3; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E; MS-RTC LM 8; InfoPath.3)
Timestamp: Sat, 28 Apr 2012 14:02:19 UTC
Message: 'EditModeStylectl00_cphLeft_ReportPage1_Filter1_FilterSte...' is undefined
Message: Object expected”

I am using the following code in Page_Prerender() event.
         RadAjaxManager manager = RadAjaxManager.GetCurrent(Page);
        manager.AjaxSettings.AddAjaxSetting(radAjaxPanel, radAjaxPanel);
I am not sure, what would be the exact reason behind it.
 It would be a really great if you could provide any help on this.

Thanks,
Maria Ilieva
Telerik team
 answered on 17 May 2012
3 answers
39 views
Hi,
i am facing the problem while moving the code from Design mode to Html Mode. please see the Generated code below
test telerik Editor<p>&nbsp;</p>Test
Thanks,
Rumen
Telerik team
 answered on 17 May 2012
1 answer
111 views
What I'd like to do is create a series of custom skins (3) and allow users to change the "look and feel" of the application by selecting from a dropdown list.  We currently have this working by pointing to the Telerik.web.ui.skins.dll which gives a complete list of skins.  Has anyone created their own skins and done what I have mentioned above?  Any help would be appreciated.

Rich
Bozhidar
Telerik team
 answered on 17 May 2012
1 answer
101 views
I want to position the TextBlock label for the YAxis2 closer to the actual chart (too much space imo).  I am not sure which attribute will do this (move label left).  Any help?
Petar Marchev
Telerik team
 answered on 17 May 2012
4 answers
114 views
Hello,

Am using vb.net
I have master table and detail table in Radgrid.
Now how to export only detail table records to excel & pdf?

Thank you
Jayanthi
Daniel
Telerik team
 answered on 17 May 2012
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?