Advertisement
Guest User

Untitled

a guest
Dec 9th, 2016
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
VB.NET 1.46 KB | None | 0 0
  1. // funcion
  2.  
  3. function PopupCenter(url, title, w, h) {
  4.     // Fixes dual-screen position                         Most browsers      Firefox
  5.     var dualScreenLeft = window.screenLeft != undefined ? window.screenLeft : screen.left;
  6.     var dualScreenTop = window.screenTop != undefined ? window.screenTop : screen.top;
  7.  
  8.     var width = window.innerWidth ? window.innerWidth : document.documentElement.clientWidth ? document.documentElement.clientWidth : screen.width;
  9.     var height = window.innerHeight ? window.innerHeight : document.documentElement.clientHeight ? document.documentElement.clientHeight : screen.height;
  10.  
  11.     var left = ((width / 2) - (w / 2)) + dualScreenLeft;
  12.     var top = ((height / 2) - (h / 2)) + dualScreenTop;
  13.     var newWindow = window.open(url, title, 'scrollbars=yes, width=' + w + ', height=' + h + ', top=' + top + ', left=' + left);
  14.  
  15.     // Puts focus on the newWindow
  16.     if (window.focus) {
  17.         newWindow.focus();
  18.     }
  19.  
  20.  
  21. }
  22.  
  23.  
  24.  
  25.  
  26.  
  27.  
  28. 'llamado :
  29.  
  30. Case 12300 'Informe de Puertas / Permisos
  31.                         objLink.ImageUrl = "../images/images_Adm/Informe_Puertas.gif"
  32.                         objLink.Attributes.Add("onClick", "WinOpen( 1, 'Mantencion/Informe_Pfl_Pue.aspx', 'window2', 900,900,50,50)")
  33.                         objCell.Controls.Add(objLink)
  34.                         objCell.HorizontalAlign = HorizontalAlign.Center
  35.                         objrow.Cells.Add(objCell)
  36.                         objCell = New TableCell
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement