Telerik Forums
UI for ASP.NET AJAX Forum
4 answers
73 views
I have a tree list where drag/drop is enabled. To do this I set AllowItemsDragDrop to true and added this line
 <ClientEvents OnItemDropping="itemDropping" OnTreeListCreated="function(sender) { treelist1 = sender; }" />

Method itemDropping verifies if the item being dragged is allowed and if the location where the item is being dropped is allowed. If not, an alert appears and the method returns. If all is ok I use fireCommand to initiate a server side method.

Since my treelist is ajax enabled the server side method was not triggered. To resolve this I added a ClientEvents-OnRequestStart method to the RadAjaxManager control to determine if the event target is my treelist control. If it is then I have set_enableAjax(false);  The problem with this is that the treelist doesn't refresh after the drop (and my RegisterClientScriptBlock doesn't execute). The odd thing is that if I replace the set_enableAjax(false) in my ClientEvents-OnRequestStart method with an alert('any text will do') then the server side method executes.

Any thoughts?

Thanks.
Robin
Top achievements
Rank 1
 answered on 08 Nov 2012
1 answer
96 views
We are using RadTextBox and specifying the text box widths, but in IE 7 Standards Mode the input widths are not enforced, resulting in very small input boxes (approx. 30px wide). How can this be fixed?

Below is one example:

<telerik:RadTextBox Width=""300px"" produces this HTML: 

<span class=""riSingle RadInput RadInput_Vista"" id=""tbTestGroupName_wrapper"" style=""width: 300px;"">

<input name=""rdCreateNewTestGroup$C$tbTestGroupName"" tabIndex=""301"" class=""riTextBox riEnabled rfdDecorated"" id=""tbTestGroupName"" style=""width: 100%;"" type=""text"" size=""20"" _events=""[object Object]"" control=""[object Object]"" RadInputValidationValue=""""/>                                       


Note the span tag has a style with width 300px. The span wraps an input tag with a width of 100% and a size of 20...   We assume the width 100% means the input width will stretch to fit the 300px wide span tag. This works in IE 8 Standards Mode but not in IE 7 Standards Mode. Not sure why the size="20" is in there but it doesn't seem to have an effect.

Since the input's width 100% is specified as an in-line style, it can't be overridden from the css file even when using !important.  #tbTestGroupName [style] {width:300px !important;} in the css file for overriding the in-line style is supported in IE 8, but not IE 7.

Also, we are using the transitional doctype (see below). Should this doctype be different?

<!-- DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" -->


Any help would be much appreciated as we're on a tight deadline. =(

Angel Petrov
Telerik team
 answered on 08 Nov 2012
4 answers
524 views
I have a fairly simple application I'm currently roughing out.

I have a screen with a RadGrid.  This is bound by a query to a Linq data source.  (Not the control, a direct call to the context using a Linq query.)   I've defined a FormTemplate popup with a bound RadComboBox on it.  The RadComboBox is bound in the ItemCreatedEvent.

Basically everything is working perfectly except that the combo box will not drop down when I click on it.  If it has the focus I can change the setting by using the arrow keys and when I save, the changes are properly saved.  It just won't drop down. 

(Actually this is only true in IE and FireFox.  When it comes up in Chrome, it displays the correct value but then if I click on it and try to use the arrows, it goes blank.)

I probably should mention that when I replace the RadComboBoxes with ordinary Asp.Net dropdown lists, everything works fine.
Boris
Top achievements
Rank 1
 answered on 08 Nov 2012
1 answer
45 views
I inserted file ".flv" flowing :
<object width="150" height="150" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000">
<param value="/Upload/News/Video/08092012232957.flv" name="Movie">
<param value="false" name="play">
<param value="high" name="quality">
<param value="false" name="loop">
<param value="false" name="menu">
<embed width="150" height="150" menu="false" loop="false" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" src="/Upload/News/Video/08092012232957.flv">
</object>


But  when I run it in browse it do not play.??
Dobromir
Telerik team
 answered on 08 Nov 2012
1 answer
634 views
Hi:
My web page loads really slow after i have added a editor control on the page.

I am using IE 9 to test. I can see "Telerik.Web.UI.WebResource.axd?_TSM_HiddenField_=RadScriptManager1_TSM&compress=1&_TSM_CombinedScripts_=%3b%3bSystem.Web.Extensions%2c+Version%3d3.5.0.0%2c+Culture%3dneutral%2c+PublicKeyToken%3d31bf3856ad364e35%3aen%3a553a4a13-b3a5-4e6b-a152-b131051f1788%3aea597d4b%3ab25378d2%3bTelerik.Web.UI%2c+Version%3d2011.3.1305.35%2c+Culture%3dneutral%2c+PublicKeyToken%3d121fae78165ba3d4%3aen%3ac331b262-facd-47ae-9de3-......" is pending when using IE developer tools to check the network.  After a while, the page will be loaded and the size of the file is around 1MB. 

I am just wondering if there is a way to optimize that. I have searched other related issues but could not solve this performance issue.

thanks in advance.


Nikolay
Telerik team
 answered on 08 Nov 2012
2 answers
144 views
HI,

I am working on Radtab ondemand loading. When i click on the tab i just want to load that tab. I see your example but you are loading .ascx page on demand. Can i use aspx pages.  I have 10 tabs with 10 pageviews. first 2 pageviews have grids within the pageview itself  and other 8 tabs when i clcik on the tab i want to show different aspx pages in that associated pageview. NavigateURL is not wotking for my scenario. How to achive this scenario. ANy example would be best for me to understand. I tried the way in your example but its throwing some error for aspx pages. Here is my sample code Please look into it. Thanks.

<telerik:RadTabStrip ID="RadTabSieHistory" runat="server" Skin="Vista" MultiPageID="RadMultiPageSieHistory"
    OnTabClick="RadTabSieHistory_TabClick">
    <Tabs>
        <telerik:RadTab Text="Search Results" PageViewID="RPVSearchResults">
        </telerik:RadTab>
        <telerik:RadTab Text="Process Flow" PageViewID="RPVProcessFlow">
        </telerik:RadTab>
        <telerik:RadTab Text="Task History" PageViewID="EditWinTaskHistory">
        </telerik:RadTab>
        <telerik:RadTab Text="Order Details" PageViewID="RPVOrdDetails">
        </telerik:RadTab>
        <telerik:RadTab Text="Fiber Details" PageViewID="RPVFiberDet">
        </telerik:RadTab>
        <telerik:RadTab Text="Dependencies" PageViewID="RPVDependncy">
        </telerik:RadTab>
        <telerik:RadTab Text="Jeopardy" PageViewID="RPVJeop">
        </telerik:RadTab>
        <telerik:RadTab Text="Attachments" PageViewID="RPVAttachments">
        </telerik:RadTab>
        <telerik:RadTab Text="Notes" PageViewID="RPVNotes">
        </telerik:RadTab>
    </Tabs>
</telerik:RadTabStrip>
<telerik:RadMultiPage ID="RadMultiPageSieHistory" runat="server" BorderStyle="Solid"
    BorderWidth="1px" BackColor="White" BorderColor="Black" OnPageViewCreated="RadMultiPageSieHistory_PageViewCreated">
    <telerik:RadPageView ID="RPVSearchResults" runat="server">
        <asp:label id="lblMsg" runat="server" font-bold="True" font-size="10pt" backcolor="Yellow"
            forecolor="Black"></asp:label>
        <div style="text-align: right; font-size: 8pt" id="div1" runat="server">
            <asp:linkbutton id="lnkbtnViewAll" onclick="lnkbtnViewAll_Click" runat="server" text="View All"></asp:linkbutton>
              Total Records found: <asp:label id="lblTotRecCount" font-bold="True"
                runat="server" forecolor="Black" font-size="10pt" text="0"></asp:label>
        </div>
        <div style="overflow: auto; height: 460px">
            <asp:gridview id="gvSites" borderwidth="0px" borderstyle="None" runat="server" backcolor="White"
                bordercolor="White" cellspacing="1" allowpaging="True" width="98.6%" onrowdatabound="gvSites_RowDataBound"
                onselectedindexchanged="gvSites_SelectedIndexChanged" onpageindexchanging="gvSites_PageIndexChanging"
                pagesize="15" allowsorting="True" onsorting="gvSites_Sorting" autogeneratecolumns="False"
                onrowcommand="gvSites_RowCommand">
                <AlternatingRowStyle Font-Size="8pt" BackColor="#F5F5E9" BorderWidth="0px" BorderColor="White" />
                <Columns>
                    <asp:TemplateField>
                        <ItemTemplate>
                            <asp:Image ID="imgOrdStat" runat="server" />
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:BoundField DataField="OrderType" />
                    <asp:BoundField DataField="LineOfBusiness" SortExpression="LineOfBusiness" HeaderText="LOB" />
                    <asp:BoundField DataField="DivisionName" SortExpression="DivisionName" HeaderText="Division Name" />
                    <asp:BoundField DataField="MarketName" SortExpression="MarketName" HeaderText="Region/ Market Name" />
                    <asp:BoundField DataField="CarrierName" SortExpression="CarrierName" HeaderText="Customer Name" />
                    <asp:BoundField DataField="HeadendName" SortExpression="HeadendName" HeaderText="Headend Name" />
                    <asp:BoundField DataField="ProjectName" SortExpression="ProjectName" HeaderText="Project Name" />
                    <asp:BoundField DataField="siteId" SortExpression="siteId" HeaderText="site Id" />
                    <asp:BoundField DataField="SiteName" SortExpression="SiteName" HeaderText="Site Name" />
                    <asp:BoundField DataField="Address" SortExpression="Address" HeaderText="Site Address" />
                    <asp:BoundField DataField="quoteId" SortExpression="quoteId" HeaderText="Quote ID" />
                    <asp:BoundField DataField="PTD" SortExpression="PTD" HeaderText="PTD" />
                    <asp:BoundField DataField="orderStatus" SortExpression="orderStatus" HeaderText="Order Status" />
                    <asp:BoundField DataField="orderId" />
                    <asp:BoundField DataField="MixedOrder" HeaderText="MixOrd" />
                    <asp:BoundField DataField="ServiceOrderNumber" HeaderText="Service Order Number"
                        SortExpression="Service Order Number" />
                    <asp:TemplateField Visible="False">
                        <ItemTemplate>
                            <asp:Label ID="lblOrdType" runat="server" Text='<%# Bind("orderTypeDesc") %>'></asp:Label>
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField>
                        <ItemTemplate>
                            <asp:ImageButton ID="imgDet" ToolTip="View network diagram" CommandName="Details"
                                ImageUrl="Images/Details.gif" runat="server" />
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField>
                        <ItemTemplate>
                            <asp:ImageButton ID="imgMixDet" ToolTip="View Mixed Order Details" CommandName="Mixed"
                                ImageUrl="Images/MIXED.png" runat="server" Visible="false" />
                        </ItemTemplate>
                    </asp:TemplateField>
                </Columns>
                <FooterStyle BackColor="White" ForeColor="#000066" BorderWidth="0px" />
                <HeaderStyle Height="20px" BackColor="#004000" Font-Size="8pt" Font-Bold="True" ForeColor="White"
                    HorizontalAlign="Center" BorderWidth="0px" />
                <PagerSettings Mode="NumericFirstLast" />
                <PagerStyle HorizontalAlign="Right" Font-Bold="True" Font-Size="8pt" />
                <RowStyle ForeColor="#3C5F22" Font-Size="8pt" BackColor="White" BorderWidth="0px"
                    BorderColor="White" />
            </asp:gridview>
        </div>
    </telerik:RadPageView>
    <telerik:RadPageView ID="RPVProcessFlow" runat="server">
        <div style="overflow: auto; width: 100%; overflow-y: hidden" align="center">
            <syncfusion:diagramwebcontrol cssclass="diadisplay" bordercolor="White" borderstyle="NotSet"
                borderwidth="0" id="DiagramWebControl1" runat="server" width="100%" waitingpopuptext="Processing"
                dbclicktimeoutdelay="1" disabledbackgroundcolor="LightBlue" waitingpopupautoformat="Indicator"
                boundaryconstraintsenabled="True" documentid="f69befd0-b591-42af-a1c6-377dd730c290"
                enablexhtml="true" height="485px" onnodeclick="DiagramWebControl1_NodeClick" />
        </div>
    </telerik:RadPageView>
    <telerik:RadPageView ID="RPVTskHis" runat="server">
    </telerik:RadPageView>
    <telerik:RadPageView ID="RPVOrdDetails" runat="server">
    </telerik:RadPageView>
    <telerik:RadPageView ID="RPVFiberDet" runat="server">
    </telerik:RadPageView>
    <telerik:RadPageView ID="RPVDependncy" runat="server">
    </telerik:RadPageView>
    <telerik:RadPageView ID="RPVJeop" runat="server">
    </telerik:RadPageView>
    <telerik:RadPageView ID="RPVAttachments" runat="server">
    </telerik:RadPageView>
    <telerik:RadPageView ID="RPVNotes" runat="server">
    </telerik:RadPageView>
</telerik:RadMultiPage>
protected void RadMultiPageSieHistory_PageViewCreated(object sender, RadMultiPageEventArgs e)
    {
        //if (e.PageView.ID.ToLower() == "rpvtskhis")
        //{
        //    Page.LoadControl("EditWinTaskHistory.aspx");
        //}
        //else if (e.PageView.ID.ToLower() == "rpvorddetails")
        //{
        //    Page.LoadControl("EditWinOrderData.aspx");
        //}
        //else if (e.PageView.ID.ToLower() == "rpvfiberdet")
        //{
        //    Page.LoadControl("EditWinFiberConstructionCost.aspx");
        //}
 
        if(e.PageView.ID == "EditWinTaskHistory")
            Page.LoadControl("EditWinTaskHistory.aspx");
 
        //string userControlName = e.PageView.ID + ".aspx";
 
        //Control userControl = Page.LoadControl(userControlName);
        //userControl.ID = e.PageView.ID + "_userControl";
 
        //e.PageView.Controls.Add(userControl);
    }
 
    protected void RadTabSieHistory_TabClick(object sender, RadTabStripEventArgs e)
    {
        if (e.Tab.Index != 0 && e.Tab.Index != 1)
        {
            AddPageView(e.Tab);
            e.Tab.PageView.Selected = true;
        }
    }
 
    private void AddPageView(RadTab tab)
    {
        RadPageView pageView = new RadPageView();
        pageView.ID = tab.PageViewID;
        RadMultiPageSieHistory.PageViews.Add(pageView);
        tab.PageViewID = pageView.ID;
    }
Gia
Top achievements
Rank 1
 answered on 08 Nov 2012
7 answers
146 views
heey guys 

I have a problem how can I get the department with the all current Users I created a View that connect this both tables(user/department) 

but i got this strange error (Must declare the scalar variable "@UserId".) 

my coder






protected
void LoadDE(string businessUnitId)
       {
           SqlConnection connection = new SqlConnection(ConfigurationManager.ConnectionStrings["HolidayTrackerConnectionString"].ConnectionString);
 
           SqlDataAdapter adapter = new SqlDataAdapter("SELECT * FROM DepartmentView  WHERE BusinessUnitId=@BusinessUnitId AND UserId=@UserId", connection);
           adapter.SelectCommand.Parameters.AddWithValue("@BusinessUnitId", businessUnitId);
           DataTable dt = new DataTable();
           adapter.Fill(dt);
 
           rcbDepartments.DataTextField = "Name";
           rcbDepartments.DataValueField = "DepartmentId";
           rcbDepartments.DataSource = dt;
           rcbDepartments.DataBind();
           rcbDepartments.Items.Insert(0, new RadComboBoxItem("-Select a DEP-"));
       }

Thanks for every help and fast answer ! ^^


 
Nikola
Top achievements
Rank 2
 answered on 08 Nov 2012
2 answers
134 views
I've got textboxes within a RadGrid FormTemplate.  I am getting the handles for the textboxes with the methods illustrated here: http://www.telerik.com/community/code-library/aspnet-ajax/grid/accessing-server-controls-in-a-grid-template-on-the-client.aspx

I have the handles to the textboxs.  That is not in doubt.

The problem is, I cannot find any usable way to enable or disable them through Javascript.

Either nothing happens or the page crashes.

(And there seem to be a dozen different methods out there.  enable()/disable().  attr/removeattr, disabled =true/false,  etc.)
Boris
Top achievements
Rank 1
 answered on 08 Nov 2012
2 answers
137 views
I'm sorry if this is partially a duplicate of a previous entry but I need a fast answer.

I need to be able to be able to enable and disable textboxes and other controls within a RadGrid's popup using a Javascript call from a check box on that same popup.

Every entry I've found seems to contradict the previous and nothing works.
Boris
Top achievements
Rank 1
 answered on 08 Nov 2012
1 answer
80 views

In one of my applications with IE 7 browser, the toolbar tools section that contains a dropdown will wrap to the 2nd line.  See attached image. 

I am using 2012.3.1030.35.  This application has a Master page.  The content page has a Radgrid.  In the editform is the Radeditor.  The radeditor uses a tools.xml file to load specific tools.

If the tools section has a dropdown as shown below, the <tool /> after the last dropdown will display on the next line.  So in the below example, the separator and the formatstripper objects will appear in a line below the 3 dropdown objects.

 

<

 

tools name="Fonts" dockable="true" >

 

<

 

tool name="FormatBlock" />

 

<

 

tool name="FontName" />

 

<

 

tool name="RealFontSize" />

 

<

 

tool separator="true" />

 

<

 

tool name="FormatStripper" />

 

</

 

tools>

Any suggestions as to how to fix this? 

 

Dobromir
Telerik team
 answered on 08 Nov 2012
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?