Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Can I run two macros in the same time?
Thank for the help Emil. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
That would require multi-threading and the answer is no. That being said what
are you up to that leads you to believe you want to run two different macro's at the same time? -- HTH... Jim Thomlinson "emil" wrote: Can I run two macros in the same time? Thank for the help Emil. |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Jim Thomlinson wrote:
That would require multi-threading and the answer is no. That being said what are you up to that leads you to believe you want to run two different macro's at the same time? The answer in general is no. But sometimes is yes. Create two user forms and set their Show modal property to false. Put you macro to Form_Activate() or UserForm_Click() or similar place where you can somehow start it. Now you have mutli-threading because Windows is in its nature mutli-threading. |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thank, but I must explain:
I rules two macros. The first macro record and print an order with quantities from an available stock of items. It rules in 30 seconds. After this order I must print another order but I must check the stock and the client for that. This macro rules in 3 minutes, and is too long time. How can I solve this problem? Thank for any idea. Emil. "Jim Thomlinson" a scris: That would require multi-threading and the answer is no. That being said what are you up to that leads you to believe you want to run two different macro's at the same time? -- HTH... Jim Thomlinson "emil" wrote: Can I run two macros in the same time? Thank for the help Emil. |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I do not beleive that is correct. At no point in time can I have two threads
of exectution running concurrently (even with 2 userforms). Try this. Create two userforms with a button and a label on each. Attach this code to the button of each... Private Sub CommandButton1_Click() Dim lng As Long For lng = 1 To 10000000 Label1.Caption = lng Repaint Next lng End Sub Now display both forms non-modal and run the code on each form. I think you will find you can't. You can not begin execution of code on the second form until the code on the first form completes. -- HTH... Jim Thomlinson "witek" wrote: Jim Thomlinson wrote: That would require multi-threading and the answer is no. That being said what are you up to that leads you to believe you want to run two different macro's at the same time? The answer in general is no. But sometimes is yes. Create two user forms and set their Show modal property to false. Put you macro to Form_Activate() or UserForm_Click() or similar place where you can somehow start it. Now you have mutli-threading because Windows is in its nature mutli-threading. |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thank you very much. I must try it, i think that is not simple but I will try.
Emil "witek" a scris: Jim Thomlinson wrote: That would require multi-threading and the answer is no. That being said what are you up to that leads you to believe you want to run two different macro's at the same time? The answer in general is no. But sometimes is yes. Create two user forms and set their Show modal property to false. Put you macro to Form_Activate() or UserForm_Click() or similar place where you can somehow start it. Now you have mutli-threading because Windows is in its nature mutli-threading. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
running macros at a set time | Excel Discussion (Misc queries) | |||
Can I run two macros in the same time? | Excel Programming | |||
Run two macros in the same time. | Excel Programming | |||
time specific macros | Excel Programming | |||
Two Macros at the same time?? is it possible | Excel Programming |