Control the "Page Mode" of a page

jensthomsenjensthomsen Member Posts: 173
edited 2014-05-30 in NAV Three Tier
Hi

I want to be able to create a new item - via a function - from a page where 'SourceTable' isn't table 27. I'm aware that the following code can do the trick:

Item."No." := '';
Item.INSERT(TRUE);
Page.Runmodal(page::"30",Item);

This code will always create a new item when the user pushes the 'Create new item' button (unless I write a confirm to "control" it, but that isn't nice either). I would like do have a function that resembles the "New" functionality on a list page (like page 31): The card page will open up in "Page mode" = CREATE and the item will not be created when the user escapes the page? Is this possible? Maybe by use of 'WinFormsControlAddInBase'....

Comments

Sign In or Register to comment.