Please don't mind. I've solded this problem with set and mapcar lambda. Thanks for reading ^^


Registered forum members do not see this ad.
I've written some function, put it in one lisp file.
My idea is in end of file, i'll write a function to check key registered , if unregistered, i assign all function above to a function alert to user that they must register program
Ex
1;
But it didn't workCode:(defun a ()...) (defun b ()...) .... (defun arlet-unreg ()...) ;EOF (if unregistered (foreach func (list a b) (setq func arlet-unreg) ) )
2; I must change as bellow to do my idea :
and it make my code longerCode:(if unregistered (progn (setq a arlet-unreg) (setq b arlet-unreg) ..... ) ) )
Please tell me what wrong with foreach in code 1st.
Thanks all very much


Please don't mind. I've solded this problem with set and mapcar lambda. Thanks for reading ^^


Registered forum members do not see this ad.
Ok, it's my way to solved the problem:
Now if unregistered, all doA, doB.. command goto alert function ^^Code:(defun a ...) ;do sth (defun b...) ; do sth (defun C:doA nil (a)) ;call macro (defun C:doB nil (b)) ;call macro .... ;Defun to alert Unregistered (defun ST:Sys-Alert-Unregistered nil (alert "B\U+1EA1n ch\U+01B0a \U+0111\U+0103ng k\U+00FD n\U+00EAn kh\U+00F4ng s\U+1EED d\U+1EE5ng \U+0111\U+01B0\U+1EE3c l\U+1EC7nh n\U+00E0y :)")) (setq #ST:Key "080227BB0300WCC6MPUA1") ;this key is HDD serial with some encrypt to check with (defun ST:Sys-CheckKey (key) ...) ; this function to check key ;list all function use : (setq #funclst '(a b ....)) (if (not (ST:Sys-CheckKey #ST:key)) ;unregisterd (progn (mapcar '(lambda (x)(set x ST:Sys-Alert-Unregistered)) #funclst) ) )
BTW, haiz, please tell me which sysvar make alert function only display in commandline (dialog is disappear). I forgot it and can't to find out now![]()
Bookmarks