Page 1 of 1

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

Posted: Thu Feb 16, 2017 4:32 pm
by Taku Izumi
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?

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

Posted: Mon Feb 20, 2017 9:37 am
by Stewart Marshall
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