Solved

custom html wizard

Posted on 2008-10-01
5
169 Views
Last Modified: 2012-05-05
Hi all

I wanted to make a custom HTML page that will take input from and user and based on that input it will go to a certain page. For example, I would like to have a HTML page prompt the user for there name, they would then click a next button which would open a new window and display that information, at the same time when they click next it will close the first window.

I am stuck at the part where the first windows closes and the second one opens

Thanks
0
Comment
Question by:OTNAdmin
  • 3
  • 2
5 Comments
 
LVL 44

Expert Comment

by:scrathcyboy
ID: 22618080
In the second window, but this as the body tag --

<BODY onLoad="javascript: window.parent.close();">

that will close the first window when the second opens.
0
 

Author Comment

by:OTNAdmin
ID: 22618513
Alright that worked, is there anyway i can use vbscript instead of java?
0
 
LVL 44

Expert Comment

by:scrathcyboy
ID: 22619732
You really don't want to do that if you want cross-browser compatibility.  VB script is something that is almost always limited to MS internet explorer.  Almost half the world is on other browsers now because of IE's crummy security.  Why limit your audience to only corporate types stuck on IE?  All the leading people now are runnning something like Firefox as their main browser, and essentially everyone has to run javascript these days just to see almost any modern page on the internet.  Stick with that.
0
 

Author Comment

by:OTNAdmin
ID: 22624643
alright that is fare, will, I am working on a HTA file, I want to be able to click next an have the first window close Can this done done in VB? THe only reason I want VB is because it is a Win PE script and Java in not the best in PE
0
 
LVL 44

Accepted Solution

by:
scrathcyboy earned 500 total points
ID: 22629238
The problem is that VB will give the user a warning before closing the parent, and that is a real nuisance, because people will think you are trying to do something wrong on their system.  You can try these two --

Response.Write("window.open('','_parent','');")
Response.write("window.close();")

Don't be surprised if it doesn't work right.  Javascript is the best way to do this.  Also, explore the issue in these links, there are a lot of irrelevant (erroneous?) opinions in other blogs, but you might find something that will work.  But I think all VB will generate a warning message, as I understand it.  Good luck --
http://www.google.com/search?num=30&q=close-parent+window+in+VB
0

Featured Post

ScreenConnect 6.0 Free Trial

Explore all the enhancements in one game-changing release, ScreenConnect 6.0, based on partner feedback. New features include a redesigned UI, app configurations and chat acknowledgement to improve customer engagement!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
In this tutorial viewers will learn how to style elements, such a divs, with a "drop shadow" effect using the CSS box-shadow property Start with a normal styled element, such as a div.: In the element's style, type the box shadow property: "box-shad…
In this tutorial viewers will learn how to embed videos in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <video> tag to insert a video. Define the src as the URL of your video; this is similar to …

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question