Results 1 to 4 of 4

Thread: into excel

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Sep 2001
    Location
    Philippines
    Posts
    75

    into excel

    hi all

    i know this is pretty simple but is there anybody has a code that writes to an excel file.

    thanks again....

    tazzzman2001
    [email protected]

  2. #2
    PowerPoster
    Join Date
    Aug 2000
    Location
    IN SILENCE
    Posts
    6,441
    Remaining quiet down here !!!

    BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....

  3. #3
    Frenzied Member Microbasic's Avatar
    Join Date
    Mar 2001
    Posts
    1,402
    VB Code:
    1. 'NOTE: ADD REFERENCE TO MICROSOFT EXCEL 8.0/9.0 LIBRARY
    2. Public Sub WriteCell(ByVal FileName As String, ByVal SheetIndex As Long, ByVal Cell As String, ByVal CellValue As String)
    3.     Dim app As New Excel.Application, mybook As Excel.Workbook
    4.     Dim tmp As Excel.Worksheet
    5.     Set mybook = app.Workbooks.Open(FileName)
    6.     mybook.Worksheets(SheetIndex).Range(Cell).Value = CellValue
    7.     mybook.Close True
    8. End Sub


    MicroBasic
    Dragon Shadow Trainer

    There is no good or evil in the world...only programmers and fools .

  4. #4

    Thread Starter
    Lively Member
    Join Date
    Sep 2001
    Location
    Philippines
    Posts
    75
    Thanks guys... but there are errors when i run them. i guess its on the OS. im using NT 4. the error does not comes out if run on another OS.

    The error message is "Active X component can't crate object"
    ive check the necessary things at the REFERENCE SECTION...

    hope to resolve this soon.

    Thanks...
    tazzzman2001
    [email protected]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width