Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
143 views
Hello,

I was looking at the keyboard shortcut demo (http://demos.telerik.com/aspnet-ajax/window/examples/keyboardsupport/defaultcs.aspx) and only saw that a few commandNames were listed. I am looking for a complete list and couldn't find it anywhere. Does anyone know if there is documentation for this?

Regards,
Tom
Georgi Tunev
Telerik team
 answered on 26 Oct 2010
1 answer
113 views
Hi,
i've got a question, because im new to asp.net. Im trying to port mine app from WPF to ASP.NET, but got few issues. Im doing full ajax app, and i dont know how to achiv such scenario:

1. Default.aspx with RadWindowManager and a DIV that will contain website later.
2. Login.aspx just a form with login, pass and a button (it appears in RadWindow)
3. xxxx.aspx after successful login

so basicly in Default.cs i got 

protected void Page_Load(object sender, EventArgs e)
        {
            SessionUser sessionUser = (SessionUser)Session["User"];
            if (sessionUser == null)
            {
                ShowLoginWindow();
            }
        }

ShowLoginWindow() just open a RadWindow and till that everything works fine. Than in Login.aspx i use RadAjaxManager with button control to get click. Mine question starts here
1. How can i close RadWindow form code-behind.
2. How can i know at code-behind Default.cs that Login Window is closed, so i can load a site into DIV?

Also how do you use modal window? Im not talking about lock screen, because there is a bool to make modal or not, but how can i do something at code-behind, than forward data to modal window, get data from window and continue to execute code.
Something like:

Window window = new Window();
window.MineString = "Something";
window.ShowDialog();
MessageBox.Show(window.OtherString);

Ofc i know it cant be achiv like i did, but need something for such scenario.

Thanks, for help.
Georgi Tunev
Telerik team
 answered on 26 Oct 2010
6 answers
609 views
hi,

I have a asp:Button. OnCLientClick of the button, I call a javascript method-> Test()

function Test()
{
document.getElementById('Id of the combo box').disabled=true;
}

I am unable to do so. Please advice on how to proceed.

Thanks,
Saravanan
Kalina
Telerik team
 answered on 26 Oct 2010
1 answer
500 views
I am trying to figure out what to do when an image I upload to my database is smaller than my max height/width that I have setup for resize on upload. 

For example, I have my resize utlity resizing all images to be no larger than 1000 X 1200 pixels and this works great with RadBinary because it "fits" them into my various objects (thumbnail, full size, screen size, etc) at my specificied sizes (for example full size = 500 pixels width).  But my problem is sometimes I am supplied with photos that have already been resized to dimensions which are smaller than the ones I have setup for my project (for example I might be supplied with a 300 x 400 image).  This causes the image to be streched when I am using radbinary on my page because I have my sizes preset to 500 width.

I would like to know if there is a way to detect the image size from the database, then see if it is smaller than my presets (500 px), if so, then it would need to show the image in its largest format size and if not, show it in my preset size format. 

I found this article, but it is referring to using it in the grid, but I am not, I just have the files on my page.
http://www.telerik.com/community/forums/aspnet-ajax/binary-image/change-image-size-different-for-landscape-portrait.aspx

Thanks
Veli
Telerik team
 answered on 26 Oct 2010
2 answers
663 views

I started a new ASP .NET website in VS 2010 and added a RadScriptManager to default.aspx. I set the validate option on the httphandler add to true and get this error.

Configuration Error Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: Could not load type 'Telerik.Web.UI.WebResource'.

Source Error:

Line 71: 			<add verb="*" path="*_AppService.axd" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
Line 72: 			<add verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" validate="false"/>
Line 73: <add path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource" verb="*" validate="true"/>Line 74: 		</httpHandlers>
Line 75: 		<httpModules>

If I change validate to false, I get AJAX errors (sys is undefined etc.).

If I change my target .NET framework to 4.0 the problem goes away. However, I am not prepared to migrate to .NET 4.0 right now. Can anyone help me figure out what is amiss?

I have reinstalled the 3.5 framework as well as the RadControls for AJAX (Q1 2010). I have also tried (Q2 2010) with the same results.

Here is the web.config file if it helps:

<!--
    Note: As an alternative to hand editing this file you can use the
    web admin tool to configure settings for your application. Use
    the Website->Asp.Net Configuration option in Visual Studio.
    A full list of settings and comments can be found in
    machine.config.comments usually located in
    \Windows\Microsoft.Net\Framework\vx.x\Config
-->
<configuration>
    <configSections>
        <sectionGroup name="system.web.extensions" type="System.Web.Configuration.SystemWebExtensionsSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
            <sectionGroup name="scripting" type="System.Web.Configuration.ScriptingSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
                <section name="scriptResourceHandler" type="System.Web.Configuration.ScriptingScriptResourceHandlerSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
                <sectionGroup name="webServices" type="System.Web.Configuration.ScriptingWebServicesSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
                    <section name="jsonSerialization" type="System.Web.Configuration.ScriptingJsonSerializationSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="Everywhere"/>
                    <section name="profileService" type="System.Web.Configuration.ScriptingProfileServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
                    <section name="authenticationService" type="System.Web.Configuration.ScriptingAuthenticationServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
                    <section name="roleService" type="System.Web.Configuration.ScriptingRoleServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
                </sectionGroup>
            </sectionGroup>
        </sectionGroup>
    </configSections>
    <appSettings/>
    <connectionStrings/>
    <system.web>
        <!--
            Set compilation debug="true" to insert debugging
            symbols into the compiled page. Because this
            affects performance, set this value to true only
            during development.
        -->
        <compilation debug="true">
            <assemblies>
                <add assembly="System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
                <add assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
                <add assembly="System.Data.DataSetExtensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
                <add assembly="System.Xml.Linq, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
                <add assembly="System.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
                <add assembly="System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
                <add assembly="System.Speech, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            </assemblies>
        </compilation>
        <!--
            The <authentication> section enables configuration
            of the security authentication mode used by
            ASP.NET to identify an incoming user.
        -->
        <authentication mode="Windows"/>
        <!--
            The <customErrors> section enables configuration
            of what to do if/when an unhandled error occurs
            during the execution of a request. Specifically,
            it enables developers to configure html error pages
            to be displayed in place of a error stack trace.
 
        <customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm">
            <error statusCode="403" redirect="NoAccess.htm" />
            <error statusCode="404" redirect="FileNotFound.htm" />
        </customErrors>
        -->
        <pages>
            <controls>
                <add tagPrefix="asp" namespace="System.Web.UI" assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
                <add tagPrefix="asp" namespace="System.Web.UI.WebControls" assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            </controls>
        </pages>
        <httpHandlers>
            <remove verb="*" path="*.asmx"/>
            <add verb="*" path="*.asmx" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add verb="*" path="*_AppService.axd" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" validate="false"/>
            <add verb="*" path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource"  validate="true"/>
        </httpHandlers>
        <httpModules>
            <add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
        </httpModules>
    </system.web>
    <system.codedom>
        <compilers>
            <compiler language="c#;cs;csharp" extension=".cs" warningLevel="4" type="Microsoft.CSharp.CSharpCodeProvider, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
                <providerOption name="CompilerVersion" value="v3.5"/>
                <providerOption name="WarnAsError" value="false"/>
            </compiler>
            <compiler language="vb;vbs;visualbasic;vbscript" extension=".vb" warningLevel="4" type="Microsoft.VisualBasic.VBCodeProvider, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
                <providerOption name="CompilerVersion" value="v3.5"/>
                <providerOption name="OptionInfer" value="true"/>
                <providerOption name="WarnAsError" value="false"/>
            </compiler>
        </compilers>
    </system.codedom>
    <!--
        The system.webServer section is required for running ASP.NET AJAX under Internet
        Information Services 7.0.  It is not necessary for previous version of IIS.
    -->
    <system.webServer>
        <validation validateIntegratedModeConfiguration="false"/>
        <modules>
            <remove name="ScriptModule"/>
            <add name="ScriptModule" preCondition="managedHandler" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
        </modules>
        <handlers>
            <remove name="WebServiceHandlerFactory-Integrated"/>
            <remove name="ScriptHandlerFactory"/>
            <remove name="ScriptHandlerFactoryAppServices"/>
            <remove name="ScriptResource"/>
            <add name="ScriptHandlerFactory" verb="*" path="*.asmx" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add name="ScriptHandlerFactoryAppServices" verb="*" path="*_AppService.axd" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add name="ScriptResource" preCondition="integratedMode" verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add name="Telerik_Web_UI_WebResource_axd" verb="*" preCondition="integratedMode" path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource"/>
        </handlers>
    </system.webServer>
    <runtime>
        <assemblyBinding appliesTo="v2.0.50727" xmlns="urn:schemas-microsoft-com:asm.v1">
            <dependentAssembly>
                <assemblyIdentity name="System.Web.Extensions" publicKeyToken="31bf3856ad364e35"/>
                <bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="3.5.0.0"/>
            </dependentAssembly>
            <dependentAssembly>
                <assemblyIdentity name="System.Web.Extensions.Design" publicKeyToken="31bf3856ad364e35"/>
                <bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="3.5.0.0"/>
            </dependentAssembly>
        </assemblyBinding>
    </runtime>
</configuration>

T. Tsonev
Telerik team
 answered on 26 Oct 2010
1 answer
71 views
Good day!
Changing size of window automatically do not work in ie 8 at all! =((( You can jaust open this link http://demos.telerik.com/aspnet-ajax/window/examples/autosize/defaultcs.aspx in IE8 to see it =((
it works well in ie7 & ie6, but in ie8 =(((
What can I do?
Georgi Tunev
Telerik team
 answered on 26 Oct 2010
3 answers
153 views
I have created a RadGrid with SqlDataSource. Enabled Automatic delete, update and insert. Then I created an external filter with ComboBox, for filtering with multiple columns. I created a function for filtering in code behind with new Sql connection and Rebind RAdGrid with new filtered items. When I run Its perfect every automatic properties work. But after filtering with combobox automatic properties does n't work, not able to edit delete paging sorting etc. The reason is I am binnding the grid with new data table for filtering. How can I enable the automatic properties again, after filtering? Anybody can help.
 I tryied to write, RadGrid.AutomaticDelete=true, AutomaticUpdate=true, etc in codebehind after binding with filtered data. But no hope.
Veli
Telerik team
 answered on 26 Oct 2010
1 answer
76 views
I want to disable default telerix CSS and use my own CSS, how should i do it ?
Please advice
Fiko
Telerik team
 answered on 26 Oct 2010
1 answer
83 views
Right Now I am able to load the tree and have the first node (root Node) select automatically, but I want to have it detect if a child of that root node exists and if it does I want to auto select and expand that child node.

Not sure how to get this done?
I expected it to be something like:
If tree.Nodes(0).ChildNode.Count > 0 then
tree.Nodes(0).ChildNode(0).Selected = True
End If
Shinu
Top achievements
Rank 2
 answered on 26 Oct 2010
1 answer
112 views
Here how I call my window. Both code behind and client methods are not working, the window just don't open.

function OpenWindow(url) {
    var oWindow = window.radopen(url, 'window');
 
    oWindow.set_behaviors(Telerik.Web.UI.WindowBehaviors.Close);
    oWindow.moveTo(150, 100);
    oWindow.setSize(1000, 360);
 
    var browserWin = oWindow.BrowserWindow;
    var fn = new browserWin.Function("parent.window.location.reload(false);");
 
    oWindow.add_close(fn);
}


<
a onclick="OpenWindow('<%# WindowURL(Eval("AddresID").ToString()) %>')" class="edit">Edit</a>

private void NewWindow()
{
    RadWindow newwindow = new RadWindow();
 
    newwindow.ID = "RadWindow1";
    newwindow.AutoSize = true;
    newwindow.EnableEmbeddedBaseStylesheet = false;
    newwindow.EnableEmbeddedSkins = false;
    newwindow.Behaviors = WindowBehaviors.Close;
    newwindow.NavigateUrl = GetWidgetPagerURL("Profil/Address.ascx&isInvoiceAddress=1");
    newwindow.VisibleOnPageLoad = true;
    newwindow.VisibleStatusbar = false;
    newwindow.OnClientClose = "OnClientClose";
    rwm.Windows.Add(newwindow);
}


Georgi Tunev
Telerik team
 answered on 26 Oct 2010
Narrow your results
Selected tags
Tags
+? more
Top users last month
Marco
Top achievements
Rank 4
Iron
Iron
Iron
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
Want to show your ninja superpower to fellow developers?
Top users last month
Marco
Top achievements
Rank 4
Iron
Iron
Iron
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
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?