FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour How have a value from Xbrowse with array
Posts: 3107
Joined: Fri Oct 07, 2005 06:28 PM
How have a value from Xbrowse with array
Posted: Wed Jan 20, 2010 12:02 PM

to return a value from array I use

ON DBLCLICK Inser_Img( oBrw:aArrayData[oBrw:nArrayAt,1] )

BUT return only the record of the first column and not the record I selected : How I must make to have therecord selected ?

then

it return ".\bitmaps\test.bmp" How I can make to have all Path of this bitmap ?

sample c:\test\bitmaps\test.bmp ?

THANKS

Best Regards, Saludos



Falconi Silvio
Posts: 4043
Joined: Wed Dec 19, 2007 06:40 PM
Re: How have a value from Xbrowse with array
Posted: Wed Jan 20, 2010 12:23 PM

Hello Silvio,

There are some Filefunctions in FWH

cFileNoPath( <cFullFileName> ) --> cFileName
Returns:
<cFileName> Just the filename specified inside the full filename

Path-Convert :
cFull := CURDRIVE() + ":\" + GETCURDIR() + "\" + cFileNoPath( ".\test\test.bmp" )
msgalert( cFull ) => c:\test\test.bmp

For full Path i use a Var inside my Applications :

c_path := CURDRIVE() + ":\" + GETCURDIR()
DEFINE IMAGE oImage FILENAME c_path + "\BACKGRD.JPG"
Filename uses : c:\test\BACKGRD.JPG

Best Regards
Uwe :lol:

Since 1995 ( the first release of FW 1.9 )

i work with FW.

If you have any questions about special functions, maybe i can help.
Posts: 312
Joined: Sat Oct 08, 2005 09:12 AM
Re: How have a value from Xbrowse with array
Posted: Wed Jan 20, 2010 12:28 PM
Silvio,

try
Code (fw): Select all Collapse
oBrw:aRow[ n ]

where n is the desired column.

hth,
Detlef
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: How have a value from Xbrowse with array
Posted: Wed Jan 20, 2010 02:07 PM
Code (fw): Select all Collapse
? oBrw:aArrayData[ oBrw:nArrayAt, n ]
or 
? oBrw:aRow[ n ]

are the same.
Better is
Code (fw): Select all Collapse
? oBrw:SelectedCol():Value   // to query and
oBrw:SelectedCol():Value := uNewValue // assign a new value

The last method works whatever is the data source ( array, rdd, rs, etc).
Regards



G. N. Rao.

Hyderabad, India

Continue the discussion