27348

kendo window with minimize and maximize

Question:

I have two kendo windows one below the other in the page with minimize and maximize options. When I close or minimize the first window the window below should come up. Could you please help me achieve this?

<div id="dialog"></div> <div id="dialog1"></div> <script> $("#dialog").kendoWindow({ animation: { close: false } }); $("#dialog1").kendoWindow({ animation: { close: false } }); </script>

Answer1:

Try:

<script> $("#dialog").kendoWindow({ animation: { close: false }, close: function(e) { var d1 = $("#dialog1").data("kendoWindow"); d1.open(); }, minimize: function(e) { var d1 = $("#dialog1").data("kendoWindow"); d1.open(); } }); $("#dialog1").kendoWindow({ animation: { close: false } }); </script>

<a href="http://docs.telerik.com/kendo-ui/api/javascript/ui/window#methods-open" rel="nofollow">http://docs.telerik.com/kendo-ui/api/javascript/ui/window#methods-open</a>

Answer2:

Use the <a href="http://docs.telerik.com/kendo-ui/api/javascript/ui/window#methods-toFront" rel="nofollow">toFront()</a> method

$("#dialog1").kendoWindow({ animation: { close: false }, actions: [ "Pin", "Minimize", "Maximize", "Close" ], minimize: function(e) { var d1 = $("#dialog").data("kendoWindow"); d1.toFront(); }, close: function(e) { var d1 = $("#dialog").data("kendoWindow"); d1.toFront(); } });

<strong><a href="http://codepen.io/ezanker/pen/zBRkJj" rel="nofollow">DEMO</a></strong>

Recommend

  • I am having trouble with jquery modal with multiple id's
  • Kendo UI custom grid popup editor window only opens once
  • C/C++ returning struct by value under the hood
  • I have a modal that opens a second modal and cannot close the first modal if open then close the sec
  • Is it one-to-one or Component ? Nhibernate Mapping
  • Where to put clearQueue in jQuery code
  • dismiss Progress Dialog in another Activity … Android
  • How to remove all of a jQuery UI dialog when it is closed
  • div fade-in when window is scrolled a certain distance from the top
  • Visual Studio 2010 debugger build correctly - compiler pdb and linker pdb not in synch?
  • Alert pop up with LWUIT
  • FileReader+canvas image loading problem
  • Insert into database using onclick function
  • Deselecting radio buttons while keeping the View Model in synch
  • Javascript simulate pressing enter in input box
  • Why HTML5 Canvas with a larger size stretch a drawn line?
  • Importing jscolor library in angular 2
  • Release, debug version and Authorization Google?
  • Websockets service method fails during R startup
  • Alternatives to the OPTIONAL fallback SPARQL pattern?
  • How to get next/previous record number?
  • Apache 2.4 - remove | delete | uninstall
  • A cron job substitute?
  • How to delete a row from a dynamic generate table using jquery?
  • json Serialization in asp
  • Rails 2: use form_for to build a form covering multiple objects of the same class
  • Proper way to use connect-multiparty with express.js?
  • Trying to get generic when generic is not available
  • embed rChart in Markdown
  • How to stop GridView from loading again when I press back button?
  • How to get Windows thread pool to call class member function?
  • IndexOutOfRangeException on multidimensional array despite using GetLength check
  • sending mail using smtp is too slow
  • costura.fody for a dll that references another dll
  • Binding checkboxes to object values in AngularJs
  • Observable and ngFor in Angular 2
  • How to Embed XSL into XML
  • UserPrincipal.Current returns apppool on IIS
  • Conditional In-Line CSS for IE and Others?
  • java string with new operator and a literal