I have just started my 1st project using FWH. Request all of u to forgive my ignorance. Right now I am having only 2 functions Main and BuildMenu. When I compile my project I am getting warning. Exe is working fine
Warning : Ambiguous reference: 'OWND'
oWnd is the object name of the Window
I just want to know where I am wrong.
Regards
Anser
- Code: Select all Expand view RUN
---------- Capture Output ----------
> "Compile.Bat"
D:\WinAcs>if not exist obj md obj
D:\WinAcs>c:\Borland\bcc55\bin\make -fWinAcs.rmk
MAKE Version 5.2 Copyright (c) 1987, 2000 Borland
c:\xHarbour\bin\harbour .\WinAcs.PRG /L /N /W /Oobj\ /Ic:\fwh\include;c:\xHarbour\include
xHarbour Compiler build 1.1.0 (SimpLex) (Rev. 6195)
Copyright 1999-2008, http://www.xharbour.org http://www.harbour-project.org/
Compiling '.\WinAcs.PRG'...
.\WinAcs.PRG(14) Warning W0001 Ambiguous reference: 'OWND'
.\WinAcs.PRG(16) Warning W0001 Ambiguous reference: 'OWND'
.\WinAcs.PRG(16) Warning W0001 Ambiguous reference: 'OWND'
.\WinAcs.PRG(18) Warning W0001 Ambiguous reference: 'OWND'
.\WinAcs.PRG(18) Warning W0001 Ambiguous reference: 'OWND'
.\WinAcs.PRG(18) Warning W0001 Ambiguous reference: 'OWND'
.\WinAcs.PRG(18) Warning W0001 Ambiguous reference: 'OWND'
.\WinAcs.PRG(18) Warning W0001 Ambiguous reference: 'OWND'
.\WinAcs.PRG(18) Warning W0001 Ambiguous reference: 'OWND'
.\WinAcs.PRG(18) Warning W0001 Ambiguous reference: 'OWND'
.\WinAcs.PRG(18) Warning W0001 Ambiguous reference: 'OWND'
.\WinAcs.PRG(18) Warning W0001 Ambiguous reference: 'OWND'
.\WinAcs.PRG(35) Warning W0001 Ambiguous reference: 'OWND'
.\WinAcs.PRG(43) Warning W0001 Ambiguous reference: 'OWND'
Lines 66, Functions/Procedures 2
Generating C source output to 'obj\WinAcs.c'...
Done.
c:\Borland\bcc55\bin\bcc32 -c -tWM -Ic:\xHarbour\include -oobj\WinAcs obj\WinAcs.c
Borland C++ 5.5.1 for Win32 Copyright (c) 1993, 2000 Borland
obj\winacs.c:
c:\Borland\bcc55\bin\brc32.exe -r WinAcs.rc
Borland Resource Compiler Version 5.40
Copyright (c) 1990, 1999 Inprise Corporation. All rights reserved.
echo off
echo c:\Borland\bcc55\lib\c0w32.obj + > b32.bc
echo obj\WinAcs.obj obj\One.obj obj\two.obj obj\Masters.obj, + >> b32.bc
echo WinAcs.exe, + >> b32.bc
echo WinAcs.map, + >> b32.bc
echo c:\fwh\lib\FiveHx.lib c:\fwh\lib\FiveHC.lib + >> b32.bc
echo c:\xHarbour\lib\rtl.lib + >> b32.bc
echo c:\xHarbour\lib\vm.lib + >> b32.bc
echo c:\xHarbour\lib\gtgui.lib + >> b32.bc
echo c:\xHarbour\lib\lang.lib + >> b32.bc
echo c:\xHarbour\lib\macro.lib + >> b32.bc
echo c:\xHarbour\lib\rdd.lib + >> b32.bc
echo c:\xHarbour\lib\dbfntx.lib + >> b32.bc
echo c:\xHarbour\lib\dbfcdx.lib + >> b32.bc
echo c:\xHarbour\lib\dbffpt.lib + >> b32.bc
echo c:\xHarbour\lib\hbsix.lib + >> b32.bc
echo c:\xHarbour\lib\debug.lib + >> b32.bc
echo c:\xHarbour\lib\common.lib + >> b32.bc
echo c:\xHarbour\lib\pp.lib + >> b32.bc
echo c:\xHarbour\lib\pcrepos.lib + >> b32.bc
rem Uncomment these two lines to use Advantage RDD
rem echo c:\xHarbour\lib\rddads.lib + >> b32.bc
rem echo c:\xHarbour\lib\Ace32.lib + >> b32.bc
echo c:\Borland\bcc55\lib\cw32.lib + >> b32.bc
echo c:\Borland\bcc55\lib\import32.lib + >> b32.bc
echo c:\Borland\bcc55\lib\psdk\odbc32.lib + >> b32.bc
echo c:\Borland\bcc55\lib\psdk\nddeapi.lib + >> b32.bc
echo c:\Borland\bcc55\lib\psdk\iphlpapi.lib + >> b32.bc
echo c:\Borland\bcc55\lib\psdk\msimg32.lib + >> b32.bc
echo c:\Borland\bcc55\lib\psdk\rasapi32.lib, >> b32.bc
IF EXIST WinAcs.res echo WinAcs.res >> b32.bc
c:\Borland\bcc55\bin\ilink32 -Gn -aa -Tpe -s @b32.bc
Turbo Incremental Link 5.00 Copyright (c) 1997, 2000 Borland
del b32.bc
D:\WinAcs>
This is the code
- Code: Select all Expand view RUN
#include "FiveWin.ch"
*-----------------------------------------------------------------*
Function Main()
*-----------------------------------------------------------------*
Local nScrHeight,nScrWidth
Private oWnd
nScrHeight:=GetSysMetrics(1) // Screen Height
nScrWidth :=GetSysMetrics(0) // Screen Width
DEFINE WINDOW oWnd FROM 1, 1 TO nScrHeight, nScrWidth MDI ;
TITLE "Accounting Software" ;
MENU BuildMenu() ;
COLOR "B/W"
SET MESSAGE OF oWnd TO "My Company name" NOINSET CLOCK CENTERED
ACTIVATE WINDOW oWnd MAXIMIZED ;
VALID MsgYesNo( "Do you want to quit ?" )
Return nil
*-----------------------------------------------------------------*
Function BuildMenu()
*-----------------------------------------------------------------*
Local oMenu
MENU oMenu
MENUITEM "Masters"
MENU
MENUITEM "&Account Groups" ;
ACTION Another()
MENUITEM "&Account Heads" ;
ACTION Another()
SEPARATOR
MENUITEM "&Exit" ;
ACTION oWnd:End()
ENDMENU
MENUITEM "&Transactions"
MENU
MENUITEM "&Voucher Entry" ;
ACTION ( MsgStop( "New Clients" ),;
oWnd:Say( 5, 5, "New Clients...", "GR+/G" ) )
MENUITEM "&Sales Posting" ACTION MsgInfo( "Modif. Clients" )
MENUITEM "&Delete..." ACTION MsgAlert( "Del Clients" )
SEPARATOR
MENUITEM "&Browse..." ACTION MsgInfo( "Browse Clients" )
ENDMENU
MENUITEM "&Utilities"
MENU
MENUITEM "&Calculator..." ACTION WinExec( "Calc" )
MENUITEM "&Internet..." ;
ACTION WinExec( "start iexplore www.fivetech.com", 0 )
ENDMENU
ENDMENU
Return oMenu