Results 1 to 4 of 4

Thread: Where are you HDF?

  1. #1

    Thread Starter
    Fanatic Member coox's Avatar
    Join Date
    Oct 1999
    Posts
    550
    You offered me some help on using Excel objects, and I wanted to ask you more... could you possibly email me?

    [email protected]

    Cheers!

  2. #2

    Thread Starter
    Fanatic Member coox's Avatar
    Join Date
    Oct 1999
    Posts
    550
    Are you there?

  3. #3
    Addicted Member
    Join Date
    Jan 2000
    Location
    Fresno, California, USA
    Posts
    195
    I'm sorry, I didn't go back to the post and check it again. Here is some code that will insert data into an EXCEL cell. By the way, this is part of my first VB application. The sheriff's department is still using that application to move raw data from it's dispatch system, to EXCEL to track crime statistics. Good luck.


    Private xlOut As Excel.Application

    Set xlOut = CreateObject("Excel.Application")
    ' You put in path and file name.
    xlOut.Workbooks.Open xlOutPath & xlOutFileName & ".xls"
    ' If you want to see it, uncomment.
    'xlOut.Visible = True
    ' You put in the name of the worksheet,
    xlOut.Worksheets(xlOutWorkSheetName).Activate
    ' and the row and column.
    xlOut.Worksheets(xlOutWorkSheetName).Cells(intOutRow, intOutColumn) = Data
    xlOut.ActiveWorkbook.Close SaveChanges:=True
    Set xlOut = Nothing
    xlOut.Quit

  4. #4

    Thread Starter
    Fanatic Member coox's Avatar
    Join Date
    Oct 1999
    Posts
    550
    Cheers HDF, I'll let you know how I get on with it.

    By the way, will this work with an inserted excel worksheet? I was trying to do it by adding it to the toolbox from the Insertable Objects tab, and then painting it on to a form. But I couldn't figure out how to get the normal excel properties to work with that.

    Thanks a lot anyway!

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