Jump to content











Photo
* * * * * 1 votes

WIMMaster


  • Please log in to reply
36 replies to this topic

#1 martinr

martinr

    Frequent Member

  • Advanced user
  • 120 posts

Posted 07 September 2007 - 09:33 AM

File name: WIMMaster


Description:
I have just finished writing this program. It works like ImageX, but it is not a wrapper for that program. It was written in C and uses the Wimgapi library for its functionality.

My script includes the program in encoded form as well as some redistributable Microsoft files needed to make it work. You also need wimgapi.dll and wimfltr.sys which are included in the WAIK. The script will copy them from the WAIK if it is installed in your ProgramFiles folder.

If anyone would like to have the source code (should be useful if you are using wimgapi for the first time) or would like to have a BartPE plugin, I have put everything here for download.

Download file

#2 Nuno Brito

Nuno Brito

    Platinum Member

  • .script developer
  • 10549 posts
  • Location:boot.wim
  • Interests:I'm just a quiet simple person with a very quiet simple life living one day at a time..
  •  
    European Union

Posted 07 September 2007 - 10:53 AM

Nice work!! :loleverybody:

#3 Max_Real Qnx

Max_Real Qnx

    Gold Member

  • Patrician
  • 1382 posts
  • Location:Istanbul
  • Interests:To be or not to be that is the question.
  •  
    Turkey

Posted 07 September 2007 - 10:13 PM

Hi :loleverybody:

Thanks a lot for nice share :w00t:

I modified this nice script :w00t:

Download

#4 powaking

powaking

    Frequent Member

  • Advanced user
  • 238 posts
  • Location:Fall River, MA
  •  
    United States

Posted 19 September 2007 - 04:06 PM

Hi :w00t:

Thanks a lot for nice share :loleverybody:

I modified this nice script :w00t:

Download


What did you change and how do I remove the link on the desktop? Can't find any reference to the Desktop link.

#5 booty#1

booty#1

    Frequent Member

  • .script developer
  • 285 posts
  • Location:Near Frankfurt
  •  
    Germany

Posted 20 September 2007 - 07:26 AM

here is the diff:

[codebox]***** wimmaster.script [ExtractFiles] DirMake,"%ScriptDir%\%OutDir%" ***** ..\WIMMASTER_MAXREALQNX.SCRIPT [ExtractFiles] DirMake,"%TargetDir%\Windows\system32\config" DirMake,"%TargetDir%\Windows\system32\drivers" DirMake,"%ScriptDir%\%OutDir%" ***** ***** wimmaster.script DirCopy,"%ScriptDir%\%OutDir%\*.*","%TargetDir%\%DestDir%" FileCopy,"%ProgramFilesDir%\Windows AIK\Tools\x86\wimfltr.sys","%TargetDir%\Windows\system32\drivers" FileCopy,"%ProgramFilesDir%\Windows AIK\Tools\x86\wimgapi.dll","%TargetDir%\Windows\system32" TXTAddLine,%ES%,"%LinkDir%\%Executable%,%ParentItem%\%PName%.lnk,%LinkDir%","Append" ***** ..\WIMMASTER_MAXREALQNX.SCRIPT DirCopy,"%ScriptDir%\%OutDir%\*.*","%TargetDir%\%DestDir%" FileCopy,"%Tools%\wimfltr.sys","%TargetDir%\Windows\system32\drivers" FileCopy,"%Tools%\wimgapi.dll","%TargetDir%\Windows\system32" TXTAddLine,%ES%,"%LinkDir%\%Executable%,%ParentItem%\%PName%.lnk,%LinkDir%","Append"
*****[/codebox]

booty#1

#6 booty#1

booty#1

    Frequent Member

  • .script developer
  • 285 posts
  • Location:Near Frankfurt
  •  
    Germany

Posted 20 September 2007 - 07:42 AM

File name: WIMMaster
Description:
I have just finished writing this program. It works like ImageX, but it is not a wrapper for that program. It was written in C and uses the Wimgapi library for its functionality.


Just a little improvement:
1. Changed the used compile profile from debug to release.
2. The current version of WIMMaster.exe requires MSVCR80D.DLL, because it is compiled as "Multi-threaded DLL /MD".
I changed it to "Multi-threaded /MT" (Project Options -> Configuration Properties -> C/C++ -> Code Generation -> Runtime Library).
The attached version is now independent of MSVCR80D.DLL and 10k smaller than before (because of the missing debug infos). It has been compiled with Visual Studio C++ Express.

booty#1

Attached Files



#7 powaking

powaking

    Frequent Member

  • Advanced user
  • 238 posts
  • Location:Fall River, MA
  •  
    United States

Posted 20 September 2007 - 11:56 AM

Just a little improvement:
1. Changed the used compile profile from debug to release.
2. The current version of WIMMaster.exe requires MSVCR80D.DLL, because it is compiled as "Multi-threaded DLL /MD".
I changed it to "Multi-threaded /MT" (Project Options -> Configuration Properties -> C/C++ -> Code Generation -> Runtime Library).
The attached version is now independent of MSVCR80D.DLL and 10k smaller than before (because of the missing debug infos). It has been compiled with Visual Studio C++ Express.

booty#1



So all those dlls are not needed then from the original script? If so then this makes it much smaller.

#8 booty#1

booty#1

    Frequent Member

  • .script developer
  • 285 posts
  • Location:Near Frankfurt
  •  
    Germany

Posted 20 September 2007 - 12:14 PM

So all those dlls are not needed then from the original script? If so then this makes it much smaller.

Yes, no MS*.dll are needed.

booty#1

#9 bilou_gateux

bilou_gateux

    Frequent Member

  • Expert
  • 230 posts
  •  
    France

Posted 22 September 2007 - 10:34 AM

I have successfully captured an image from WinPE.
Unfortunately, i can't apply it to a new drive from WinPE.

I have used the same box and drive for capture and (not sucessfull) apply.

My wim file isn't corrupted as i can mount it from real windows XP.

Just would like to know if some members have fully checked the apply function.

If i'm the only one to have an issue, i have to re-create a full installation of the OS to capture :loleverybody: before checking a second time WIMmaster.

to do: try to apply the WIM file with imageX first.

#10 martinr

martinr

    Frequent Member

  • Advanced user
  • 120 posts

Posted 06 November 2007 - 09:58 AM

Just to let you know that I have updated my WIMMaster files. The changes are:

1. I have altered the VistaPE script to load wimgapi.dll and wimfltr.sys from the Tools folder. This was Max_Real Qnx's suggestion, and people may find it more convenient to work this way and not have to keep the WAIK permanently installed on their machine.

2. The executable is now statically built, so the Microsoft run time files no longer have to be included. I did in fact start working this way shortly after my previous post. booty#1 was quite right that this was the way to go because it takes up much less space on a VistaPE/BartPE disk.

3. I have made some minor changes to the source code, which were technical in nature and don't actually change the way the program works.

As before the whole package is available at this link.

By way of interest, I have also written a different version of WIMMaster which uses the SmartWIM component. The main advantage of this is that the progress bar displays with the Apply function, which it doesn't do in the Wimgapi version. The program is written using MFC, and the source code is quite instructive as it shows how to integrate a non-visual custom COM control into a C++ program.

The SmartWIM component is of course needed, but is available as a free trial version. This is fully functional but does display a nag screen when it runs each time. It is fairly expensive to buy in registered form, but seems to work very well.

This package includes again source code, BartPE plugin and VistaPE script, and is available here.

#11 powaking

powaking

    Frequent Member

  • Advanced user
  • 238 posts
  • Location:Fall River, MA
  •  
    United States

Posted 21 November 2007 - 08:23 PM

Just to let you know that I have updated my WIMMaster files. The changes are:

1. I have altered the VistaPE script to load wimgapi.dll and wimfltr.sys from the Tools folder. This was Max_Real Qnx's suggestion, and people may find it more convenient to work this way and not have to keep the WAIK permanently installed on their machine.

2. The executable is now statically built, so the Microsoft run time files no longer have to be included. I did in fact start working this way shortly after my previous post. booty#1 was quite right that this was the way to go because it takes up much less space on a VistaPE/BartPE disk.

3. I have made some minor changes to the source code, which were technical in nature and don't actually change the way the program works.

As before the whole package is available at this link.

By way of interest, I have also written a different version of WIMMaster which uses the SmartWIM component. The main advantage of this is that the progress bar displays with the Apply function, which it doesn't do in the Wimgapi version. The program is written using MFC, and the source code is quite instructive as it shows how to integrate a non-visual custom COM control into a C++ program.

The SmartWIM component is of course needed, but is available as a free trial version. This is fully functional but does display a nag screen when it runs each time. It is fairly expensive to buy in registered form, but seems to work very well.

This package includes again source code, BartPE plugin and VistaPE script, and is available here.


Am I confusing this one with another tool? I thought at one time there was a progress indicator? Also is it possible to include the task of wiping and creating a partition and also doing a quick format of the c: drive prior to applying the image?

Also in the apply tab would be nice if once you select the wim it would show what images are in the wim and the one you select is the one that gets put down on the c: drive.

I have found that on certain machines when using WIM to deploy XP images the diskpart doesn't work correctly. To work around this I had to use the tool AEFDisk32 (google it).

#12 martinr

martinr

    Frequent Member

  • Advanced user
  • 120 posts

Posted 23 November 2007 - 05:21 PM

Am I confusing this one with another tool? I thought at one time there was a progress indicator? Also is it possible to include the task of wiping and creating a partition and also doing a quick format of the c: drive prior to applying the image?

Yes, there could be some confusion here. I was involved with 3 different programs which aimed at giving a graphical interface to the wim functions:

1. The first was an AutoIt3 program which acted as a wrapper for Microsoft's imagex tool. It was variously known as gimagex or GUI-Imagex wrapper.exe. It was not my creation, but I did some work on it later. Originally, it tried to provide a progress bar by using a program called RTConsole.exe, and also disk partitioning by using DiskPartitioner.exe, a graphical version of Microsoft's diskpart. I was unable to get either of these to work in this context, and eventually took them both out in the version I used. The full story is available at this site. My VistaPE script incorporating this version is still available for download as part of version 010.

2. The next was the WIMMaster program which I wrote in C, and which is the real subject of this topic. This program uses Microsoft's WImgapi library directly, rather than imagex. The progress bar feature is available and works with the Capture/Append and Export functions, but not with Apply. This is apparently due to a thread change which Microsoft made to the Apply part of Wimgapi, which blocks access to the messages which provide progress information.

3. The last is a variation on WIMMaster, written in C++ and using MFC and the SmartWIM component from SmartDeploy. This works best of all, and has a progress bar which works with Apply as well. The only drawback is that a registered version of SmartWIM costs $299. The trial version is however free and fully functional but has a nag screen.

Also in the apply tab would be nice if once you select the wim it would show what images are in the wim and the one you select is the one that gets put down on the c: drive.

The GUI-Imagex wrapper program does in fact provide this facility, which it calls Poll Image Number. It is also available for Mount/Unmount and Delete. I decided to provide something similar in WIMMaster under the Info tab. You only have to remember the number for a second before entering it in the other tab.

I have found that on certain machines when using WIM to deploy XP images the diskpart doesn't work correctly. To work around this I had to use the tool AEFDisk32 (google it).

The graphical program DiskPartitioner.exe does seem to work well under XP, in fact better than it does in Vista. There is information about this at this link, and more help with a VistaPE script here.

The AEFDisk32 program sounds interesting and I have downloaded the latest version.

#13 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7100 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 23 November 2007 - 07:02 PM

Just to keep things as together as possible, there is also this app GimageX:
http://www.911cd.net...showtopic=20706

jaclaz

#14 martinr

martinr

    Frequent Member

  • Advanced user
  • 120 posts

Posted 24 November 2007 - 12:39 PM

Just to keep things as together as possible, there is also this app GimageX:
http://www.911cd.net...showtopic=20706

jaclaz

Thanks. This really is interesting. It has its origins in the AutoIt3 program Gimagex I referred to above, but like my WIMMaster prog it is written in C or C++ and uses the Wimgapi library.

The author Jonathan Bennett has managed to do what I couldn't do (nor anyone else as far as I am aware), which is to run a progress bar for the Apply feature. SmartWIM seemed to be the only way to go to achieve that, but Jon works for Microsoft and will have access to more info about the Wimgapi than the rest of us.

I like his program. As you would expect, it has a professional feel to it, and it even comes with a Microsoft EULA!

I would really like to see his source code, to find out how he implemented that progress bar, and also his Change feature which allows you to change the names and descriptions of images. I guess that Microsoft wouldn't allow him to release it.

#15 martinr

martinr

    Frequent Member

  • Advanced user
  • 120 posts

Posted 24 November 2007 - 03:15 PM

I have been checking out the new ImageX GUI v2.0.1 BETA program. It seems to perform very well.

Just to show how much I like it and that I bear no professional jealousy towards Jonathan Bennett, I have uploaded a version 010 VistaPE script for people to try it.

Having read the Microsoft EULA, I did not dare to embed the actual program into the script. You will therefore need to download it from the links which jaclaz provided, and put the file and the EULA (?) into your gimagex folder.

Once again, I have assumed that the WAIK is installed on your machine, but if it isn't, you will need wimfltr.sys and wimgapi.dll and amend the script to copy them into the locations I have indicated.

Attached Files



#16 TheHive

TheHive

    Platinum Member

  • .script developer
  • 4171 posts

Posted 24 November 2007 - 07:13 PM

thanks for the script

#17 Jotnar

Jotnar

    Member

  • Members
  • 35 posts

Posted 03 December 2007 - 01:07 AM

For those interested in GImageX...

v2.0.4

2nd Dec 2007 - v2.0.4
- Improved mount/unmount interface.

2nd Dec 2007 - v2.0.3
- Improved image selection interface.

1st Dec 2007 - v2.0.2
- Added Delete tab.
- Added Export tab.
- Some internal improvements to XML handling.

http://www.autoitscript.com/gimagex/

Cheers

#18 martinr

martinr

    Frequent Member

  • Advanced user
  • 120 posts

Posted 11 December 2007 - 07:48 PM

Good News! WIMMaster is now better than ever :cheers:

Thanks to a tip from Jonathan Bennett, the author of ImageX GUI v2.0.4, I have been able to get the progress bar working with the Apply function. So it now works the way I always wanted it to.

As previously, my C/C++ source code, the VistaPE script and a BartPE plugin are all available for download from this link.

Having expressed my excitement at this new development, let me say that I have a very high regard for Jonathan's own program, which has a few more features than my own, and looks really good.

Thanks, Jonathan, for your help :cheers:

#19 Jotnar

Jotnar

    Member

  • Members
  • 35 posts

Posted 18 December 2007 - 01:32 PM

15th Dec 2007 - v2.0.5 BETA
- Image selection screen was not working properly when an image did not contain both a name and description

Also I noticed the EULA is now non-Microsoft and now provides for distribution. You still can't distribute wimgapi.dll, but the main program gimagex.exe can be distributed as long as it comes with the EULA and the readme.txt file.

Cheers

#20 martinr

martinr

    Frequent Member

  • Advanced user
  • 120 posts

Posted 19 December 2007 - 06:55 PM

Also I noticed the EULA is now non-Microsoft and now provides for distribution. You still can't distribute wimgapi.dll, but the main program gimagex.exe can be distributed as long as it comes with the EULA and the readme.txt file.

GImageX is now version 2.0.6.

I have updated my script which I posted previously. Due to the change in the EULA, I have been able to embed the program (and the EULA) into the script. The new version is attached, and is also available here.

Attached Files



#21 martinr

martinr

    Frequent Member

  • Advanced user
  • 120 posts

Posted 10 January 2008 - 04:19 PM

I mentioned in an earlier post that I had written a variation of my WIMMaster program which used the SmartWim component from SmartDeploy. The only drawback was that the full version cost $299, and the trial version had a nag screen until registration.

There is good news here. SmartDeploy have recently released a new version of their component (v 1.1.1) which no longer carries the nag screen and is completely free for non-commercial use.

The source code, BartPE plugin and VistaPE script for this version of WIMMaster is still available for download from this link, and seems to work fine with the new component.

#22 NightMan

NightMan

    Frequent Member

  • .script developer
  • 433 posts
  • Location:Russian, Moscow

Posted 11 January 2008 - 07:57 AM

I mentioned in an earlier post that I had written a variation of my WIMMaster program which used the SmartWim component from SmartDeploy. The only drawback was that the full version cost $299, and the trial version had a nag screen until registration.

There is good news here. SmartDeploy have recently released a new version of their component (v 1.1.1) which no longer carries the nag screen and is completely free for non-commercial use.

The source code, BartPE plugin and VistaPE script for this version of WIMMaster is still available for download from this link, and seems to work fine with the new component.


Good news!

ps your program request wimgapi.dll? i test on Win 2003 x64 and try add wimgapi.dll x64 version - WIMMaster.exe can not find it, but if i add x86 version of wimgapi.dll it's starting, but noting happened, i not see any windows :cheers:

#23 martinr

martinr

    Frequent Member

  • Advanced user
  • 120 posts

Posted 11 January 2008 - 10:57 AM

Good news!

ps your program request wimgapi.dll? i test on Win 2003 x64 and try add wimgapi.dll x64 version - WIMMaster.exe can not find it, but if i add x86 version of wimgapi.dll it's starting, but noting happened, i not see any windows :cheers:

I haven't tried it myself in x64.

The problem may be with the SmartWIM component. According to the Features section of the Help file, it "works with all 32-bit development environments that can use ActiveX components, including VB, VBScript, VC++, VB.NET, C#". I guess that it doesn't work in 64-bit.

#24 NightMan

NightMan

    Frequent Member

  • .script developer
  • 433 posts
  • Location:Russian, Moscow

Posted 11 January 2008 - 11:10 AM

i try use it in Windows 2008 x86 (without WAIK), but it's not working too :cheers:

(i not have WinXP x86 for testing right now)

wimmaster.jpg

#25 martinr

martinr

    Frequent Member

  • Advanced user
  • 120 posts

Posted 12 January 2008 - 10:03 AM

Your WIMMaster.exe and wimgapi.dll files both seem to be fine.

For the program to work, you need to have SmartWIM.dll installed on your machine. It is downloadable from here. It doesn't matter much where you put the file, as long as you leave it in that folder. The component then needs to be registered, using:

regsvr32.exe "full path and filename of SmartWIM.dll".

WIMMaster runs perfectly on my machines under both WinXP and Vista. I haven't tried it under Windows Server 2003.

Using the program in VistaPE, you just need to copy SmartWIM.dll into %ScriptDir%\wimmaster before running WinBuilder. The registration of the component is done through the script.

You also need wimfltr.sys for Mount/Unmount to work, but the program should run and work in other areas without it. The VistaPE script copies this file from the WAIK and makes the necessary registration entries.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users