Page 2 of 2 FirstFirst 12
Results 11 to 14 of 14

Thread: OOP Framework - reveals oxygen bug -

  1. #11

    Re: OOP Framework - reveals oxygen bug -


    One possible reason for the problem is the client picking up the wrong dll. (if it has the same name). I've been caught by this a few times when testing programs in different locations.

    The client picks up the old version and does not see your new classes.

    Charles

  2. #12

    Re: OOP Framework - reveals oxygen bug -

    Charles,
    attached is a zip file with the 3 modified files.

    I've modified them to the instructions above.

    bye
    efgee
    Attached Files Attached Files

  3. #13

    Re: OOP Framework - reveals oxygen bug -


    Thanks efgee,

    this is odd behaviour. The library side appears to be ok - the setup functions for each class show up in a PE viewer as expected. Yet the client cannot access the third function whichever one that happens to be...

    Charles

  4. #14

    Re: OOP Framework - reveals oxygen bug -


    The solution!

    Organise the group of classes so that their names are in ascending ascii order. The DLL linker expects the symbol names to ascend and will not locate those which are out of order.

    I will resolve this by sorting the entries before building the DLL but meanwhile here is the ascending order of classes

    Bear in mind that CAPs come first followed by underscore followed by lowercase.


    Charles

    [code=thinbasic]
    ' ============================================================================
    '
    ' oAPP - is the application class
    ' -
    ' - Run - message loop, returns error code if occured...
    ' - Quit - kills main window, initiates message loop to end
    ' - CommandLine - returns the command line (at start of program)
    ' - InfoBox - info message box
    ' - ErrorBox - error message box
    ' - QuestionBox - question message box
    ' - WarningBox - warning message box
    '
    ' ============================================================================



    class oAPP alias "oAPP"

    method ctor()
    method dtor()
    method Instance() as long
    method Run()
    method Quit()
    method CommandLine() as string
    method InfoBox(_Text as string)
    method ErrorBox(_Text as string)
    method QuestionBox(_Text as string)
    method WarningBox(_Text as string)

    private

    _Instance as LONG
    _Return as LONG
    _Message as MSG
    _Command as string
    _LastWindow as LONG
    _LastChild as long
    _ExitCode as long
    /
    end class

    class oA_FORM alias "oA_FORM"

    method ctor()
    method dtor()
    method show()

    protected

    _Instance as LONG
    _MainWindow as LONG
    _LastWindow as LONG
    _LastChild as LONG
    /
    hwnd as long
    wc as WndClass
    end class



    class oFORM alias "oFORM"

    method ctor()
    method dtor()
    method show()

    protected

    _Instance as LONG
    _MainWindow as LONG
    _LastWindow as LONG
    _LastChild as LONG
    /
    hwnd as long
    wc as WndClass
    end class

    [/code]

Page 2 of 2 FirstFirst 12

Similar Threads

  1. Visual Studio 2010 and .NET Framework 4.0 Overview
    By ErosOlmi in forum Development
    Replies: 3
    Last Post: 02-10-2008, 16:23

Members who have read this thread: 0

There are no members to list at the moment.

Posting Permissions

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