Results 1 to 4 of 4

Thread: Visual Basic and dll problem

  1. #1

    Thread Starter
    New Member
    Join Date
    Jun 2008
    Posts
    2

    Visual Basic and dll problem

    Im doing some mp3 ripper. In really im using RealBasic to make user interface but i think that it is not important. The user interface has made by basic and rest of it is in dll which use c. I call dll functions with declare.
    At the moment i have a problem that when i call the RipCD()- function in dll, user interface has freezed until the dll return a value. And in this case it really take several minutes to rip whole cd. Only if i put some messagebox to dll pop for example in every 2 sec, it refresh the user interface in the same time.

    Is there any solution to dll?

    It is developed by c-language but i think that many people with visual basic have had the same problem and can solve it better.

  2. #2
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    41,974

    Re: Visual Basic and dll problem

    Thread moved to 'Other BASIC' forum, which is for kinds of BASIC other than VB (while there are similarities between VB and RealBasic, several things are very different)

  3. #3

    Thread Starter
    New Member
    Join Date
    Jun 2008
    Posts
    2

    Re: Visual Basic and dll problem

    Ok then but if someone still have the solution for the problem even with visual basic, please tell me.

  4. #4
    PowerPoster dilettante's Avatar
    Join Date
    Feb 2006
    Posts
    24,487

    Re: Visual Basic and dll problem

    It sounds as if this DLL is doing a lengthy blocking operation instead of using async callbacks or event messages. If there isn't another way to call it you need another thread - and classic VB doesn't offer this, perhaps RB doesn't either.

    One hack in VB would be to create a second program to run as a second process. The main process would start and monitor this process by using API calls or a component designed for the purpose. With a little clever coding this could all be in one EXE, the first one passing a command line parameter to the "slave" process so it knows how it should act in this instance.

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