The MASM Forum

Projects => Rarely Used Projects => PowerBASIC => Topic started by: hutch-- on September 14, 2020, 10:26:44 AM

Title: Window Maker Version 4
Post by: hutch-- on September 14, 2020, 10:26:44 AM
I have done a number of updated in this later version, stripped the inline comments and slightly reformatted the side comments., The output is a window with a menu and status bar with user defined client area colour easily modified. Some of the internal code has been updated to reflect more modern tasks but the code is efficient and properly documented Microsoft API code.

To set it up you use the 4 text entry slots for the include path and required binaries and its good to go. I mainly use this tool for prototyping and instead of having to grind through a heap of boilerplate code, it will deliver a working window in seconds which is designed to be modified to suit the task at hand.

It is designed for PBWIN version 10 although it will probably run on version 9.
Title: Re: Window Maker Version 4
Post by: jj2007 on September 14, 2020, 05:03:49 PM
Project.log:
Code: [Select]
Classic PowerBASIC for Windows
Classic PB/Win  Version 9.07
Copyright (c) 1996-2012 PowerBasic Inc.
Englewood, Florida USA
All Rights Reserved

Error 524 in Project.bas(34:027):  Undefined TYPE
Line 34:     LOCAL szClassName  as STRINGZ * 64
Title: Re: Window Maker Version 4
Post by: hutch-- on September 14, 2020, 05:58:09 PM
Been a while since I used version 9.0.

Change "STRINGZ" to "ASCIIZ" and see if it runs.
Title: Re: Window Maker Version 4
Post by: HSE on September 15, 2020, 02:47:29 AM
Change "STRINGZ" to "ASCIIZ" and see if it runs.
:thumbsup:
Title: Re: Window Maker Version 4
Post by: jj2007 on September 15, 2020, 04:31:41 AM
Change "STRINGZ" to "ASCIIZ" and see if it runs.

Yep, that works, for me and HSE :thumbsup:

Maybe a little check to set the default include & exe etc paths? The exit code is the version number:
Code: [Select]
include \masm32\MasmBasic\MasmBasic.inc
  Init
  GetRegKeyArray "HKCU\Software\PowerBASIC\PB/Win", pb$()
  For_ ecx=0 To eax-1
.if Val(pb$(ecx))>edi
xchg eax, edi
mov esi, pb$(ecx)
.endif
  Next
  Print Str$("You have got version %i, and your compiler sits at ", edi), GetRegVal(Cat$("HKCU\Software\PowerBASIC\PB/Win\"+esi+"\Compiler"), "Compiler", "Test"), CrLf$
EndOfCode edi

Output:
Code: [Select]
You have got version 9, and your compiler sits at J:\PowerBasic\bin\PBWin.exe
Title: Re: Window Maker Version 4
Post by: bobl on September 15, 2020, 08:39:38 PM
Thank you very much for this.