Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
135 views
Hi

Currently the compact button popup will be centered on the screen.
Is there any possibility to show the popup bellow the button?

Cheers,
Jani
Marin Bratanov
Telerik team
 answered on 16 Dec 2011
1 answer
116 views

Hello!

I have inherited an asp.net project that relies heavily on the Telerik library.  In the current application, there are two menu items that when clicked generate a redirect to the same asp page, but with different arguments:
~\myasppage.aspx?Mode="A"&Type="B";
~\myasppage.aspx?Mode="C"&Type="D";

So I have been asked to replace them with a dialog box that allows the user to choose the Mode and type, then opening the page.  In looking at the Telerik controls that are available to me, it seems that the RadWindow is perfect.  My strategy is:
redirect to the generic page:
~\myasppage.aspx
Define a RadWindow on the page and sets its VisibleOnPageLoad to true.

The RadWindows contains a Cancel button and a Next button.  Selection of the cancel button closes the dialog and leaves an empty page.  Selection of the Next button will redirect to the same page but contain the Mode and Type parameters using the
 window.location = myasppage.aspx?Mode="whatever"&Type="whatever";

My problem is that because VisibleOnPageLoad=true the radwindow always opens so  I can't load the real page! 

Am I going about this correctly? Is there another control to deal with this? 

I was thinking that I could set VisibleOnPageLoad to false, then check for my parameters in the OnPreInit method to decide if I should show the radwindow. 

I haven't been able to figure out how to call a javascript function (to show the radwindow) from the code behind, and even if I could, I'm not sure that the javascript would even be loaded yet!

Is there a better way of doing this?  Will this even work?

thanks

Marin Bratanov
Telerik team
 answered on 16 Dec 2011
1 answer
92 views
This must be my week for strange problems.  Actually, I'm upgrading half a million lines of code from ASP.NET 2.0 to 4.0, and taking my telerik from 2009 Q3 to 2011 Q3, so I've got to catch up on 2 - 5 years of advancements.

Anyway, I'm seeing some strageness in RadInput.  I'm trying to add a specific default button for the enter key. Simple enough, right?  Handle the keypress and act on keyCode 13.

I've found through testing though, that when you have MaxLength defined on the field, characters don't seem to be accepted.  The enter key still works fine, but nothing shows up in the field.

Here's what I did:
s = string.Empty;
s += "function " + this.ClientID + "_defaultEnter(sender, eventArgs) { \r\n";
s += "  var c = eventArgs.get_keyCode(); \r\n";
s += "  var btn = document.getElementById('" + btnSearch.ClientID + "'); \r\n";
s += "  if (c == 13){ \r\n";
s += "    btn.click(); \r\n";
s += "    eventArgs.set_cancel(true); \r\n";
s += "  } \r\n";
s += "}\r\n";
this.Page.ClientScript.RegisterClientScriptBlock(this.GetType(), this.ClientID + "_defaultEnter", s, true);
fldCaseNumber.ClientEvents.OnKeyPress = this.ClientID + "_defaultEnter";

And yes, I know (now) that strings are immutable and I should be using a StringBuilder instead of += ... let's stick to the topic, eh? :)

Anyway, I can live without the MaxLength, I just wanted to share the pain and maybe help someone who can't figure out why their keyboard suddenly stopped working on that textbox.

-Chris
Vasil
Telerik team
 answered on 16 Dec 2011
1 answer
132 views
Hi,

I downloaded the trial version of ASP.NET Ajax controls and I tried explore the RadAsyncUpload control.

I am bit confused about the look and feel of the RadAsyncUpload and RadUpload control.

When I used RadAsyncUpload control, I don't know to display the Add, delete buttons to this control
(Not finding the ControlObjectsVisibility Preoperty) .
But in the online help document I can see the Add and delete buttons for the RadAsyncUpload   control in this link.

My requirement is to get the same look and feel of RadUpload control for RadAsyncUpload control and as well as validate the file size at client side.

Please help me to solve the above issue?

Thanks
Prabhakar
Bozhidar
Telerik team
 answered on 16 Dec 2011
2 answers
251 views
Hello, I have added asyncupload control in page and set EnableEmbeddedScripts="false", for this I have to add related scripts in file. So I have added like below <asp:ScriptManager runat="server" ID="RadScriptManager1" AsyncPostBackTimeout="18000">
        <Scripts>
            <%--RadWindow--%>
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Common/Core.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Upload/RadProgressManager.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Common/jQuery.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Common/jQueryPlugins.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Upload/RadUpload.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/AsyncUpload/RadAsyncUploadScripts.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Common/PopUp/PopUpScripts.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Upload/RadProgressArea.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Common/Animation/AnimationScripts.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Window/RadWindowScripts.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Window/RadWindowManager.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Common/TouchScrollExtender.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Ajax/Ajax.js" />
            <%--RadSplitter--%>
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Splitter/RadSplitterScripts.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Splitter/RadSlidingZoneScripts.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Common/Navigation/NavigationScripts.js" />
            <%--RadPanelBar--%>
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/PanelBar/RadPanelBarScripts.js" />
            <%--RadComboBox--%>
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/ComboBox/RadComboBoxScripts.js" />
            <%--RadTreeView--%>
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/TreeView/RadTreeViewScripts.js" />
            <%--RadContextMenu--%>
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Menu/RadMenuScripts.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Menu/ContextMenu/RadContextMenuScripts.js" />
            <%--noderenderer--%>
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Grid/RadGridScripts.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Button/RadButton.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Common/Scrolling/ScrollingScripts.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/TabStrip/RadTabStripScripts.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/TabStrip/MultiPage/RadMultiPageScripts.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Input/TextBox/RadInputScript.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Input/DateInput/RadDateInputScript.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Calendar/RadCalendarCommonScript.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Calendar/RadCalendarScript.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Calendar/RadDatePicker.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Calendar/RadPickersPopupDirectionEnumeration.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Editor/RadEditor.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Common/LayoutBuilder/LayoutBuilderEngine.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Spell/SpellCheckService.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Editor/Modules.js" />
            <asp:ScriptReference Path="~/Enigma/Telerik/Scripts/Dialogs/RadDialogOpenerScripts.js" />
        </Scripts>
    </asp:ScriptManager> Upload control code ===================== <telerik:RadAsyncUpload ID="rubg" runat="server" 
     EnableEmbeddedScripts="false" EnableInlineProgress="false" ProgressHandlerUrl="">
</telerik:RadAsyncUpload> When I load the page then it is loaded successfully, but when I click on upload > then select Image -> then process image show in red and it will display error in error console as below POST http://localhost/enigma/Telerik.Web.UI.WebResource.axd?type=rau 404 (Not Found) Uncaught Error while uploading, HTTP Error code is: 404

Please Help me out this issue.

Thanks in advance,
Mohmedsadiq Modan
Bozhidar
Telerik team
 answered on 16 Dec 2011
3 answers
179 views
hi,
We have a requirement from our client to select multiple records in a grid, just by a mouse click on each record and without using the 'Ctrl' key.

Please help me how to implement the multi-selection of the records in the radgrid without using the 'Ctrl' key.



Thanks in advance.
Casey
Top achievements
Rank 1
 answered on 16 Dec 2011
3 answers
145 views
Hello,

I have a Rad Grid to the left of my page and a ajax panel to the right, I basically want the user to be able to select any row in my grid which in turn will pass an ID and refresh the ajax panel showing the selected row details.

I'm pretty sure you used to have an online example of this scenerio, if so could please link it (I've looked everywhere for it to no avail).

Thank you.

Craig Mellon
Top achievements
Rank 1
 answered on 16 Dec 2011
1 answer
309 views
Hi,

I am creating a hierarchical grid with template as shown in link below. However, all of my  tab pages in the  nested view template have chidgrids. . There is n-level of hierarchy. How can i create parent table relation in  hierarchical grid with template   to avoid infinite loop.



http://demos.telerik.com/aspnet-ajax/grid/examples/hierarchy/nestedviewtemplate/defaultcs.aspx

Thanks,
Prava
Antonio Stoilkov
Telerik team
 answered on 16 Dec 2011
1 answer
110 views
Hi all,

can someone tell me what it is the best way to browse all nodes of a RadTreeView?

I'm using the following code:

foreach (RadTreeNode oNode in oTreeView.Nodes)
{
    Label oLbl = (Label)oNode.FindControl("spnDesignation");
    oLbl.Visible = bShow;
}

but it is just catching the root node.

Thanks,
Bruno
Bruno
Top achievements
Rank 1
 answered on 16 Dec 2011
2 answers
116 views
I have one database with two tables, named Event1 and Event2. 

I now have:

<telerik:RadScheduler runat="server" ID="RadScheduler1" Width="748px" SelectedDate="2007-03-30"<br>            DayStartTime="08:00:00" DayEndTime="18:00:00" DataKeyField="ID" DataSubjectField="Subject"<br>            DataStartField="Start" DataEndField="End" DataRecurrenceField="RecurrenceRule"<br>            DataRecurrenceParentKeyField="RecurrenceParentID" <br>            DataSourceID="EntityDataSource1" ><br>            <ResourceTypes><br>                <telerik:ResourceType KeyField="ID" Name="Event1" TextField="Text1" ForeignKeyField="ID"<br>                    DataSourceID="EntityDataSource1" /><br>                <telerik:ResourceType KeyField="ID" Name="<span style="font-size: 14px; ">Event2</span>" TextField="Text2" ForeignKeyField="ID"<br>                    DataSourceID="EntityDataSource2" /><br>            </ResourceTypes><br>        </telerik:RadScheduler>


I have some questions:

1. What is the method GetResources(ISchedulerInfo schedulerInfo) for? What would I get if I override it?
2. In the code above, I know that the KeyField is the primary key of the table, the ForeignKeyField  is the foregin key, but what column of the table represents the TextField attribute?
3. How to define the tables as different resources?
4. How to make different color of the events from the second table but not with javascript, but as resources?
Dani
Top achievements
Rank 1
 answered on 16 Dec 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Hiba
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Max
Top achievements
Rank 1
Veteran
Iron
Alina
Top achievements
Rank 1
Rakhee
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?