lisp函数的到期日期
你好我需要帮助一个lisp函数的过期日期。我几乎不会写下面的lisp,我想添加一个到期日期。它将是vlx文件,在2017年1月1日无效。它需要一个警告,如“此函数已过期!”
Lisp程序是;
(defun c:MKAtman ()
(command "CMDECHO" "0")(terpri)
(prompt "Setting layers")(princ)
(command "layer" "unlock" "*" "thaw" "*" "on" "*" "")
(command "layer" "m" "0" "c" "7" "" "l" "Continuous" "" "")
(if(not(tblsearch "LAYER" "000_Ahşap"))
(command "layer" "m" "000_Ahşap" "c" "white" "" "l" "Continuous" "" "d" "Ahşap İmalatlar" "000_Ahşap" "")
(command "layer" "m" "000_Ahşap" "c" "white" "" "l" "Continuous" "" "d" "Ahşap İmalatlar" "000_Ahşap" "y" ""))
(if(not(tblsearch "LAYER" "000_Andezit"))
(command "layer" "m" "000_Andezit" "c" "250" "" "l" "Continuous" "" "d" "Andezit Döşeme Kaplamaları" "000_Andezit" "")
(command "layer" "m" "000_Andezit" "c" "250" "" "l" "Continuous" "" "d" "Andezit Döşeme Kaplamaları" "000_Andezit" "y" ""))
(if(not(tblsearch "LAYER" "000_Antet"))
(command "layer" "m" "000_Antet" "c" "251" "" "l" "Continuous" "" "d" "ABB Antet" "000_Antet" "")
(command "layer" "m" "000_Antet" "c" "251" "" "l" "Continuous" "" "d" " ABB Antet" "000_Antet" "y" ""))
(if(not(tblsearch "LAYER" "000_Beton Parke"))
(command "layer" "m" "000_Beton Parke" "c" "250" "" "l" "Continuous" "" "d" "N/A" "000_Beton Parke" "")
(command "layer" "m" "000_Beton Parke" "c" "250" "" "l" "Continuous" "" "d" "N/A" "000_Beton Parke" "y" ""))
(if(not(tblsearch "LAYER" "000_Bitki"))
(command "layer" "m" "000_Bitki" "c" "white" "" "l" "Continuous" "" "d" "N/A" "000_Bitki" "")
(command "layer" "m" "000_Bitki" "c" "white" "" "l" "Continuous" "" "d" "N/A" "000_Bitki" "y" ""))
(if(not(tblsearch "LAYER" "000_Bitki İz"))
(command "layer" "m" "000_Bitki İz" "c" "white" "" "l" "Continuous" "" "d" "N/A" "000_Bitki İz" "")
(command "layer" "m" "000_Bitki İz" "c" "white" "" "l" "Continuous" "" "d" "N/A" "000_Bitki İz" "y" ""))
(if(not(tblsearch "LAYER" "000_Bordür"))
(command "layer" "m" "000_Bordür" "c" "180" "" "l" "Continuous" "" "d" "N/A" "000_Bordür" "")
(command "layer" "m" "000_Bordür" "c" "180" "" "l" "Continuous" "" "d" "N/A" "000_Bordür" "y" ""))
(if(not(tblsearch "LAYER" "000_Çim Tarama"))
(command "layer" "m" "000_Çim Tarama" "c" "64" "" "l" "Continuous" "" "d" "169,185,167" "000_Çim Tarama" "")
(command "layer" "m" "000_Çim Tarama" "c" "64" "" "l" "Continuous" "" "d" "169,185,167" "000_Çim Tarama" "y" ""))
(if(not(tblsearch "LAYER" "000_Duvar"))
(command "layer" "m" "000_Duvar" "c" "19" "" "l" "Continuous" "" "d" "N/A" "000_Duvar" "")
(command "layer" "m" "000_Duvar" "c" "19" "" "l" "Continuous" "" "d" "N/A" "000_Duvar" "y" ""))
(if(not(tblsearch "LAYER" "000_EPDM"))
(command "layer" "m" "000_EPDM" "c" "white" "" "l" "Continuous" "" "d" "142,95,87" "000_EPDM" "")
(command "layer" "m" "000_EPDM" "c" "white" "" "l" "Continuous" "" "d" "142,95,87" "000_EPDM" "y" ""))
(if(not(tblsearch "LAYER" "000_Eski Eğri"))
(command "layer" "m" "000_Eski Eğri" "c" "253" "" "l" "Dashed2" "" "d" "N/A" "000_Eski Eğri" "")
(command "layer" "m" "000_Eski Eğri" "c" "253" "" "l" "Dashed2" "" "d" "N/A" "000_Eski Eğri" "y" ""))
(if(not(tblsearch "LAYER" "000_Havuz"))
(command "layer" "m" "000_Havuz" "c" "132" "" "l" "Continuous" "" "d" "N/A" "000_Havuz" "")
(command "layer" "m" "000_Havuz" "c" "132" "" "l" "Continuous" "" "d" "N/A" "000_Havuz" "y" ""))
(if(not(tblsearch "LAYER" "000_Kauçuk"))
(command "layer" "m" "000_Kauçuk" "c" "white" "" "l" "Continuous" "" "d" "142,95,87" "000_Kauçuk" "")
(command "layer" "m" "000_Kauçuk" "c" "white" "" "l" "Continuous" "" "d" "142,95,87" "000_Kauçuk" "y" ""))
(if(not(tblsearch "LAYER" "000_Kent Mobilyası"))
(command "layer" "m" "000_Kent Mobilyası" "c" "white" "" "l" "Continuous" "" "d" "N/A" "000_Kent Mobilyası" "")
(command "layer" "m" "000_Kent Mobilyası" "c" "white" "" "l" "Continuous" "" "d" "N/A" "000_Kent Mobilyası" "y" ""))
(if(not(tblsearch "LAYER" "000_Koşu Yolu"))
(command "layer" "m" "000_Koşu Yolu" "c" "34" "" "l" "Continuous" "" "d" "N/A" "000_Koşu Yolu" "")
(command "layer" "m" "000_Koşu Yolu" "c" "34" "" "l" "Continuous" "" "d" "N/A" "000_Koşu Yolu" "y" ""))
(if(not(tblsearch "LAYER" "000_KüpTaş"))
(command "layer" "m" "000_KüpTaş" "c" "250" "" "l" "Continuous" "" "d" "N/A" "000_KüpTaş" "")
(command "layer" "m" "000_KüpTaş" "c" "250" "" "l" "Continuous" "" "d" "N/A" "000_KüpTaş" "y" ""))
(if(not(tblsearch "LAYER" "000_Mevsimlik Tarama"))
(command "layer" "m" "000_Mevsimlik Tarama" "c" "210" "" "l" "Continuous" "" "d" "N/A" "000_Mevsimlik Tarama" "")
(command "layer" "m" "000_Mevsimlik Tarama" "c" "210" "" "l" "Continuous" "" "d" "N/A" "000_Mevsimlik Tarama" "y" ""))
(if(not(tblsearch "LAYER" "000_Ölçü"))
(command "layer" "m" "000_Ölçü" "c" "217" "" "l" "Continuous" "" "d" "N/A" "000_Ölçü" "")
(command "layer" "m" "000_Ölçü" "c" "217" "" "l" "Continuous" "" "d" "N/A" "000_Ölçü" "y" ""))
(if(not(tblsearch "LAYER" "000_Sert Tarama"))
(command "layer" "m" "000_Sert Tarama" "c" "white" "" "l" "Continuous" "" "d" "N/A" "000_Sert Tarama" "")
(command "layer" "m" "000_Sert Tarama" "c" "white" "" "l" "Continuous" "" "d" "N/A" "000_Sert Tarama" "y" ""))
(if(not(tblsearch "LAYER" "000_Sınır"))
(command "layer" "m" "000_Sınır" "c" "20" "" "l" "Continuous" "" "d" "N/A" "000_Sınır" "")
(command "layer" "m" "000_Sınır" "c" "20" "" "l" "Continuous" "" "d" "N/A" "000_Sınır" "y" ""))
(if(not(tblsearch "LAYER" "000_Slopeticks"))
(command "layer" "m" "000_Slopeticks" "c" "252" "" "l" "Continuous" "" "d" "Şev Çizgisi" "000_Slopeticks" "")
(command "layer" "m" "000_Slopeticks" "c" "252" "" "l" "Continuous" "" "d" "Şev Çizgisi" "000_Slopeticks" "y" ""))
(if(not(tblsearch "LAYER" "000_Tasarım"))
(command "layer" "m" "000_Tasarım" "c" "50" "" "l" "Continuous" "" "d" "N/A" "000_Tasarım" "")
(command "layer" "m" "000_Tasarım" "c" "50" "" "l" "Continuous" "" "d" "N/A" "000_Tasarım" "y" ""))
(if(not(tblsearch "LAYER" "000_Terrazo Granit AG"))
(command "layer" "m" "000_Terrazo Granit AG" "c" "250" "" "l" "Continuous" "" "d" "N/A" "000_Terrazo Granit AG" "")
(command "layer" "m" "000_Terrazo Granit AG" "c" "250" "" "l" "Continuous" "" "d" "N/A" "000_Terrazo Granit AG" "y" ""))
(if(not(tblsearch "LAYER" "000_Terrazo Bazalt AG"))
(command "layer" "m" "000_Terrazo Bazalt AG" "c" "250" "" "l" "Continuous" "" "d" "N/A" "000_Terrazo Bazalt AG" "")
(command "layer" "m" "000_Terrazo Bazalt AG" "c" "250" "" "l" "Continuous" "" "d" "N/A" "000_Terrazo Bazalt AG" "y" ""))
(if(not(tblsearch "LAYER" "000_Terrazo Washbeton Yİ"))
(command "layer" "m" "000_Terrazo Washbeton Yİ" "c" "250" "" "l" "Continuous" "" "d" "N/A" "000_Terrazo Washbeton Yİ" "")
(command "layer" "m" "000_Terrazo Washbeton Yİ" "c" "250" "" "l" "Continuous" "" "d" "N/A" "000_Terrazo Washbeton Yİ" "y" ""))
(if(not(tblsearch "LAYER" "000_Yazı"))
(command "layer" "m" "000_Yazı" "c" "220" "" "l" "Continuous" "" "d" "N/A" "000_Yazı" "")
(command "layer" "m" "000_Yazı" "c" "220" "" "l" "Continuous" "" "d" "N/A" "000_Yazı" "y" ""))
(if(not(tblsearch "LAYER" "000_Yeni Eğri"))
(command "layer" "m" "000_Yeni Eğri" "c" "20" "" "l" "Continuous" "" "d" "N/A" "000_Yeni Eğri" "")
(command "layer" "m" "000_Yeni Eğri" "c" "20" "" "l" "Continuous" "" "d" "N/A" "000_Yeni Eğri" "y" ""))
(command "layer" "s" "0" "")
(command "CMDECHO" "1")
(prompt "Tüm Layerlar Başarıyla Oluşturulmuştur.")
(princ)
);end defun
检查下面的链接
http://www.cadtutor.net/forum/showthread.php?54624-限时Lisp 别忘了提及“联系人…”部分;-) 建议您下次列出图层详细信息(name1 col1 ltype1 name2 col2 ltype2……。然后只需获得列表的长度,使用它重复查看3个变量,然后进行表格搜索。整个lisp只有几行长,而不是对每个图层重复layer命令。 还有其他方法,比如你有50次,现在是49次,48次。。。通过lisp将数字写入注册表。重新设置日期有点容易捏造,如果你知道它的用途的话,可以继续使用。另一种方法是读取网站上的URL,通过计数器或正确的日期检查其使用情况。您可以检查Autocad序列号是否停止复制到许多机器。如果软件有用,人们会尝试将其分发给他人。
如果您有很多例程,那么很容易在包含检查例程的lisp中添加一个标题,这样就可以正常运行。复制标题+Lisp1 LISP1vlx 谢谢大家。
我试过了,但还是不行。我不是lisp方面的专家,所以我不能听从Bigal的建议。所以,我还是不知道怎么做。 我不得不不好意思地再次求助。我还是修不好。
"http://www.cadtutor.net/forum/showth...ime-bound-Lisp“那个话题对我来说不管用。 这是另一段代码,稍微添加了一点,放在lisp的开头。(退出)将停止运行lisp。我们有多个LISP,所以我们在发布时使用DOS命令复制安全性添加了安全代码。lsp+lisp1。lsp c:\\securty\\lisp1。然后lsp将编译成FAS。如果你有很多事情要做的话,你也可以编写制作fas的脚本。
(if (< (rtos (getvar "cdate") 2 0) "20170101") ; 1st Jan 2017
(princ)
(progn
(Alert "Contact Merve for Renewal\n\nPlease call us on 12334567 to discuss continued use")
(exit)
)
)
成功了!非常感谢。这对我来说非常重要。
干得好BIGAL。
我说话不流利,所以如果这是错误的,或者太明显而无法提及,请原谅我。
我猜想,如果用户在记事本中打开这个lisp,删除这个最新添加的内容并保存它,就可以继续使用lisp而不会造成进一步的中断?
毫无疑问,梅尔夫知道这一点,如果我是正确的话,他也应该知道。
页:
[1]
2