Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 135
  • Last Modified:

Opening a new window and controlling the size

I can open a document in a new window using the following HTML code:
<a href="#" onClick=window.open('karen.htm','','scrollbars=yes','height=200','width=200')>Sized w/scrollbars</a>

I can open a document in a new window using the following VB Script:
<%
blah, blah, blah
response.write "<a href=""" & "karen.htm" & """ target=""_blank"">in VB Script - New window - No sizing</a>"
blah, blah, blah
%>

WHAT I WANT TO DO is combine the two within VB script. This is just ONE example of what DOES NOT work:
response.write "<a href=""" & "#" onClick=window.open('karen.htm','','scrollbars=yes','height=200','width=200' & """)>Sized w/scrollbars</a>"


0
goldstar
Asked:
goldstar
1 Solution
 
BhargavaCommented:
try this

response.write "<a href='#' onClick=window.open('karen.htm','','scrollbars=yes','height=200','width=200')>Sized w/scrollbars</a>"

hope this helps

0
 
goldstarAuthor Commented:
Thanks!

What you provided worked!

I will increase your points if you can correct the following.  I am actually linking to an .asp page, and passing a varible - objRec ("fldTip") created earlier in the VBScript.

Again, the following DOES NOT work....................

response.write "<a href='#' onClick=window.open('includes\karenbigtip.asp?tip=' & objRec ("fldTip") & ','','scrollbars=yes','height=150','width=150'>"                              

Or, I will give you the 100 points now, close this, and open a new question.

Your preference.

0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now