Results 1 to 4 of 4

Thread: OLE container limits in VB6

  1. #1

    Thread Starter
    New Member
    Join Date
    Aug 2009
    Posts
    2

    Angry OLE container limits in VB6

    I have created an application in VB6 that displays data from an Excel sheet in an OLE container.
    The application adds lines to this container by inserting new data into the first row of the worksheet, then updating the OLE container.
    However, as more lines are added, effectively off the bottom of the display, the displayed font slowly grows, until the text becomes unreadable.
    If the user right-clicks the data and edits, when the Excel edit is completed, the font returns to normal.
    This is driving me crazy, as I cannot find any way of stopping this font growth.
    Does anyone have any ideas?

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: OLE container limits in VB6

    Could you zip up your project and attach it. I'd like to run it and take a look.

  3. #3

    Thread Starter
    New Member
    Join Date
    Aug 2009
    Posts
    2

    Post Re: OLE container limits in VB6

    Hack, thanks for taking an interest.
    I've resolved that original problem, by dumping the OLE container approach, and just running Excel directly from my code.

    However, I still have a problem. though somewhat different:
    If someone tries to open the Event Log.xls sheet, whilst my app is running, that breaks the link, and I can no longer control Excel.
    I can set the file as Hidden, etc, but I would really prefer a more "hardened" form of protection. In reality, my app should be the only way of adding entries to the log.
    Your thoughts would be appreciated.
    Jim
    Attached Files Attached Files

  4. #4
    Hyperactive Member
    Join Date
    Sep 2009
    Location
    Lost in thought
    Posts
    349

    Re: OLE container limits in VB6

    You have:
    Code:
     master_file = App.Path & "\Event Log.xls"
    Maybe
    Code:
     master_file = App.Path & "\Event Log.xxls"
    or
    Code:
    master_file = App.Path & "\Event Log.slx"
    or
    Code:
    master_file = App.Path & "\Event Log.My_app_only"

    Hope it helps.
    5ms

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