1
    sb.Append("<script language='javascript'>")
    sb.Append("window.open('updateRT.aspx?batchno=" + batchno + "&prodcode=" + prodcode + "&maxrunningtime=" + temprunningtime + ",")
    sb.Append("top=0, left=0, width=500, height=500, menubar=yes,toolbar=yes,status=1,resizable=yes');")
    sb.Append("</script>")
    ClientScript.RegisterStartupScript(Me.GetType(), "abc", sb.ToString())

hi everyone ...above is my vb.net code that i am trying to pass the value to other page and at the same time resize the window that will appear ...

i am not sure why and which error that i encounter and the size od windows still remain the same which is full screen rather than with width = 500 and height=500

can anyone help me out here?

thank you so much and have a nice day ...

:D

1 Answer 1

2

Whoops, had misread your code.

You're supposed to pass in the window specification as the third parameter to window.open - check out http://www.w3schools.com/jsref/met_win_open.asp. Right now, you're passing everything in one parameter, since the comma which is intended to close the first parameter is actually part of a string. Try

sb.Append("window.open('updateRT.aspx?batchno=" + batchno + "&prodcode=" + prodcode + "&maxrunningtime=" + temprunningtime + "', '_blank',")
sb.Append("'top=0, left=0, width=500, height=500, menubar=yes,toolbar=yes,status=1,resizable=yes');")
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.