Seeking solution to avoid FORM.RUNMODAL not allowed

zeonzeon Member Posts: 130
edited 2012-04-03 in NAV Three Tier
Hi,

Based on a Vendor No. on a Sales Line, I want to create a Purchase Order. If the Purchase Order exist or more Purchase Orders exists, the user should be presented with a form showing the Purchase Orders that he can transfer the Sales Line to.

The problem is now that when I present the form to the user, I am in a transaction, so in order to show the form, I need to make a COMMIT, before opening the form. Not nice! :?

So, the flow is

On Sales Order, user presses "Create Purchase Order"
1. Filter Sales Lines to the ones having a Vendor No. on it (Vendor No. is a new field)
2. Check if Purchase Order with Buy Form Vendor No. = Vendor No. exists.
3. If more than one Purchase Order open form with possible Purchase Orders to transfer the Sales Line to.

Any ideas for an alternate solution?

/zeon

Answers

  • deV.chdeV.ch Member Posts: 543
    You have 2 options:
    1. Do not create any transaction before you show the Form, Change your logic if possible
    2. Do your modification on temporary records, this way you can show the form modal. Create the real transactions after that.
  • zeonzeon Member Posts: 130
    Thanks for your input! 8)

    I think I'll go with the second option - to use temp records!

    /zeon
  • rhpntrhpnt Member Posts: 688
    zeon wrote:
    Any ideas for an alternate solution?
    Sure! Use the standard "Special order" functionality or better yet the requisition worksheet!
Sign In or Register to comment.