How to change the edit style of PRIM_LIST.Number from a sipn edit to an input field

This Q&A forum allows users to post and respond to "How Do I Do ....." questions. Please do not use to report (suspected) errors - you must use your regional help desk for this. The information contained in this forum has not been validated by LANSA and, as such, LANSA cannot guarantee the accuracy of the information.
Post Reply
Taku Izumi
Posts: 15
Joined: Thu Dec 15, 2016 2:03 pm

How to change the edit style of PRIM_LIST.Number from a sipn edit to an input field

Post by Taku Izumi » Thu Feb 16, 2017 4:32 pm

Hi,

When the numeric type field is used as read-only(false) in the VLWEB PRIM_LIST, the edit style is a spin edit. Is there a way to change this edit style to a normal input field?

User avatar
Stewart Marshall
Posts: 417
Joined: Thu Nov 05, 2015 5:25 pm

Re: How to change the edit style of PRIM_LIST.Number from a sipn edit to an input field

Post by Stewart Marshall » Mon Feb 20, 2017 9:37 am

When a number field is dragged on to a list from the repository, it automatically creates a number column (#Prim_list.Number) and sets the source to the field name. This results in spin edit at runtime.

However, if you change the column type to a string (#Prim_list.String), the edit appearance will be that of a regular edit sourced by a numeric field.

Code: Select all

Begin_Com Role(*EXTENDS #PRIM_WEB) Height(505) Width(721)
Define_Com Class(#PRIM_LIST) Name(#List) DisplayPosition(1) Left(15) Parent(#COM_OWNER) TabPosition(1) Top(15) Height(386) Width(690)
Define_Com Class(#PRIM_LIST.String) Name(#Column1) ColumnWidth(207) DisplayPosition(1) Parent(#List) Source(#xDemoCaption) ColumnReadOnly(False)
Define_Com Class(#PRIM_LIST.Number) Name(#Column2) ColumnWidth(136) DisplayPosition(2) Increment(1) Parent(#List) Source(#xDemoNumber) Wrap(False) ColumnReadOnly(False)
Define_Com Class(#PRIM_LIST.String) Name(#Column3) ColumnWidth(99) DisplayPosition(3) Parent(#List) Source(#xDemoNumber_2) ColumnReadOnly(False)

Evtroutine Handling(#Com_owner.CreateInstance)
Inz_List Named(#List) Num_Entrys(10)
Endroutine

End_Com
Regards
Stewart Marshall

Independent IT Consultant
www.marshallfloyd.com.au

Post Reply