String-fields
You can set the format with
setvar=ls_text=<ls_mystring,format>
or
setvar=ls_text=<%var("ls_mystring","format1","format 2",... )>
<string,date> |
converts string to date-format |
|
<string,num> |
deletes thousand-dot-separator and replaces comma with dot. (for German decimal-format) |
|
<string,space x> |
enlarges String to x chars. <abc,space 4> returns "abc ". <abc,space 2> returns "ab" |
|
<string,lefttrimrow xRow xLeft> |
Extracts row xRow and trims xLeft chars from the left. The remaining blank spaces from the right are deleted |
|
<string,lefttrim xLeft> |
Trims xLeft chars from the left and deletes blank spaces |
|
<string,left xLeft> |
returns xLeft chars from the left |
|
<string,trim> |
Delete all space, tabs, cr_lf and char(160) from left and right site from the string and all "<P></P>" from right side |
|
<string,lasttoken x> |
|
|
<string,token xToken xTokensign> |
|
|
<string,right xRight> |
returns xRight chars from the right of the string |
|
<string,len> |
returns the len from string Example <hello world,len> return 11 |
|
<string,lower> |
convert string to lower string |
|
<string,upper> |
convert string to upper string |
|
<string,mid pos length> |
returns a part-sequence of the string Example setvar=ls_value=Hello World messagebox=<ls_value,mid 4 1> Returns: o |
|
<string,pos x> |
gets the position of the first appearance of the character x. x can be included in "..." x can be done with char(ascii) Example setvar=ls_test=hello<tab>world messagebox=<ls_test,pos char(9)> returns 6 |
|
<string,default x> |
If String=NULL or String=leer then use the default "x" Example: <column,default hello>: if there is no content of column then returns "hallo" |
|
<string,isnull x> |
like default but only if content is "NULL" |
|
<string,padr xtoken=xlength> |
fills the String up to "xlength" chars from the left with the token "xToken". Example: setvar=ls_value=1 messagebox=<ls_value,padr 0=5> Return: 00001 |
|
<string,monthname> |
if string is date then returns the month |
|
<string,datename> |
if string is date then returns the week-day |
|
<string,rtf> |
converts CR_LF to RTF-CR_LF |
|
<string,time> |
formats string to time in current user-language, e. g. 15 gets 15:00 or 3:00 pm |
|
<string,time2sec> |
Convert time to seconds |
|
<string,string2price> |
|
|
<string,string2currency> |
Formatted a price field in a currency field e.g. USD 1,234.56 will be USD |
|
<string,tosql> |
|
|
<string,dbstring> |
|
|
<string,ascii> |
Display the ascii-values from string Exampe <ABC,ascii> return (65) (66) (67) |
|
<string,trimhtml> |
Trims trailing and leading empty html tags.
Example:
<p></p>Hello World to Hello World Hello<br>World<span></span> to Hello<br>World
|
<string,html2text> |
Replace all <, > and ' to { } and ´ |
|
<string,html2textarea> |
Replace all <textarea and </textarea to {textarea and {/textarea |
|
<string,html2num x> |
This method is to check a numeric value in a string and return it. The default behavior is to use the decimal system on base 10. It is possible to use a system based on 16 or 2 by using the x parameter. It is highly recommended to use this method to prevent sql injections.
Examples setvar=ls_text=0815 setvar=ls_text=<ls_text,html2num> // 815
setvar=ls_text=Hello World setvar=ls_text=<ls_text,html2num> // 0
setvar=ls_text=A100 setvar=ls_text=<ls_text,html2num 16> // A100
setvar=ls_text=XYZ500 setvar=ls_text=<ls_text,html2num 16> // 0
setvar=ls_text=1100101 setvar=ls_text=<ls_text,html2num 2> // 1100101
|
|
<string,html2html> |
|
|
<string,dbhtml> |
replace ` to ′ |
|
<string,url2string> |
Convert a url-String to normal String Replace all %-Placeholder |
|
<string,tourl> |
|
|
<string,htmlcharset2string> |
|
<string,tohex> |
convert a integer (0-255) in hexadecimal with 2 digits 0 = 00, 5=05, 255=FF... |
<string,tolonghex> |
convert to long hex with 3 Numbers Example: 255=0000FF, 256 = 000100 and so on (for coloring in HTML) |
<string,hex2int> |
convert a Hex-Value to Integer, Example FF = 255 setvar=ls_test=Erst%&FCsten meldung=<ls_test,url2string> 10 |