找回密码
 加入
搜索
楼主: lynfr8

[原创] i-Autoit软件安装管理器测试版

[复制链接]
 楼主| 发表于 2011-3-15 22:12:44 | 显示全部楼层
回复 15# 872777825



谢谢反馈,所以非常奇怪的在win7可以完美执行的程序到了xp就失效了
真是奇怪
初步估计是这句代码在xp下出错无法获取值,所以无法获取安装文件的路径,导致没有正确执行安装
$Groupname = _GUICtrlListView_GetGroupInfoByIndex($ListView, _GUICtrlListView_GetItemGroupID($ListView, $i) - 1)
这里提出一个疑问:
_GUICtrlListView_GetGroupInfoByIndex是否在xp还是精简版的xp下失效?

我测试了UDF的例子,发现里面的msgbox根本就没有执行脚本就结束了
代码如下:
#AutoIt3Wrapper_Au3Check_Parameters=-d -w 1 -w 2 -w 3 -w 4 -w 5 -w 6
#include <GuiConstantsEx.au3>
#include <GuiListView.au3>
#include <GuiImageList.au3>

Opt('MustDeclareVars', 1)

$Debug_LV = False ; Check ClassName being passed to ListView functions, set to True and use a handle to another control to see it work

_Main()

Func _Main()
        Local $aInfo, $hImage, $hListView
        
        GUICreate("ListView Get Group Info", 400, 300)

        $hListView = GUICtrlCreateListView("", 2, 2, 394, 268)
        GUISetState()

        ; Load images
        $hImage = _GUIImageList_Create()
        _GUIImageList_Add($hImage, _GUICtrlListView_CreateSolidBitMap(GUICtrlGetHandle($hListView), 0xFF0000, 16, 16))
        _GUIImageList_Add($hImage, _GUICtrlListView_CreateSolidBitMap(GUICtrlGetHandle($hListView), 0x00FF00, 16, 16))
        _GUIImageList_Add($hImage, _GUICtrlListView_CreateSolidBitMap(GUICtrlGetHandle($hListView), 0x0000FF, 16, 16))
        _GUICtrlListView_SetImageList($hListView, $hImage, 1)

        ; Add columns
        _GUICtrlListView_AddColumn($hListView, "Column 1", 100)
        _GUICtrlListView_AddColumn($hListView, "Column 2", 100)
        _GUICtrlListView_AddColumn($hListView, "Column 3", 100)

        ; Add items
        _GUICtrlListView_AddItem($hListView, "Row 1: Col 1", 0)
        _GUICtrlListView_AddSubItem($hListView, 0, "Row 1: Col 2", 1)
        _GUICtrlListView_AddSubItem($hListView, 0, "Row 1: Col 3", 2)
        _GUICtrlListView_AddItem($hListView, "Row 2: Col 1", 1)
        _GUICtrlListView_AddSubItem($hListView, 1, "Row 2: Col 2", 1)
        _GUICtrlListView_AddItem($hListView, "Row 3: Col 1", 2)

        ; Build groups
        _GUICtrlListView_EnableGroupView($hListView)
        _GUICtrlListView_InsertGroup($hListView, -1, 1, "Group 1", 1)
        _GUICtrlListView_InsertGroup($hListView, -1, 2, "Group 2")
        _GUICtrlListView_SetItemGroupID($hListView, 0, 1)
        _GUICtrlListView_SetItemGroupID($hListView, 1, 2)
        _GUICtrlListView_SetItemGroupID($hListView, 2, 2)

        ; Change group information
        For $x = 0 To _GUICtrlListView_GetGroupCount($hListView) - 1
                $aInfo = _GUICtrlListView_GetGroupInfoByIndex($hListView, $x)
                MsgBox(4160, "Information", "Index " & $x + 1 & "Text: " & $aInfo[0])
        Next
        _GUICtrlListView_SetGroupInfo($hListView, 1, "New Group 1")

        ; Loop until user exits
        Do
        Until GUIGetMsg() = $GUI_EVENT_CLOSE
For $x = 0 To _GUICtrlListView_GetGroupCount($hListView) - 1
                $aInfo = _GUICtrlListView_GetGroupInfoByIndex($hListView, $x)
                MsgBox(4160, "Information", "Index " & $x + 1 & "Text: " & $aInfo[0])
        Next
        GUIDelete()
EndFunc   ;==>_Main
希望大家也测试一下,并请反馈具体测试系统环境
发表于 2011-3-17 01:18:11 | 显示全部楼层
kankan
发表于 2011-3-17 09:39:11 | 显示全部楼层
看起来很舒服呼呼哈~
发表于 2011-3-18 02:51:48 | 显示全部楼层
美观大于实用
发表于 2011-3-18 10:42:17 | 显示全部楼层
谢谢分享,用下了
发表于 2011-3-20 01:03:13 | 显示全部楼层
真漂亮,不知道成熟后,会不会开放一下源码呢?
发表于 2011-3-28 22:15:01 | 显示全部楼层
配套使用很不错啊啊啊
发表于 2011-3-28 22:15:30 | 显示全部楼层
元老推荐的软件肯定好用
发表于 2011-3-28 22:16:28 | 显示全部楼层
撒花支持偶也
发表于 2011-3-31 13:50:11 | 显示全部楼层
上个版本报毒  这个没问题把
发表于 2011-3-31 16:33:40 | 显示全部楼层
不错 不错!!
发表于 2011-4-1 23:07:43 | 显示全部楼层
回复 1# lynfr8


    金钱不足了,只下得一半
发表于 2011-4-2 03:58:33 | 显示全部楼层
好贵哦 我的天啊呵呵
发表于 2011-4-2 03:58:54 | 显示全部楼层
今天的钱不好转啊
发表于 2011-4-2 21:13:31 | 显示全部楼层
貌似不错啊~
您需要登录后才可以回帖 登录 | 加入

本版积分规则

QQ|手机版|小黑屋|AUTOIT CN ( 鲁ICP备19019924号-1 )谷歌 百度

GMT+8, 2024-3-28 17:15 , Processed in 0.073273 second(s), 15 queries .

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表