MSFN Forum: ImageX HTA with Win PE 3.0/4.0 x64/x86 - MSFN Forum

Jump to content


  • 4 Pages +
  • « First
  • 2
  • 3
  • 4
  • You cannot start a new topic
  • You cannot reply to this topic

ImageX HTA with Win PE 3.0/4.0 x64/x86 Server 2008/R2 WDS Tutorial Rate Topic: -----

#61 User is offline   Tripredacus 

  • K-Mart-ian Legend
  • Group: Super Moderator
  • Posts: 8,723
  • Joined: 28-April 06
  • OS:Server 2012
  • Country: Country Flag

Posted 22 April 2013 - 03:00 PM

If you try using this on WinPE4 x64 and do a UEFI boot via CD/DVD or PXE (or whatever) you'll find that everything is thrown off regarding pictures and text size. This is because WinPE4 can detect the native resolution of the display and will use GOP mode to automatically set the resolution. I have just tested a method of using ZOOM in javascript in a test HTA that you can use in this case.

Add the following Javascript code to a script element. I placed mine after the Script end tag for the VBScript code.

<script TYPE="text/javascript">
function pageLoadFunctions()
{
document.body.style.zoom = screen.height / 768;
}
</SCRIPT>


Then I change the BODY tag:

<BODY ONLOAD="pageLoadFunctions()">


It isn't 100% perfect, the right side of the HTA's background image is cut off but overall it is better.

Edit: This works fine on a 4:3 display. It leaves a large white space on the right side if using a 16:9 display and 1024x768. This is caused by the wallpaper background image.

This post has been edited by Tripredacus: 31 May 2013 - 07:58 AM



#62 User is offline   MadFly1 

  • Group: Members
  • Posts: 7
  • Joined: 31-May 13
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 31 May 2013 - 04:14 AM

Hi, Thanks to everyone who contributed to this project... I only VERY recently started playing around with winPE, and came across this forum.
Currently like the v7.3 the most, and was wondering if there was a way that I can use both 32bit and 64bit PE HTA at the same time?

I assume the reason they are in separate folders, is because you have to run either one of them... is there perhaps a way that i can put both on a flash drive, which will be my winPE, and then either run 32bit PE or 64bit...
I also assume that the 32bit PE is to deploy and capture 32bit OS, and 64bit PE is to deploy and capture 64bit OS.

Would be nice to have one HTA which can deploy/capture either 32bit or 64bit, or do i completely misunderstand the whole idea behind this project?

#63 User is offline   Tripredacus 

  • K-Mart-ian Legend
  • Group: Super Moderator
  • Posts: 8,723
  • Joined: 28-April 06
  • OS:Server 2012
  • Country: Country Flag

Posted 31 May 2013 - 07:56 AM

64bit WinPE can do both, its the only one I actually use.

The only problems with 64bit WinPE is that the client needs a 64bit CPU to boot. Also requires nearly 1GB RAM (its less than that but I don't know how to test it) 99% of the time and 2GB on some boards with RAID enabled.

In other news, I've been working on trying to get the HTA to deploy via UEFI but it isn't working out yet. As it stands, this HTA can't deploy to UEFI and it can't deploy Windows 8. :(

#64 User is offline   MadFly1 

  • Group: Members
  • Posts: 7
  • Joined: 31-May 13
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 03 June 2013 - 02:15 AM

excellent.

I have configured for myself a virtual environment (hyper-V) where i can play with this hta thing.
Works great so far, but for some reason when i try to apply the captured image to a new virtual pc, it complains that the bootmgr is missing.

Is there a way that I can capture the boot partition as well, or should i create it manually? Or could I somehow implement a button or two in the diskpart options?

Once I get this to actually work, i'll start playing around with adding drivers to the wim and a few other things i would like to try. but for now the capture and apply is more crucial.

This post has been edited by MadFly1: 03 June 2013 - 03:58 AM


#65 User is offline   MadFly1 

  • Group: Members
  • Posts: 7
  • Joined: 31-May 13
  • OS:Windows 7 x64
  • Country: Country Flag

Posted 03 June 2013 - 10:52 AM

View PostTripredacus, on 22 March 2010 - 08:19 AM, said:

View Postkyascian, on 21 March 2010 - 02:10 PM, said:

nothing.... :realmad:

the progress bar not run...
i have the same grey rectangle...

i make all the steps , gimagex x64 , startnet.cmd , and all packages..mhta...etc...

nothing :(

i don't understand where is MY error...


The current code in this is still the same as v7.1 except for the code changes mentioned in this thread. So the progress bar code is still incorrect, and as such, does not work for anyone. So its not your error, no one sees the progress bar. It is good enough to see the square, on some video cards/motherboards, no rectangle appears at all! Anyways, you will know when it is done because it shows you a prompt after applying the image.


How would one go about replacing that whole progress sub with an animated picture "loading.gif"?

#66 User is offline   Tripredacus 

  • K-Mart-ian Legend
  • Group: Super Moderator
  • Posts: 8,723
  • Joined: 28-April 06
  • OS:Server 2012
  • Country: Country Flag

Posted 08 June 2013 - 09:12 AM

Uggg apparently there was a database rollback and my reply to this was lost. I will post again on Monday and see if I can reconstruct that reply. :(

#67 User is offline   Tripredacus 

  • K-Mart-ian Legend
  • Group: Super Moderator
  • Posts: 8,723
  • Joined: 28-April 06
  • OS:Server 2012
  • Country: Country Flag

Posted 10 June 2013 - 08:35 AM

To the best of my knowledge, the gray rectangle is from either one of these subs, right at the very end of the VBScript.

Sub objWIM_Progress(Percent,TimeRemaining)
On Error Resume Next
objShell.Popup Percent, 1, "Title", -1
If Percent = 100 Then
progress.innerHTML = "<table border='0'><tr><td>Percents completed: </td><td>100 % </tr><tr><td>Time remaining: </td><td>0 min 0 sec</td></tr></table>"
Exit Sub
Else
Call ProgressHelper(Percent,TimeRemaining)
End If

End Sub

Sub ProgressHelper(pr,tr)
On Error Resume Next
intFMin = (tr MOD 3600) \ 60
intFSec = (tr MOD 3600) MOD 60
progress.style.visibility = "visible"
progress.innerHTML = "<table border='0'><tr><td>Percents completed: </td><td>" & pr & "%" & "</td></tr><tr><td>Time remaining: </td><td>" & intFMin & " min " & intFSec & " sec</td></tr></table>"
If pr = 100 Then
window.clearInterval(iTimerID)
progress.innerHTML = "<table border='0'><tr><td>Percents completed: </td><td>100 % </tr><tr><td>Time remaining: </td><td>0 min 0 sec</td></tr></table>"
Else
Exit Sub
End If

End Sub


As a way to replace that, I can think maybe change it to show a pop-up HTA similar to the Diskpart/format select screen, but instead the HTA would be fairly simple and have a Style Body object that has this:

background-image:url('resources\imagex.gif')


This is only an example. If you have any questions relating to VBScript, ask them here:
http://www.msfn.org/...s-cmdbatch-etc/

Share this topic:


  • 4 Pages +
  • « First
  • 2
  • 3
  • 4
  • You cannot start a new topic
  • You cannot reply to this topic

2 User(s) are reading this topic
0 members, 2 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2013 msfn.org
Privacy Policy