Results 1 to 10 of 10

Thread: how to run VbTrickThreading on vb6 ide,Create New Form1 or Class1 ?

  1. #1

    Thread Starter
    PowerPoster
    Join Date
    Jan 2020
    Posts
    5,042

    how to run VbTrickThreading on vb6 ide,Create New Form1 or Class1 ?

    VbTrickThreading

    i test some code,but also can't run in vb6 ide,how to fixed?

    i want to create new form1,new form2 by createthread

    https://github.com/thetrik/VbTrickThreading

  2. #2
    PowerPoster Arnoutdv's Avatar
    Join Date
    Oct 2013
    Posts
    6,432

    Re: how to run VbTrickThreading on vb6 ide,Create New Form1 or Class1 ?

    If I’m correct then multi threading only works when compiled, never from within the IDE

  3. #3

    Thread Starter
    PowerPoster
    Join Date
    Jan 2020
    Posts
    5,042

    Re: how to run VbTrickThreading on vb6 ide,Create New Form1 or Class1 ?

    Quote Originally Posted by Arnoutdv View Post
    If I’m correct then multi threading only works when compiled, never from within the IDE
    that's right.

    but can run code in vb6 ide with cteatethread

    only can't use new object

    dim f as object
    set f=new form1 'error
    set f=forms.add("form1") 'error

    set f=new class1 'err

  4. #4

    Thread Starter
    PowerPoster
    Join Date
    Jan 2020
    Posts
    5,042

    Re: how to run VbTrickThreading on vb6 ide,Create New Form1 or Class1 ?

    When i create a class in com dll(activex project)

    Function NewForm1() As Form1
    Set NewForm = New Form1
    End Function

    Compilation failed?
    Private object module cannot be used as a parameter? The return type of the public process,
    Public data members or public user-defined type fields are used in public objects

  5. #5

  6. #6

    Thread Starter
    PowerPoster
    Join Date
    Jan 2020
    Posts
    5,042

    Re: how to run VbTrickThreading on vb6 ide,Create New Form1 or Class1 ?

    Quote Originally Posted by The trick View Post
    You can't use threading in IDE because there is a single instance of the global VM data. Whatever you do it'll be unstable.
    You might be able to run multithreading inside a com DLL. Then call back and execute the function in idE.

  7. #7
    PowerPoster Arnoutdv's Avatar
    Join Date
    Oct 2013
    Posts
    6,432

    Re: how to run VbTrickThreading on vb6 ide,Create New Form1 or Class1 ?

    Why the urge to run it from the IDE?
    But make it if you think it’s possible

  8. #8

    Thread Starter
    PowerPoster
    Join Date
    Jan 2020
    Posts
    5,042

    Re: how to run VbTrickThreading on vb6 ide,Create New Form1 or Class1 ?

    Quote Originally Posted by Arnoutdv View Post
    Why the urge to run it from the IDE?
    But make it if you think it’s possible
    Maybe you can just compile it into an exe and run it. F5 = compile to exe + run + debugYou can even modify the code.Look at the value of each variable.

    Exe + create thread + VBA SDK, maybe that's what it means.

  9. #9
    Hyperactive Member
    Join Date
    Mar 2019
    Posts
    478

    Re: how to run VbTrickThreading on vb6 ide,Create New Form1 or Class1 ?

    Function NewForm1() As Form not Form1 I think.

    But this has nothing to do with threading

  10. #10

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