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

Sorry guys if this is a question, but I am a newbie in programming language and this is the first time I use RadWindow.

I have a and it displays a dialog. As you know, after closing this dialog, its ​Close handler function will be hit. In there, I return a boolean value. 
And my problem is that I want to get the return value directly from the Close handler without using any global flags.

 

Please reference the snippet code below to get more detail.

Function used for showing the dialog:

function showDialog() {
        var url = "ChildPage.aspx";
        var wnd = window.radopen(url, 'Child Dialog');
        wnd.set_modal(true);
        wnd.setSize(400, 120);
        wnd.set_minHeight(300);
        wnd.set_minWidth(100);
        wnd.set_destroyOnClose(true);
        wnd.set_keepInScreenBounds(true);
        wnd.set_overlay(false);
        wnd.set_visibleStatusbar(false);
        wnd.set_visibleTitlebar(true);
        wnd.add_close(closeChildDialogHandler); //closeChildDialogHandler is Close handler
        wnd.set_behaviors(Telerik.Web.UI.WindowBehaviors.Move + Telerik.Web.UI.WindowBehaviors.Close + Telerik.Web.UI.WindowBehaviors.Resize);
        wnd.show();
        wnd.center();
    }

And Close handle function. As you see, I want to return true|false value in this handler.  

function closeChildDialogHandler(sender, args) {
        var flag = false;
        var objConfirmSQ = args.get_argument();
        if (objConfirmSQ != null && typeof objConfirmSQ['returnValue'] != "undefined") {
            console.log("objConfirmSQ['returnValue'] = " + objConfirmSQ['returnValue']);
            return true;
        }
        else {
            return false;
        }
    }

 OK, and is there any way I can receive the true|false value from the handler like this:

function myFunction(){
  var myVar = closeChildDialogHandler(unknown_param, unknown_param) //Not sure about this
}

 

 

 

function showDialog() {
        var url = "ChildPage.aspx";
        var wnd = window.radopen(url, 'Child Dialog');
        wnd.set_modal(true);
        wnd.setSize(400, 120);
        wnd.set_minHeight(300);
        wnd.set_minWidth(100);
        wnd.set_destroyOnClose(true);
        wnd.set_keepInScreenBounds(true);
        wnd.set_overlay(false);
        wnd.set_visibleStatusbar(false);
        wnd.set_visibleTitlebar(true);
        wnd.add_close(closeChildDialogHandler);
        wnd.set_behaviors(Telerik.Web.UI.WindowBehaviors.Move + Telerik.Web.UI.WindowBehaviors.Close + Telerik.Web.UI.WindowBehaviors.Resize);
        wnd.show();
        wnd.center();
    }

Marin Bratanov
Telerik team
 answered on 06 Nov 2015
3 answers
283 views
Hi,

Is there a way to assign a ValidationGroup to the Update/Insert commands (<rad:GridEditCommanColumn>) in RadGrid?   I have a grid with custom EditItemTemplate and I only want the validators in the edit template to active if the user press the Update/Insert command.  The form has other buttons  outside the grid but I don't want them to active the validators in the Grid.

Thank you,

Vincent
Mohd
Top achievements
Rank 1
 answered on 06 Nov 2015
4 answers
216 views
I made added a new page to my project and added a Rad Scheduler, and bound it to it's datasource so there is no problem there.  When I compiled the project and went to view the .aspx page, it throws the following exception:

Type : System.Web.HttpException, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
Message : Path '/ScriptResource.axd' was not found.
Source : System.Web
Help link :
ErrorCode : -2147467259
Data : System.Collections.ListDictionaryInternal
TargetSite : Void ProcessRequest(System.Web.HttpContext)
Stack Trace :    at System.Web.HttpNotFoundHandler.ProcessRequest(HttpContext context)
   at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
   at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)



What does this mean:  Path '/ScriptResource.axd' was not found.   ??

Thank you for your help!
Bozhidar
Telerik team
 answered on 06 Nov 2015
1 answer
146 views

I have a radgrid set up to allow filtering on date columns which appears to be working fine.

However I can't work out how to deal with invalid input. For example  entering text instead of a date crashes the page.

Can anyone point me in the right direction of how I can either trap the error (eg where to put a try/catch block) and/or how I can apply an input mask?

Maria Ilieva
Telerik team
 answered on 06 Nov 2015
9 answers
307 views
Hi, I am looking for a solution to the following problem:

The ability to connect to a database using ASP.Net and C# and retrieve the hierarchical attribute of an entity in order to plot and draw its position within an org chart on a web page.

Special Requirements

  • Must allow for multiple parents
  • Must have the ability to skip rows directly beneath in order to reach entities in a subsequent row.

I have attached a file with an example chart that would need to be created dynamically by extracting the entities from a database according to their hierarchical code, plotting their positions on a web page, and drawing the relationships between them.
NB: Entities are labelled according to the row and column that they below two i.e. the first row with 5 entities would have the labels R1C1 to R1C5; the next row with 2 entities would have the codes R2C1 and R2C2

Kindest Regards,

Brendan
Peter Filipov
Telerik team
 answered on 06 Nov 2015
3 answers
141 views

I have a RadGrid that contains a NestedView Template.   With the export option, i DO NOT want the NestedView to export (even if the nested view is visible).

 

While the grid item isn't expanded, i don't see the NestedView data.  However, when one is expanded, it will export.  How do I keep that from happening?

Kostadin
Telerik team
 answered on 06 Nov 2015
6 answers
151 views
I am trying to match menu colors/styles to an existing web site, so none of your great supplied skins match the color schemes of the existing site.  In trying to control the menus without a skin, I am encountering a border with white space all around each menu and item (see attached screen capture).

What properties or css properties do I need to utilize (in what manner) in order to eliminate this spacing issue?

The code for the menu as pictured is:

        <telerik:RadMenu ID="RadMenu2" runat="server">  
            <Items>  
                <telerik:RadMenuItem runat="server" BackColor="#212121" Font-Bold="True"   
                    Font-Names="Arial" Font-Size="Small" ForeColor="White"   
                    NavigateUrl="Default.aspx" Text="Home">  
                </telerik:RadMenuItem>  
                <telerik:RadMenuItem runat="server" BackColor="#212121" Font-Bold="True"   
                    Font-Names="Arial" Font-Size="Small" ForeColor="White" Text="Overview"   
                    BorderColor="#212121">  
                    <Items>  
                        <telerik:RadMenuItem runat="server" BackColor="#212121" Font-Bold="False"    
                            NavigateUrl="HowWeWork.aspx" Text="How We Work" ForeColor="#FF8000">  
                        </telerik:RadMenuItem>  
                        <telerik:RadMenuItem runat="server" BackColor="#212121" Font-Bold="False"   
                            Font-Names="Arial" Font-Size="Small" ForeColor="#FF8000"   
                            NavigateUrl="ProdsAndSvcs.aspx" Text="Our Products And Services">  
                        </telerik:RadMenuItem>  
                        <telerik:RadMenuItem runat="server" BackColor="#212121" Font-Bold="False"   
                            Font-Names="Arial" Font-Size="Small" ForeColor="#FF8000"   
                            NavigateUrl="TransTypes.aspx" Text="Transaction Types">  
                        </telerik:RadMenuItem>  
                        <telerik:RadMenuItem runat="server" BackColor="#212121" Font-Bold="False"   
                            Font-Names="Arial" Font-Size="Small" ForeColor="#FF8000"   
                            NavigateUrl="PropertyTypes.aspx" Text="Property Types">  
                        </telerik:RadMenuItem>  
                    </Items>  
                </telerik:RadMenuItem>  
                <telerik:RadMenuItem runat="server" BackColor="#212121" Font-Bold="True"   
                    Font-Names="Arial" Font-Size="Small" ForeColor="White" Text="My Account" BorderStyle="None"  >  
                    <Items>  
                        <telerik:RadMenuItem runat="server" BackColor="#212121" Font-Bold="false"   
                            Font-Names="Arial" Font-Size="Small" ForeColor="#FF8000" Text="My Dashboard" BorderStyle="None">  
                        </telerik:RadMenuItem>  
                        <telerik:RadMenuItem runat="server" BackColor="#212121" Font-Bold="false"   
                            Font-Names="Arial" Font-Size="Small" ForeColor="#FF8000" Text="My Reward Points" BorderStyle="None" >  
                        </telerik:RadMenuItem>  
                    </Items>  
                </telerik:RadMenuItem>  
            </Items>  
        </telerik:RadMenu> 
Please bear in mind that the colors, fonts, etc. are not those of the targeted web site, but just simple settings we are using to learn how to control the look and feel of the menus without skins.

Thanks in advance!
Lynn
Ivan Danchev
Telerik team
 answered on 06 Nov 2015
1 answer
137 views
Can anyone point to a code example showing how to write a custom FileBrowserContentProvider that will enable a RadEditor user to browse to a file on a shared network drive and insert a link to it into the content? I'd like it to work the same as Microsoft Outlook's Insert Hyperlink feature. By default, the DocumentManager points only to the web server where the application folder is. Thanks
Ianko
Telerik team
 answered on 06 Nov 2015
0 answers
62 views

I found following example which integrates Column Series  with PivotGrid

http://demos.telerik.com/aspnet-ajax/pivotgrid/examples/applicationscenarios/chartintegration/defaultcs.aspx

 I have implemented this successfully.

 

I am unable to integrate Pie Chart with PivotGrid. Is there any demo available for same?

Kamalpreet
Top achievements
Rank 1
 asked on 06 Nov 2015
1 answer
97 views

Hi, there! 

I have a pivot grid with a column field which is Types of budgets, there are 3 in the SQL query: initial budget, real budget, executed value. I want two calculated fields, namely the percentage difference between the initial budget vs real budget and executed value. The result would be something like:

 INIT    REAL  Dif%  EXEC  Dif%

$1000  $900  -10%  $1100 +10%

 Is there a way to do it with custom calculated fields?

Thanks a lot!

Viktor Tachev
Telerik team
 answered on 05 Nov 2015
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?