You must place the command in parenthesis.
Example:
Code: Select all
#include "dcdialog.CH"
#xtranslate MESSAGE <x> [<p: PROPERCASE>] => XMessage(<x>,<.p.>)
FUNCTION Main()
LOCAL GetList[0]
@ 0,0 DCPUSHBUTTON CAPTION 'Send Message' SIZE 20,1.2 ;
ACTION {||(MESSAGE "this is a message to roger" PROPERCASE)}
DCREAD GUI FIT TITLE 'Code block test'
RETURN nil
* -----------
PROC appsys ; RETURN
* -----------
FUNCTION XMessage(cMsg,lProper)
IF lProper
cMsg := DC_CapFirst(cMsg)
ENDIF
MsgBox(cMsg)
RETURN nil
Code: Select all
bBlock := {|a,b,c,d,e|(WTF a,b,c,d,e)}