by PorkNBeans (3 Submissions)
Category: Coding Standards
Compatability: Visual Basic 3.0
Difficulty: Beginner
Date Added: Wed 3rd February 2021
Rating: (3 Votes)
After attempting to use various manifest creators and uilities found here and finding out it either doesn't work at all or works but with errors I decided to add minor fixes and explain exactly how to implement windows xp theme use and not get an error... Well I hope you don't get an error cause mine doesn't generate errors. Now don't get me wrong there are a few manifest programs I found that worked fine in displaying the content but I was getting various errors from them when using other components in the program and this seems to have worked with most of the components I have.
I didn't create this coding but I did figure out how to avoid errors, at least on my own machine and if this helps you please toss a vote just for the sake of all this typing and rambling. *lol*
Additional Note I Left Out: You do not need to add Reunion.exe for your app file name it can be just reunion without the exe (of course reunion probably iisn't the name of your exe but mine is so just for ease of the explanation)
A piece of advice when doing xp theming, if you place the controls within a frame they will form a ugly black outline so make your controls on the form not inside of a frame then move the controls to the frame.
In your form add the following:
Option Explicit
Private Declare Function InitCommonControls
Lib "Comctl32.dll" () As Long
Private Sub Form_Initialize()
Dim XP As Long
XP = InitCommonControls
End Sub
Now in a good text editor geared towards coding languages (such as edit plus) you add this.
#?xml version="1.0" encoding="UTF-8" standalone="yes"?#
#assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0"#
#assemblyIdentity
version="1.0.0.0"
processorArchitecture="X86"
name="PorkORamaInc.ClassReunionCompanion.Reunion.exe"
type="win32"
/#
#description#WindowsExecutable#/description# "
#dependency#
#dependentAssembly#
#assemblyIdentity
type="win32"
name="Microsoft.Windows.Common-Controls"
version="6.0.0.0"
processorArchitecture="X86"
publicKeyToken="6595b64144ccf1df"
language="*"
/#
#/dependentAssembly#
#/dependency#
#/assembly#
Now for some explanations...
this line here :
name="PorkORamaInc.ClassReunionCompanion.Reunion.exe"
PorkORamaInc would be your company name
ClassReunionCompanion Would Be Your Product Name
Reunion.exe of course would be your programs exe name
This line here:
#description#WindowsExecutable#/description#
well thats basically what it appears to be, it's your files description.
when done save the file as the following
Reunion.exe.manifest
reunion.exe would be replaced by the actual name of your programs executable file.
Due to psc treating the code as html i had to replace the < and > with # so just replace them when using this code.