Error Amigous reference

Moderator: Rathinagiri

Post Reply
radohabjan
Posts: 99
Joined: Mon Nov 30, 2009 7:17 am
Location: Slovenia
Contact:

Error Amigous reference

Post by radohabjan »

Hello friends,

I have one problem with harbour compailing.
I changed h_edit_ex.prg to get my desktop height and width from my program:

// Tamańo de la pantalla.
*_nAltoPantalla := getDesktopHeight()
*_nAnchoPantalla := getDesktopWidth()
_nAltoPantalla := ndesktoph
_nAnchoPantalla := ndesktopw

In compiling I get error:

c:\hmg.3.4.4\SOURCE\EditEx>buildlib
Harbour 3.2.0dev (r1703241902)
Copyright (c) 1999-2016, http://harbour-project.org/
Compiling 'h_edit_ex.prg'...
h_edit_ex.prg(551) Warning W0001 Ambiguous reference 'NDESKTOPH'
h_edit_ex.prg(552) Warning W0001 Ambiguous reference 'NDESKTOPW'

In my old Harbour days this worked without errors. Is there any solution?

br Rado
User avatar
Anand
Posts: 595
Joined: Tue May 24, 2016 4:36 pm
DBs Used: DBF

Re: Error Amigous reference

Post by Anand »

Hi Rado,

To fix "Ambiguous reference" declare ndesktoph and ndesktopw variables as local or private.
In old harbour days /w warning in compilation was not done to allow loosely written clipper codes to compile.

Regards,

Anand
Regards,

Anand

Image
radohabjan
Posts: 99
Joined: Mon Nov 30, 2009 7:17 am
Location: Slovenia
Contact:

Re: Error Amigous reference

Post by radohabjan »

thx for support

Where are now good old days .....

br Rado
Post Reply