Sr. Antonio:
Lines 35, Functions/Procedures 1
Generating C source output to 'shtest.c'...
Done.
Borland C++ 5.82 for Win32 Copyright (c) 1993, 2005 Borland
shtest.c:
Warning W8075 shtest.prg 47: Suspicious pointer conversion in function HB_FUN_SHRESTARTWINDOWS
Turbo Incremental Link 5.69 Copyright (c) 1997-2005 Borland
Fatal: Too many commas on command line:
* Linking errors *
// Just for FW 32 bits
- Code: Select all Expand view
#include "FiveWin.ch"
//----------------------------------------------------------------------------//
function Main()
local oDlg
local cPrinter := GetProfString( "windows", "device", "" )
cPrinter = SubStr( cPrinter, 1, At( ",", cPrinter ) - 1 )
DEFINE DIALOG oDlg TITLE "Shell Common Dialogs" SIZE 300, 250 PIXEL
@ 10, 25 BUTTON "&Exit Windows" ACTION SHExitWindows( oDlg:hWnd ) ;
SIZE 100, 15 PIXEL
@ 30, 25 BUTTON "&Restart Windows" ACTION SHRestartWindows( oDlg:hWnd, "FiveTech Software" + CRLF + CRLF ) ;
SIZE 100, 15 PIXEL
@ 50, 25 BUTTON "&Shell About" ACTION SHAbout( oDlg:hWnd, "FW/FWH/FW++/FWC3/FWPPC", "www.Fivetechsoft.com" ) ;
SIZE 100, 15 PIXEL
@ 70, 25 BUTTON "&File Property" ACTION SHFileProperty( oDlg:hWnd, "shtest.exe" ) ;
SIZE 100, 15 PIXEL
@ 90, 25 BUTTON "&Print Property" ACTION SHPrnProperty( oDlg:hWnd, cPrinter ) ;
SIZE 100, 15 PIXEL
ACTIVATE DIALOG oDlg CENTERED
return nil
//----------------------------------------------------------------------------//
#pragma BEGINDUMP
#include <windows.h>
#include <shlobj.h>
#include <hbapi.h>
#define SHTDN_REASON_MAJOR_APPLICATION 0x00040000
HB_FUNC( SHRESTARTWINDOWS )
{
hb_retnl( RestartDialog( ( HWND ) hb_parnl( 1 ), hb_parc( 2 ), hb_parnl( 3 ) ) );
}
HB_FUNC( SHEXITWINDOWS )
{
hb_retl( ExitWindowsEx( hb_parnl( 1 ), hb_parnl( 2 ) ) );
}
HB_FUNC( SHABOUT )
{
hb_retnl( ShellAbout( ( HWND ) hb_parnl( 1 ), hb_parc( 2 ), hb_parc( 3 ), ( HICON ) hb_parnl( 4 ) ) );
}
#pragma ENDDUMP