File tree Expand file tree Collapse file tree 1 file changed +13
-3
lines changed
dotnet/src/dotnetframework/GxClasses/Domain Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -787,10 +787,20 @@ public virtual void FromJSONObject(dynamic obj)
787787 public GxSimpleCollection < string > ToStringCollection ( int digits , int decimals )
788788 {
789789 GxSimpleCollection < string > result = new GxSimpleCollection < string > ( ) ;
790- foreach ( T item in this )
790+ if ( typeof ( T ) == typeof ( string ) )
791+ {
792+ foreach ( T item in this )
793+ {
794+ result . Add ( item as string ) ;
795+ }
796+ }
797+ else
791798 {
792- decimal value = ( decimal ) Convert . ChangeType ( item , typeof ( decimal ) ) ;
793- result . Add ( StringUtil . LTrim ( StringUtil . Str ( value , digits , decimals ) ) ) ;
799+ foreach ( T item in this )
800+ {
801+ decimal value = ( decimal ) Convert . ChangeType ( item , typeof ( decimal ) ) ;
802+ result . Add ( StringUtil . LTrim ( StringUtil . Str ( value , digits , decimals ) ) ) ;
803+ }
794804 }
795805 return result ;
796806 }
You can’t perform that action at this time.
0 commit comments