After reading help file and the questions at mibuso, I am bit confused with these terms now.
I see both of these terms (run and runmodal) working similarly but I think there must be some differnce between these two. Can anybody please clarify me what are the differences between these two and in what particular situation are these two terms used i.e. RUN and RUNMODAL?
Please enlighten me.........
Roshan Thapa
0
Comments
Pargesoft
RUN opens your form, report or dataport and just continues to execute your code.
RUNMODAL opens your form, report or dataport and waits for user interaction before it continues to execute your code. This way you can use the results like ufuk explained. But it also
bascially if you are running a transaction and then you launch a form with RUNMODAL, then the form is launched as a part of the current transaction. Which means that your current version is committed only when the form is closed, control returned to the transaction, and it completes through to a commit.
This is why its possible to use the results of the form, since the instance of the form is a part of the transaction. This also means that so long as the form is open, your transaction is also open, this is why you are not allowed to RUNMODAL with uncommitted transactions, since it would lock the database until the user presses OK or closes the from.
When you call RUN, the current transaction simply launches a new form as a completely new and unrelated transaction, and then continues on with processing. Obviously since the transaction could be complete before the user even sees the form, there is no way to pass data from this form back to the current transaction.
GD
Thanx DAVID.......... You are the boss here. Navision forums like Mibuso and dynamicsusers.net should feel proud to have you.
Thanx for such a nice explanation...... to all
Roshan
Aw shucks ... :oops: :oops: :oops: THANKS!
If you have FormA that calls FormB using RUN then a user will be able to click or activate both Forms as they are running simultaneously.
However if you have FormA call FormB using RUNMODAL the user can only work with FormB. The user cannot click on back to FormA or use FormA in any way until they have closed FormB and Navision has returned control to the calling form.
Epimatic Corp.
http://www.epimatic.com
I want F1 to give me this info
ERP Consultant (not just Navision) & Navision challenger
GD
Thanks again
Well Garak, It's not that we didn't read the application programmers' Guide or the other documentations. We did read those documentations but the universal fact is that you can't remember all the information when you are new to such field or sometimes some parts are left unnoticeably untouched.
Personally, I feel that even if you are a knowledgeable person, you should not try to dominate but should show us the correct path like others do. And asking such confusing things is much better than reveiwing the documentations because the people here come up with better explanations and examples. Thta's why I asked to enlighten me...............
I think Roshan has read the documentation and searched the forums, he is now just trying to start a discussion to get a better understanding. Of course everyone should read the manuals, but sometimes sharing someone elses experience is better than just reading.