Page 1 of 1

Windows Guck and Windows API.

Posted: Sun Feb 10, 2008 10:18 am
by Yourself
I needed to use a console interface for my application which is being made in Delphi.
So I just decided to use PB to create a console DLL.
It runs fine but...
Every time I move the CONSOLE window, it leaves behind an image of itself and that too on the calling application and one nothing else :(
Any remedies?
And How do I use WinAPI in PB.
I know that the commands have to have an underscore in them but lets say ..

Code: Select all

CreateWindow(

    LPCTSTR lpClassName,	// pointer to registered class name
    LPCTSTR lpWindowName,	// pointer to window name
    DWORD dwStyle,	// window style
    int x,	// horizontal position of window
    int y,	// vertical position of window
    int nWidth,	// window width
    int nHeight,	// window height
    HWND hWndParent,	// handle to parent or owner window
    HMENU hMenu,	// handle to menu or child-window identifier
    HANDLE hInstance,	// handle to application instance
    LPVOID lpParam 	// pointer to window-creation data
   );
Thats from the WinAPI manual.
How do I implement it in PB.
An example would help me out.
Thanks

Posted: Sun Feb 10, 2008 12:02 pm
by hallodri

Posted: Sun Feb 10, 2008 12:41 pm
by pdwyer
when you say "console" do you not mean the features of:

OpenConsole()
CloseConsole()

?

Posted: Sun Feb 10, 2008 1:06 pm
by Yourself
>pdwyer >
Yeah I do mean them.
Its created all right, text IS being displayed. but the display gets messed up :(

Posted: Sun Feb 10, 2008 8:21 pm
by Heathen
You should download the PB code archive, it's a good learning tool.