Page 2 of 4

Re: Xlsxlibhb_ver2

Posted: Sat Nov 04, 2023 1:09 pm
by nageswaragunupudi
Creae the class using:

Code: Select all | Expand

oXlsx := XlsxObj( cFileXlsx, cSheetName )
For the first tests:

Code: Select all | Expand

WITH OBJECT oXlsx
:Say( 0,0,"NEW" )
:Say( 1,1, 200 )
:Say( 2,1, 500 )
:Say( 3,1,"=SUM(A2:A3)" )

:Close()
END

ShellExecute( 0, "Open", oXlsx:cFile )
Also see fwh\samples\xlsx01.prg

We will soon provide more information

Re: Xlsxlibhb_ver2

Posted: Sat Nov 04, 2023 1:18 pm
by nageswaragunupudi
METHODS

Code: Select all | Expand

METHOD AddSheet( cNewSheetName )
METHOD Address( nRow, nCol, nRow2, nCol2 ) // Adddress( 1,1 ) -> "B2"
METHOD RowHeight( nRow, nHeight, oFormat, lPixel ) 
METHOD SetColumnSize( nColFrom, nColTo, nWidth, oFormat, lPixel ) 
METHOD MergeRange( r1, c1, r2, c2, cValue, oFormat ) 
METHOD SayImage( nRow, nCol, cImage ) 
METHOD SayFormula( nRow, nCol, cFormula, oFormat, cPicture ) 
METHOD Say( nRow, nCol, uValue, oFormat, cPicture )\
       // Say() calls SayImage() or SayFormula 
METHOD SetBrush( cImage ) 


//These methods are for Tables only
METHOD SayRow( nRow, aValues, aFormat ) 
METHOD SetStruct( aStruct, nRow, aGroup ) 
METHOD SetFooter( aFooter, nRow ) 
METHOD SetArrayData( aData, aStruct, aGroup ) 
METHOD CreateFrom( uSrc ) 
//

METHOD Close()
CreateFrom()

Code: Select all | Expand

oXlsx := XlsxObj( cFile, cSheet )
( cAlias )->( oXlsx:CreateFrom() ) // Creates xlsx sheet from the dbf
oXlsx:Close()

Code: Select all | Expand

oXlsx := XlsxObj( cFile, cSheet )
oXlsx:CreateFrom( oAdoRecordSet ) // Creates xlsx sheet from recordset
oXlsx:Close()
We will provide more information in due course

Re: Xlsxlibhb_ver2

Posted: Sat Nov 04, 2023 1:25 pm
by nageswaragunupudi
If you set

Code: Select all | Expand

UseXLSXLIB(  .T.  )
All toExcel methods will use this lib instead of Using Excel

Re: Xlsxlibhb_ver2

Posted: Sat Nov 04, 2023 2:20 pm
by Horizon
Thank you Mr. Rao,

It is ok now.

Re: Xlsxlibhb_ver2

Posted: Sat Nov 04, 2023 2:25 pm
by nageswaragunupudi
You can also use:

Code: Select all | Expand

oXlsx:B3 := 200.00

Re: Xlsxlibhb_ver2

Posted: Mon Nov 20, 2023 11:10 pm
by leandro
Hola buenas noches para todos

Descargue la clase e intente hacer la prueba de uso, pero al compilar sale el mismo error que con la clase de Maestro Charles Kwon, creo que tiene que ver con el tema de actualización del Borland 770 o el xharbour para Bcc770.

De antemano gracias

https://forums.fivetechsupport.com/view ... 5a#p265458

Code: Select all | Expand

xHarbour 1.3.0 Intl. (SimpLex) (Build 20231104)
Copyright 1999-2023, http://www.xharbour.org http://www.harbour-project.org/
Compiling 'z:\prg\R32_menu.prg'...

100

200

100

100

100

100

100

200

300

400

500

600

700

800

900

1000

1100

100

200

100

200

300

100

200

100

200

300

400

500

600

700

800

900

1000

1100

1200

1300

1400

1500

1600

1700

1800

1900

2000

2100

2200

100

200

300

400

500

100

200

100

200

300

400

500

600

700

800

900

1000

1100

1200

1300

1400

1500

1600

1700

1800

1900

2000

2100

2200

2300

2400

2500

2600

2700

2800

2900

3000

3100
Generating C source output to 'C:\Fivedit\R32_menu.c'...
Done.

Lines 3066, Functions/Procedures 38, pCodes 13839
Embarcadero C++ 7.70 for Win32 Copyright (c) 1993-2023 Embarcadero Technologies, Inc.
C:\Fivedit\R32_menu.c:
xHarbour 1.3.0 Intl. (SimpLex) (Build 20231104)
Copyright 1999-2023, http://www.xharbour.org http://www.harbour-project.org/
Compiling 'z:\prg\R32_perm.prg'...

100

200

100

100

100

100

100

200

300

400

500

600

700

800

900

1000

1100

100

200

100

200

300

100

2/
Turbo Incremental Link 6.97 Copyright (c) 1997-2022 Embarcadero Technologies, Inc.
Error: Unresolved external '__streams' referenced from C:\DLYMA\XLSXLIB\LIB\XLSXLIBHB.LIB|drawing
Error: Unresolved external '_hb_parvptr' referenced from C:\DLYMA\XLSXLIB\LIB\XLSXLIBHB.LIB|XlxsFunc
Error: Unable to perform link
Link Error 
 

Re: Xlsxlibhb_ver2

Posted: Tue Nov 21, 2023 4:03 am
by nageswaragunupudi
Do you have FWH2310?

Re: Xlsxlibhb_ver2

Posted: Tue Nov 21, 2023 9:17 am
by leandro
Si, tenemos fwh2310

Re: Xlsxlibhb_ver2

Posted: Tue Nov 21, 2023 10:25 am
by nageswaragunupudi
Then,
first go to fwh\samples folder
open buildx.bat with notebook
Locate the two lines:

Code: Select all | Expand

rem echo %fwh%\lib\drxlsx32x_bcc.lib + >> b32.bc
rem echo %fwh%\lib\xlsxlibhbbccx.lib + >> b32.bc
Delete "rem " from the second line like this:

Code: Select all | Expand

rem echo %fwh%\lib\drxlsx32x_bcc.lib + >> b32.bc
echo %fwh%\lib\xlsxlibhbbccx.lib + >> b32.bc
Then, build and run

Code: Select all | Expand

buildx xlsx01
When you see xbrowse of customer.dbf, if you click on the "Excel" button,
- your will be prompted to select an xlsx file name to save and then
- saves the file immediately using the xlsxlib.

You will also see two more tests with images, fonts, etc.

Re: Xlsxlibhb_ver2

Posted: Tue Nov 21, 2023 10:56 am
by leandro
Mr.Rao hice lo que mencionaste, pero nos sale error

Code: Select all | Expand

┌────────────────────────────────────────────────────────────────────────────┐
?FiveWin for xHarbour 23.10 - Oct. 2023          Harbour development power  │▄
?(c) FiveTech 1993-2023 for Microsoft Windows 9X/NT/200X/ME/XP/Vista/7/8/10 │█
└────────────────────────────────────────────────────────────────────────────┘?
  ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀?
Compiling...
xHarbour 1.3.0 Intl. (SimpLex) (Build 20231104)
Copyright 1999-2023, http://www.xharbour.org http://www.harbour-project.org/
Compiling 'xlsx01.prg' and generating preprocessed output to 'xlsx01.ppo'...
Generating C source output to 'xlsx01.c'...
Done.
Lines 121, Functions/Procedures 4, pCodes 387
Embarcadero C++ 7.70 for Win32 Copyright (c) 1993-2023 Embarcadero Technologies, Inc.
xlsx01.c:
Turbo Incremental Link 6.97 Copyright (c) 1997-2022 Embarcadero Technologies, Inc.
Error: Unresolved external '__streams' referenced from C:\FWH2310\LIB\XLSXLIBHBBCCX.LIB|drawing
Error: Unable to perform link
* Linking errors *

C:\fwh2310\samples>

Re: Xlsxlibhb_ver2

Posted: Tue Nov 21, 2023 11:16 am
by Enrico Maria Giordano
leandro wrote:

Code: Select all | Expand

Error: Unresolved external '__streams' referenced from C:\FWH2310\LIB\XLSXLIBHBBCCX.LIB|drawing
The symbol "_streams" is used inside the lib XLSXLIBHBBCCX.LIB. It is impossible to fix it without the source code. As a stupid test, try to define a dummy "_streams" symbol (note: with only one underscore). Something like this:

Code: Select all | Expand

FUNCTION _STREAMS(); RETURN NIL

Re: Xlsxlibhb_ver2

Posted: Tue Nov 21, 2023 11:20 am
by nageswaragunupudi
I have used our old xharbour and everything is working perfectly.
I will try with new version also.

Re: Xlsxlibhb_ver2

Posted: Tue Nov 21, 2023 11:25 am
by nageswaragunupudi
Errors with new version:

Code: Select all | Expand

Turbo Incremental Link 6.70 Copyright (c) 1997-2014 Embarcadero Technologies, Inc.
Error: Unresolved external '___get_std_stream' referenced from C:\XHARBOUR\LIB\COMMON.LIB|hbtrace
Error: Unresolved external '__chdir' referenced from C:\XHARBOUR\LIB\HBZIP.LIB|zipplatform
Error: Unable to perform link
* Linking errors *
 
It is ok.
The authors made the full source code available.
FWH will try to build a new lib with new xHarbour.

Till then we can continue the work with older xHarbour

Re: Xlsxlibhb_ver2

Posted: Tue Nov 21, 2023 11:30 am
by Enrico Maria Giordano
Can I see the source code you are trying to compile, please? I'm using the new build without any problem.

Re: Xlsxlibhb_ver2

Posted: Tue Nov 21, 2023 11:40 am
by nageswaragunupudi
The problem is not only with the xlsx library.
Having problems with all progams with this new xharbour build,

trying to build the most simple program in the samples folder
samples\tutor01.prg

Code: Select all | Expand

Compiling...
xHarbour 1.3.0 Intl. (SimpLex) (Build 20231104)
Copyright 1999-2023, http://www.xharbour.org http://www.harbour-project.org/
Compiling 'tutor01.prg' and generating preprocessed output to 'tutor01.ppo'...
Generating C source output to 'tutor01.c'...
Done.
Lines 13, Functions/Procedures 1, pCodes 16
Embarcadero C++ 7.00 for Win32 Copyright (c) 1993-2015 Embarcadero Technologies, Inc.
tutor01.c:
Borland Resource Compiler  Version 5.40
Copyright (c) 1990, 1999 Inprise Corporation.  All rights reserved.
Turbo Incremental Link 6.70 Copyright (c) 1997-2014 Embarcadero Technologies, Inc.
Error: Unresolved external '___get_std_stream' referenced from C:\XHARBOUR\LIB\COMMON.LIB|hbtrace
Error: Unresolved external '__chdir' referenced from C:\XHARBOUR\LIB\HBZIP.LIB|zipplatform
Error: Unable to perform link
* Linking errors *
 
So for now, it is safe to use older vesion of xHarbour till these problems are fixed.

Keep aside the issue of drxlsx or xlsxlib. We can handle them later.

First thing we should be able to build our own programs and run.
Better we revert to older xharbour for the time being till our Experts resolve these issues.