Error Generic Error in Expression: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
No edit summary
 
m (Some wiki formatting)
 
(6 intermediate revisions by 2 users not shown)
Line 1: Line 1:
Blah
This error occurs when the type of data an operator is expecting does not match.
 
 
 
'''Compatibility:'''
 
Version '''1.96'''
 
 
 
'''Example:'''
<sqf>
_myString = "The meaning of life is " + 42; // error
_myString = "The meaning of life is " + str 42; // OK
_myString = "The meaning of life is " + format ["%1", 42]; // OK - {{Name|ofp|short}}
</sqf>
 


[[Category:Common Scripting Errors]]
[[Category:Common Scripting Errors]]

Latest revision as of 14:35, 27 March 2024

This error occurs when the type of data an operator is expecting does not match.


Compatibility:

Version 1.96


Example:

_myString = "The meaning of life is " + 42; // error _myString = "The meaning of life is " + str 42; // OK _myString = "The meaning of life is " + format ["%1", 42]; // OK - OFP