How can i run a form on a click off a button, the form should open without showing a record...
So it should be ready to insert a new record.
If i just do FORM.RUNMODAL('myform'), then it shows the first record of the table and i still have to press F3 to insert...
0
Answers
Remember : each line of extra code will make it more difficult for a later upgrade. And the usefulness of showing a new record on opening the form seems very limited.
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
So its pretty stupid that when you press 'New' and then see the form to insert that you still have to press F3 to be able to insert...
Be careful with this approach - it can leave a lot of blank record on your table if the user exits out. A simple solution is to use sendkeys and send an F3 on activate on the create form
Dynamics Nav Add-ons
http://www.simplydynamics.ie/Addons.html
I have an Cancel button also in this form where the user should enter the data for this new record.
I just check if all Fields are empty, if so i delete the rec
Same code in the onclose form
It's fine if you control all the potential exits but users can unfilter the record, navigate to a different record and exit from that valid record. Or my particular favourate is that if you filter on the code (assume is the key) and hit next, then the form thinks its inserting a new record with the code. If you then exit and your code deletes blank then it deletes a valid record.
Dynamics Nav Add-ons
http://www.simplydynamics.ie/Addons.html
Guess i will use the sendkey function then.
How does this work?
e.g.
http://www.mibuso.com/forum/viewtopic.p ... t=sendkeys
Have fun !
Dynamics Nav Add-ons
http://www.simplydynamics.ie/Addons.html