Opened 6 years ago

Last modified 6 years ago

#3593 closed Feature Request

IsFunc() - check if function exist by string — at Version 1

Reported by: mLipok Owned by:
Milestone: Component: AutoIt
Version: Severity: None
Keywords: Cc:

Description (last modified by mLipok)

IsFunc() should have feautre to check if string is reperesenting FunctionName in function list.

This feature is very much needed to validate user function parameters.

In this following example only third test should fail but second should display message.

_Test(_msg, 1)
_Test("_msg", 2)
_Test("Fake_msg", 3)

Func _Test($sFunction, $iTest)
	If IsFunc($sFunction) Then $sFunction($iTest)
EndFunc   ;==>_Test1

Func _Msg($iTest)
	MsgBox(0, "Test", $iTest)
EndFunc   ;==>_Msg

Change History (1)

comment:1 Changed 6 years ago by mLipok

  • Description modified (diff)
Note: See TracTickets for help on using tickets.