Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Copy
Message
From
24/11/2011 05:58:00
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Copy
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows XP
Network:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01529742
Message ID:
01529742
Views:
89
hi all,
i need to copy this excel book as..
COPY TO ('c:\dept\zarqa\') TYPE XL5 insteadof COPY TO (gcDelimFile) XLS
gcDelimName = ALIAS( ) + '.xls'
gcDelimFile = PUTFILE('excel_file:', gcDelimName, 'xls')
IF EMPTY(gcDelimFile)  
CANCEL
ENDIF
 COPY TO (gcDelimFile) XLS 
 

Local loExcel 
xlDown =   -4121
xlLastCell = 11

loExcel = CREATEOBJECT('Excel.Application')
loExcel.DisplayAlerts = .F.


LoWb = loExcel.WorkBooks.OPEN(gcDelimFile)
loWs = loExcel.WorkSheets(1)

loWs.Rows("1:"+Transform(3)).insert(xlDown)
lows.Range(lows.Cells(1,1),lows.Cells(1,lows.Application.ActiveCell.SpecialCells(xlLastCell).Column) ).MergeCells = .T.
loWS.cells(1,3).Font.bold  = .t.

loWS.cells(1,3).Font.Size= 14


loWS.cells(1,1) = " ) "+TRANSFORM(YEAR(DATE()))+'/'+TRANSFORM(MONTH(DATE())-1)
loWS.cells(1,1).Font.bold  = .t.
loWS.cells(1,1).Font.Size= 14


*loExcel.VISIBLE	= .T.
*loExcel			= NULL
Next
Reply
Map
View

Click here to load this message in the networking platform