摘要: import win.ui; import inet.adapter; import inet.conn; /*DSG{{*/ winForm = ..win.form(text="网卡管理工具";right=305;bottom=521;max=false) winForm.add( button={cls="button";text="修改";left=79;top=447;right=21... 阅读全文
posted @ 2019-03-06 22:12 遥月 阅读(601) 评论(0) 推荐(0)
摘要: import win.ui; import process.popen; //使用process.popen(cmd)不会闪黑窗 /*DSG{{*/ mainForm = win.form(text="定时关机程序";right=582;bottom=206;mode="popup") mainForm.add( button={cls="button";text="执行";left=42;to... 阅读全文
posted @ 2019-03-06 22:11 遥月 阅读(340) 评论(0) 推荐(0)
摘要: 输出参数(out Parameters ) 在aardio中,如果在数据类型以后添加&符号,表示这个参数的值允许被外部函数修改并且会返回修改后的值。 如果一个函数包含输出参数,那么传址参数会按原来的先后顺序附加在返回值后面返回。 aardio中函数是纯函数,函数数据只有唯一的入口(参数),也只有唯一的出口(参数),所以被修改的输出参数必须显示的从返回值 输出。 apifunc = dllf... 阅读全文
posted @ 2019-03-06 22:09 遥月 阅读(366) 评论(0) 推荐(0)
摘要: //我想从进程id获取窗口标题 import winex; for hwnd,title,theadId,processId in winex.each( ) { if( processId == 你要找的进程ID) { io.print( "标题", win.getText(hwnd) ) io.print( "标题", title ) }... 阅读全文
posted @ 2019-03-06 22:07 遥月 阅读(234) 评论(0) 推荐(0)
摘要: //打开数据库链接 sqlConnection=sqlite("\db.db") //没有就创建 if(not sqlConnection.existsTable("file")){ sqlConnection.exec("CREATE TABLE file( id INTEGER PRIMARY KEY AU... 阅读全文
posted @ 2019-03-06 22:06 遥月 阅读(725) 评论(0) 推荐(0)
摘要: /***文件的读取,一行行读取,使用io.lines可以避免一次性读取太大的文件***/ for line in io.lines("test.txt") { //io.lines()返回的迭代器函数每次读取文件中的一行 io.print(line); } 与下面的功能相同: file = io.open("d:\test.txt") //一次性读写文件内容... 阅读全文
posted @ 2019-03-06 21:56 遥月 阅读(433) 评论(0) 推荐(0)
摘要: aauto 调用 DOS 命令 方法一、最简单的方法,直接执行DOS命令 execute("ipconfig /all") //不推荐,成功返回0,否则1. 方法二、用管道 //返回执行结果文本,推荐这个,没有黑窗口 import process; f = process.popen("ipconfig /all" ) str=f.read(-1);//全部读取 方法三: ... 阅读全文
posted @ 2019-03-06 21:53 遥月 阅读(1444) 评论(0) 推荐(0)
摘要: 嵌入控件的控件,最好用wndproc回调函数处理消息。否则应在父控件窗口中转发命令消息 示例1 import win.ui; /*DSG{{*/ var winform = ..win.form( bottom=399;parent=...;text="AAuto Form";right=599 ) winform.add( listview={ bgcolor=16777215;bot... 阅读全文
posted @ 2019-03-06 21:45 遥月 阅读(371) 评论(0) 推荐(0)
摘要: listbox有seltext获取选中文本信息,所以可以不用回调和通知 //listbox去重复项 for adptInfo in inet.adapter.each() { if(!winForm.combobox.findEx(adptInfo.description)){ //主要是findex() winForm.combobox.ad... 阅读全文
posted @ 2019-03-06 21:44 遥月 阅读(266) 评论(0) 推荐(0)
摘要: import win.ui; import sqlite; import console; /*DSG{{*/ var winform = ..win.form(text="aardio Form";right=596;bottom=433;parent=...) winform.add( btn_adddb={cls="button";text="添加中数据到数据库";left=416;top... 阅读全文
posted @ 2019-03-06 21:39 遥月 阅读(690) 评论(0) 推荐(0)
摘要: //窗体中添加 listbox 控件 msel = true/false 是否允许多选 允许多选 winform.add( listbox={ bgcolor=16777215;bottom=296;right=222;left=71; items={"列表内容" };msel=1;z=1;top=95;edge=1;cls="listbox" } ) 不允许多选 winform.ad... 阅读全文
posted @ 2019-03-06 21:25 遥月 阅读(646) 评论(0) 推荐(0)
摘要: http://bbs.aardio.com/forum.php?mod=viewthread&tid=11257&from=portal :: 全局常量操作符这个操符符用于将一个变量名转换为 global名字空间下的全局常量名 - 并保护该常量在其后加载的代码中一旦赋为非空值后即不可修改,例如::: 阅读全文
posted @ 2019-03-06 21:22 遥月 阅读(321) 评论(0) 推荐(0)