Hello
When working with a programming language, it is essential that you understand what data types are available and what their limits/ranges are.
You're trying to assign a value to an INTEGER which is higher than what an INTEGER can store. So you need to use a data type which has a larger numerical range than an integer, a DOUBLE INTEGER.
The following snippet loops through numbers 1 to 20 and displays their factorial values stored as an Integer and Double Integer.
Global intAnsNum as integer
Global dintAnsNum as double integer
do
cls
`input numVar
for numVar = 1 to 20
dintAnsNum = 1
intAnsNum = 1
for multNum = 2 to numVar
dintAnsNum = dintAnsNum * multNum
intAnsNum = intAnsNum * multNum
next multNum
txtY = Text Height("X") * NumVar
txtX = 0
Set Cursor txtX, txtY
print "dint = "; dintAnsNum;
txtX = Screen Width() / 2
Set Cursor txtX, txtY
print "int = "; intAnsNum
next numVar
loop
Also, have a nose in the DBPro help topic "Main Menu\Principles\Datatypes and variables" as all available DBPro data types and their ranges are explained there.