Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Automação Excel
Message
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Miscellaneous
Thread ID:
00648905
Message ID:
00648955
Views:
25
This message has been marked as a message which has helped to the initial question of the thread.
>Alex, este exemplo cria uma nova planilha estou tentando gravar um valor em uma célula de uma planilha gravada anteriormente, localizada em uma determinada pasta.

AAARRGGHH!

Sorry. Esse exemplo era para outra resposta nos newsgroups. Eu fiz copy and paste com erro!

Algo como:
oExcel = CreateObject("Excel.Application")
oExcel.Visible = .T.  && opcional
oWorkbook = oExcel.Workbooks.Open("test.xls")
oRange = oExcel.ActiveSheet.Range("A4:B6")
FOR nRow = 1 TO oRange.Rows.Count
  FOR nColumn = 1 TO oRange.Columns.Count
    ? oRange.Cells[nRow, nColumn].Value
  ENDFOR
ENDFOR
:)


Alex Feldstein, MCP, Microsoft MVP
VFP Tips: English - Spanish
Website - Blog - Photo Gallery


"Once again, we come to the Holiday Season, a deeply religious time that each of us observes, in his own way, by going to the mall of his choice." -- Dave Barry
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform