1 Reply Latest reply on Jun 3, 2014 12:31 PM by philmodjunk

    Auto Enter a portal line



      Auto Enter a portal line


           i want to make a button (touch style) to press and have a quantity appear as 1, and a price of a service call appear in the cost box of my portal. 

           i always bill people the same price for service call. so having a button to auto enter in quantity 1 and the price would help a lot. 



        • 1. Re: Auto Enter a portal line

               Assuming this relationship:

               LayoutTable::__pkTableID = PortalTable::_fkTableID

               on a layout based on LayouTable with a portal referring to PortalTable....

               Freeze Window
               Set Variable [$TableID ; value: LayoutTable::__pkTableID ]
               Go to Layout ["PortalTable" (PortalTable) ]
               New Record/Request
               Set Field [PortalTable::_fkTableID ; $TableID ]
               Set FIeld [PortalTable::Qty ; 1 ]
               Set Field [PortalTable::Amt ; Your amount goes here ]
               Go to Layout [ original layout ]

               Note: This script can trip a number of script triggers on exiting and entering layouts. Sometimes additional step must be taken to keep such trigger performed scripts from interfering.