Results 1 to 14 of 14

Thread: CreateThread Sample--Vfb(Visual Freebasic),vb7,WinFBE

Threaded View

  1. #1

    Thread Starter
    PowerPoster
    Join Date
    Jan 2020
    Posts
    5,538

    CreateThread Sample--Vfb(Visual Freebasic),vb7,WinFBE

    Code:
    Sub Form1_Command2_BN_Clicked(hWndForm As hWnd, hWndControl As hWnd)  '单击
       Dim ABC As String Ptr = New String
       *ABC = "China"
    
       'CreateThread (NULL,0,@ThreadSub,ABC,0,0)
        Threaddetach ThreadCreate(Cast(Any Ptr ,@ThreadSub) ,ABC)
    End Sub
    
    Sub ThreadSub(StrAPtr As String Ptr)
       MsgBox *StrAPtr
       Delete  StrAPtr
    End Sub
    sub ThreadSub2(Arg1 As LPVOID)
       MsgBox *Cast(String Ptr,Arg1)
       Delete  Arg1
    End Sub
    
    Sub ThreadSub3(Arg1 As Any Ptr)
       MsgBox *Cast(String Ptr,Arg1)
       Delete  Arg1
    End Sub
    VB6 has stopped updating for 25 years. We have a development tool similar to VB6. Everyone is welcome to use it together and let the VISUAL BASIC syntax last forever.

    vfb(visual freebasic),ide like vb6,vb7.support x64,createthread,asm code
    (94) Vfb IDE【Visual Freebasic】Like vb6,vb7,Update2021-2-23 - freebasic.net
    https://www.freebasic.net/forum/view...hp?f=8&t=28522
    download vfb ide:
    https://github.com/xiaoyaocode163/VisualFreeBasic
    http://www.yfvb.com/soft-48.htm (version 5.5.3,update:2021-2-23)
    Last edited by xiaoyao; Mar 11th, 2021 at 07:21 AM.

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