listview指定欄位無法更改底色顏色[已解決]
本帖最后由 yohoboy 于 2018-4-3 01:54 编辑各位先进您好:
小弟写程式碰上一个难题,使用_GUICtrlListView 相关函数后,顺利将资料由资料库写入listview栏位内,但是有一点不太明白为何设定_GUICtrlListView_AddArray 这函数后如果要判断日期栏位内超过一定天数后设定该栏位项目底色改为红色提示,有研究过其他以解决相关问题,或是参考范例,可以成功变色,但是相同概念移植至本程式内就不行了,都无法变色,是否哪边没有设定到造成此结果?以下附上原始档,关键在193~203 行程式码要将超过指定日期的项目变色,谢谢回覆主题。
#include <array.au3>
#include <ButtonConstants.au3>
#include <Color.au3>
#include <ColorConstantS.au3>
#include <ComboConstants.au3>
#include <Date.au3>
#include <DateTimeConstants.au3>
#include <EditConstants.au3>
#include <Excel.au3>
#include <FileConstants.au3>
#include <FontConstants.au3>
#include <GUIConstantsEx.au3>
#include <GUIEdit.au3>
#include <GuiImageList.au3>
#include <GUIListBox.au3>
#Include <GuiListView.au3>
#include <GuiStatusBar.au3>
#include <ListViewConstants.au3>
#include <MsgBoxConstants.au3>
#include <SQLite.au3>
#include <SQLite.dll.au3>
#include <StaticConstants.au3>
#include <WinAPI.au3>
#include <WinAPIEx.au3>
#include <WindowsConstants.au3>
#NoTrayIcon
Opt("TrayIconHide", 1) ;0 = 顯示托盤圖標, 1 = 隱藏托盤圖標
Opt('MustDeclareVars', 1) ;1 = 變量不需預先聲明, 1 = 變量必需預先聲明
Opt("GUICloseOnESC", 0) ;1 = 點擊 Esc 鍵關閉, 0 = 點擊 Esc 鍵不關閉
Global $Title, $SQLite_Data_Path
Global $GUI_Input1, $GUI_Input2, $GUI_Input3
Global $GUI_COMBO1, $GUI_COMBO2, $GUI_COMBO3, $GUI_COMBO4, $GUI_COMBO5, $GUI_COMBO6
Global $GUI_Button1, $GUI_Button2, $GUI_Button3, $GUI_Button4, $GUI_Button5, $GUI_Button6, $GUI_Button7, $GUI_Button8, $GUI_Button9, _
$GUI_Button10, $GUI_Button11, $GUI_Button12, $GUI_Button13
Global $a, $aRow,$aRow2, $hQuery, $hImage
Global $GUI_Form, $GUI_ListBox , $GUI_ListBox2, $File_Time_Temp, $File_Time
Global $iExWindowStyle = BitOR($WS_EX_DLGMODALFRAME, $WS_EX_CLIENTEDGE) ;設定視窗LISTVIEW變數
Global $iExListViewStyle = BitOR($LVS_EX_FULLROWSELECT, $LVS_EX_GRIDLINES, $LVS_EX_DOUBLEBUFFER);項目選中顯示高亮度題示,顯示項目橫列線條,緩衝控鍵顯示
Global $iHeight = 20, $g_idListView , $hEdit;視窗點擊變
Global $Shift = "早班|中班|晚班|正常班"
Global $Service = "AM|CM|PM|其他"
Global $UnitRange = "All|O6|O7|O8|O9|O10|O11|O12|O13|O14|OT1|MD|BSS3|列車|其他"
Global $SystemName = "ART(公共藝術)|CCTV(閉路電視)|CLOCK(子母鐘)|CV(結構腐蝕)|DLTS(直線電話)|" & _
"DPA(機廠廣播)|EPABX(電話及錄音)|GE(寬頻網路)|IAS(門禁)|LSPS(投射螢幕)|LU(邊坡滑動)|" & _
"OSSS(地震警報)|PA(廣播)|PIDS(旅客資訊)|PSS(通訊電源)|RADIO(無線電)|SCADA(中央監控)|" & _
"SDH(數位同步)|WN(風速儀)|R22A防侵入|其他"
Global$Status ="待交接|已到場|待追蹤|待料|已結案"
Global $Ranking = "緊急|重要|一般|其他"
$SQLite_Data_Path = "interfix.sqlite" ;sql資料庫路徑及名稱
$File_Time_Temp = FileGetTime($SQLite_Data_Path, $FT_MODIFIED, 0); 取得檔案最新更新日期
$File_Time = $File_Time_Temp & "-" & $File_Time_Temp & "-" & $File_Time_Temp ;將更新日期陣列重新組合
$Title = "值班交接查詢(For-T2445)....." & "File_Date=" & $File_Time ;標題名稱
_SQLite_Startup ("sqlite3.dll", TRUE, 0) ;加載SQLite3.dll,工作目錄下需有SQLite3.dll 如果沒有就從autoit 網站下載並放入同一目錄下
If @error Then ;如果沒有SQLite3.dll檔案則顯示錯誤訊息
MsgBox($MB_SYSTEMMODAL, "SQLite 錯誤", "SQLite3.dll 不能載入,請檢查SQLite3.dll,SQLite3.def檔案是否存在同一目錄下!")
Exit ;離開程式不執行
EndIf
If Not FileExists($SQLite_Data_Path) Then ;如果無資料庫檔案則執行以下命令
Local $QUERY = MsgBox(1,"錯誤","資料庫無法打開,請檢查""interfix.sqlite""檔是否存在或是檔案已損毀,如要建立新檔請按確定,否則取消。")
If $QUERY = 1 Then
SQLCreate() ;建立新資料庫,參考SQLCreate() 功能,在下面
Exit
Else
Exit ;按下取消紐時,程式不執行
EndIf
EndIf
Func SQLCreate() ;建立資料庫
_SQLite_Open ($SQLite_Data_Path) ;建立資料庫,名稱為$SQLite_Data_Path 變數名稱
_SQLite_Exec(-1, "Create Table IF NOT Exists interfix ( Date Date , Shift TEXT, Service Text, LocaleName Text, " & _
"SystemName Text, Ranking Text, Matter Text, Transact Text, Status Text);") ;建立資料庫內容
;^^以上執行SQL語法建立 BM_Number 資料表,並建立相關欄位等資料內容
_SQLite_Close (-1) ;關閉資料庫
MsgBox(0,"資料庫","資料庫已建立,請重新執行程式")
Exit
EndFunc
$GUI_Form = GUICreate($Title, 750, 480, -1, -1) ;建立主視窗GUI樣式
GUISetBkColor(0xECE9C8); 設定視窗背景顏色
$GUI_ListBox = GUICtrlCreateListView(" 日 期 |班 別|勤務別|廠/站| 系 統 |" & _
"急迫性| 追 蹤 事 項 | 處 理 進 度 | 狀 態 ", 2, 2, 746, 230, BitOR($LVS_REPORT, $WS_BORDER), BitOR($LVS_EX_CHECKBOXES, $LVS_EX_FULLROWSELECT))
_GUICtrlListView_SetExtendedListViewStyle($GUI_ListBox, BitOR($LVS_EX_GRIDLINES, $LVS_EX_FULLROWSELECT, $LVS_EX_CHECKBOXES))
;上面設定ListView內容
GUICtrlCreateLabel("日期:", 10, 250, 36, 15)
$GUI_Input1 = GUICtrlCreateInput("",45,245,80,20,0x0800) ;日期
GUICtrlCreateLabel("班別:", 150, 250, 36, 15)
$GUI_COMBO1 = GUICtrlCreateCombo("", 188, 245, 60, 20,$CBS_DROPDOWNLIST);班別
GUICtrlSetData($GUI_COMBO1, $Shift, "")
GUICtrlCreateLabel("勤務:", 255, 250, 36, 15)
$GUI_COMBO2 = GUICtrlCreateCombo("", 292, 245, 50, 20,$CBS_DROPDOWNLIST);勤務
GUICtrlSetData($GUI_COMBO2, $Service, "")
GUICtrlCreateLabel("廠站:", 350, 250, 36, 15)
$GUI_COMBO3 = GUICtrlCreateCombo("", 387, 245, 50, 20,$CBS_DROPDOWNLIST) ;廠站
GUICtrlSetData($GUI_COMBO3, $UnitRange, "")
GUICtrlCreateLabel("系統:", 445, 250, 36, 15)
$GUI_COMBO4 = GUICtrlCreateCombo("", 482, 245, 130, 20,$CBS_DROPDOWNLIST) ;系統
GUICtrlSetData($GUI_COMBO4, $SystemName, "")
GUICtrlCreateLabel("急迫性:", 640, 250, 50, 15)
$GUI_COMBO5 = GUICtrlCreateCombo("", 690, 245, 50, 20,$CBS_DROPDOWNLIST) ;急迫性
GUICtrlSetData($GUI_COMBO5, $Ranking, "")
GUICtrlCreateLabel("追蹤事項:", 15, 280, 40, 30)
$GUI_Input2 = GUICtrlCreateInput("",60,280,190,190,0x00201044) ;追蹤事項
GUICtrlCreateLabel("處理進度:", 255, 280, 40, 30)
$GUI_Input3 = GUICtrlCreateInput("",300,280,250,190,0x00201044) ;處理進度
GUICtrlCreateLabel("狀態:", 560, 280, 36, 30)
$GUI_COMBO6 = GUICtrlCreateCombo("", 598, 275, 60, 20,$CBS_DROPDOWNLIST) ;狀態
GUICtrlSetData($GUI_COMBO6, $Status, "")
GUICtrlCreateLabel("未結案查詢",580, 310, 60, 17)
GUICtrlCreateLabel("緊急:", 580, 330, 40, 17)
Local $Exigency = GUICtrlCreateLabel("00", 615, 330, 20, 17)
GUICtrlCreateLabel("重要:", 580, 345, 40, 17)
Local $Momentous = GUICtrlCreateLabel("00", 615, 345, 20, 17)
GUICtrlCreateLabel("一般:", 580, 360, 40, 17)
Local $Commonly =GUICtrlCreateLabel("00", 615, 360, 20, 17)
GUICtrlCreateLabel("其他:", 580, 375, 40, 17)
Local $other =GUICtrlCreateLabel("00", 615, 375, 20, 17)
$GUI_Button1 = GUICtrlCreateButton("讀取", 690, 350, 48, 22, 0)
$GUI_Button2 = GUICtrlCreateButton("新增", 690, 375, 48, 22, 0)
$GUI_Button3 = GUICtrlCreateButton("搜尋", 690, 275, 48, 22, 0)
$GUI_Button4 = GUICtrlCreateButton("刪除", 690, 400, 48, 22, 0)
$GUI_Button5 = GUICtrlCreateButton("確定", 560, 435, 48, 22, 0)
$GUI_Button6 = GUICtrlCreateButton("關閉", 690, 435, 48, 22, 0)
$GUI_Button7 = GUICtrlCreateButton("?", 125, 245, 15, 15, 0) ;日期蒐尋
$GUI_Button8 = GUICtrlCreateButton("?", 560, 328, 15, 15, 0) ;未結案緊急工單查詢
$GUI_Button9 = GUICtrlCreateButton("?", 560, 343, 15, 15, 0) ;未結案重要工單查詢
$GUI_Button10 = GUICtrlCreateButton("?", 560, 358, 15, 15, 0) ;未結案一般工單查詢
$GUI_Button11 = GUICtrlCreateButton("?", 560, 308, 15, 15, 0) ;全部未結案工單查詢
$GUI_Button12 = GUICtrlCreateButton("清除欄位", 677, 300, 60, 22, 0) ;清空
$GUI_Button13 = GUICtrlCreateButton("?", 560, 373, 15, 15, 0) ;未結案其他工單
_GUICtrlListView_SetExtendedListViewStyle($GUI_ListBox,$iExListViewStyle) ;將視窗設定風格顯示
$GUI_ListBox = GUICtrlGetHandle($GUI_ListBox) ;回傳控件項目句柄,針對項目雙擊後選擇其它功能
Local $hFont = _WinAPI_CreateFont($iHeight - 5, 0, 0, 0, 400, False, False, False, $DEFAULT_CHARSET, $OUT_DEFAULT_PRECIS, $CLIP_DEFAULT_PRECIS, $DEFAULT_QUALITY, 0, '新細明體') ;建立點擊項目後之顯示方式
GUIRegisterMsg($WM_NOTIFY, 'WM_NOTIFY') ;註冊win消息ID-訊息通知,轉WM_NOTIFY函數處理,用於項目雙擊控制
GUIRegisterMsg($WM_COMMAND, 'WM_COMMAND') ;註冊win消息ID-訊息命令,轉WM_COMMAND函數處理,用於項目雙擊後,後續處理
_SQLite_Open ($SQLite_Data_Path) ;讀取資料庫,名稱為$SQLite_Data_Path 變數名稱
Update_totall() ;更新未結案筆數
GUISetState(@SW_SHOW,$GUI_Form) ;GUI 顯示
Interfix_data() ;顯示待交接資料
While 1
Switch GUIGetMsg()
Case $GUI_Button1 ;讀取
Read_Data()
Case $GUI_Button2 ;新增
New_Data()
Case $GUI_Button3 ;搜尋
Ambit_query()
Case$GUI_Button4 ;刪除
;SQLiteDelete()
Case $GUI_Button5 ;確定修改
Enter_data()
Case $GUI_EVENT_CLOSE, $GUI_Button6 ;視窗關閉
_SQLite_Close(-1)
_SQLite_Shutdown () ;本程式關閉時shutdown sqlite.dll
ExitLoop
Case $GUI_Button7 ;日期搜尋
DATE()
Case $GUI_Button8 ;未結案緊急工單查詢
Exigency_query()
Case $GUI_Button9 ;未結案重要工單查詢
Momentous_query()
Case $GUI_Button10 ;未結案一般工單查詢
Commonly_query()
Case $GUI_Button11 ;全部未結案工單查詢
All_query()
Case $GUI_Button12
clear_columu()
Case $GUI_Button13
other_columu()
EndSwitch
WEnd
Func Interfix_data() ; 顯示交接資料
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Status) FROM interfix WHERE Status = '待交接' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"交接事項","無交接資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Status = '待交接' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
EndFunc
Func DATE() ;日期蒐尋及填入INPUT1欄位
Local $DATETEMP = GUICreate("日期搜尋", 200, 50, -1, -1)
Local $idDate = GUICtrlCreateDate("", 10, 10, 185, 20, $DTS_SHORTDATEFORMAT)
; 選擇特定的默認格式
Local $sStyle = "yyyy-MM-dd"
GUICtrlSendMsg($idDate, $DTM_SETFORMATW, 0, $sStyle)
GUISetState(@SW_SHOW)
; 循環到用戶退出.
While 1
SWITCH GUIGetMsg()
Case $GUI_EVENT_CLOSE
GUICtrlSetData($GUI_Input1, GUICtrlRead($idDate))
ExitLoop
EndSwitch
WEnd
GUIDelete($DATETEMP)
EndFunc ;==>Example
Func New_Data() ;新增跳出之視窗
LocaL $Form2 = GUICreate("新增交接資料", 497, 280, -1, -1)
GUICtrlCreateLabel("新增日期:" , 20, 12, 60, 17)
Local $NOWDATETIME=@YEAR & "-" & @MON & "-" &@MDAY
Local $Input1 = GUICtrlCreateInput($NOWDATETIME, 80, 10, 97, 21)
GUICtrlCreateLabel("班別:", 186, 12, 30, 17)
Local $Combo1 = GUICtrlCreateCombo("", 218, 8, 60, 25, $CBS_DROPDOWNLIST )
GUICtrlSetData($Combo1, $Shift, "早班")
GUICtrlCreateLabel("勤務別:", 290, 12, 42, 17)
Local $Combo2 = GUICtrlCreateCombo("", 332, 8, 60, 25, $CBS_DROPDOWNLIST )
GUICtrlSetData($Combo2, $Service, "CM")
GUICtrlCreateLabel("車站/機廠:", 18, 42, 60, 17)
Local $Combo3 = GUICtrlCreateCombo("", 78, 40, 60, 25, $CBS_DROPDOWNLIST )
GUICtrlSetData($Combo3, $UnitRange, "")
GUICtrlCreateLabel("系統:", 158, 42, 31, 17)
Local $Combo4 = GUICtrlCreateCombo("", 190, 40, 140, 25, $CBS_DROPDOWNLIST)
GUICtrlSetData($Combo4, $SystemName, "")
GUICtrlCreateLabel("急迫性:", 340, 42, 42, 17)
Local $Combo5 = GUICtrlCreateCombo("", 385, 40, 50, 25, $CBS_DROPDOWNLIST)
GUICtrlSetData($Combo5, $Ranking, "一般")
GUICtrlCreateLabel("追蹤事項:", 20, 72, 60, 17)
Local $Input2 = GUICtrlCreateInput("", 78, 72, 150, 150,0x00201044)
GUICtrlCreateLabel("處理進度:", 240, 72, 60, 17)
Local $Input3 = GUICtrlCreateEdit("", 300, 72, 180, 150, 0x00201044)
GUICtrlCreateLabel("狀態:", 45, 240, 30, 17)
Local $Combo6 = GUICtrlCreateCombo("", 78, 237, 60, 25, $CBS_DROPDOWNLIST)
GUICtrlSetData($Combo6, $Status, "待交接")
Local $Button1 = GUICtrlCreateButton("確認", 336, 235, 65, 25)
Local $Button2 = GUICtrlCreateButton("取消", 408, 235, 65, 25)
GUISetState(@SW_SHOW,$Form2)
Local $NOWDATETIME2, $Temp
While 1
Local $nMsg = GUIGetMsg()
Switch $nMsg
Case $Combo3 ;設定廠站名稱選擇到列車或是其他時,自動代入系統別
IfGUICtrlRead($Combo3) = "列車" Then
GUICtrlDelete($Combo4)
Sleep(150)
$Combo4 = GUICtrlCreateCombo("", 190, 40, 140, 25, $CBS_DROPDOWNLIST )
GUICtrlSetData($Combo4, $SystemName, "RADIO(無線電)")
ElseIf GUICtrlRead($Combo3) = "其他" Then
GUICtrlDelete($Combo4)
Sleep(150)
$Combo4 = GUICtrlCreateCombo("", 190, 40, 140, 25, $CBS_DROPDOWNLIST )
GUICtrlSetData($Combo4, $SystemName, "其他")
EndIf
Case $GUI_EVENT_CLOSE ,$Button2 ; 關閉視窗或是取消鈕則退出
ExitLoop
Case $Button1 ;輸入確認
GUICtrlSetState($Button1,$GUI_DISABLE )
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Date) FROM interfix WHERE Date Like '" & $NOWDATETIME & "%" & "';", $aRow) ;執行SQL語法查詢當日產生筆數
$Temp = int($aRow)
If $Temp = 0 Then
$NOWDATETIME2 = $NOWDATETIME & "-1"
_SQLite_Exec(-1, "Insert into interfix (Date) values ('" & $NOWDATETIME2 & "');") ;輸入交接筆數
IF GUICtrlRead($Combo1) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Shift = '" & GUICtrlRead($Combo1) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入班別
EndIf
IF GUICtrlRead($Combo2) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Service = '" & GUICtrlRead($Combo2) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入勤務別
EndIf
IF GUICtrlRead($Combo3) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET LocaleName = '" & GUICtrlRead($Combo3) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入廠站
EndIf
IF GUICtrlRead($Combo4) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET SystemName = '" & GUICtrlRead($Combo4) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入系統別
EndIf
IF GUICtrlRead($Combo5) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Ranking = '" & GUICtrlRead($Combo5) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入急迫性
EndIf
IF GUICtrlRead($Input2) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Matter = '" & GUICtrlRead($Input2) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入追蹤事項
EndIf
IF GUICtrlRead($Input3) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Transact = '" & GUICtrlRead($Input3) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入處理進度
EndIf
IF GUICtrlRead($Combo6) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Status = '" & GUICtrlRead($Combo6) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入急迫性
EndIf
Else
$Temp = $Temp + 1
$NOWDATETIME2 = $NOWDATETIME & "-" & $Temp
_SQLite_Exec(-1, "Insert into interfix (Date) values ('" & $NOWDATETIME2 & "');") ;輸入交接筆數
IF GUICtrlRead($Combo1) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Shift = '" & GUICtrlRead($Combo1) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入班別
EndIf
IF GUICtrlRead($Combo2) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Service = '" & GUICtrlRead($Combo2) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入勤務別
EndIf
IF GUICtrlRead($Combo3) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET LocaleName = '" & GUICtrlRead($Combo3) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入廠站
EndIf
IF GUICtrlRead($Combo4) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET SystemName = '" & GUICtrlRead($Combo4) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入系統別
EndIf
IF GUICtrlRead($Combo5) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Ranking = '" & GUICtrlRead($Combo5) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入急迫性
EndIf
IF GUICtrlRead($Input2) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Matter = '" & GUICtrlRead($Input2) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入追蹤事項
EndIf
IF GUICtrlRead($Input3) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Transact = '" & GUICtrlRead($Input3) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入處理進度
EndIf
IF GUICtrlRead($Combo6) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Status = '" & GUICtrlRead($Combo6) & "' WHERE Date = '" & $NOWDATETIME2 & "';") ;輸入急迫性
EndIf
EndIf
GUICtrlSetState($Button1,$GUI_ENABLE )
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Date) FROM interfix WHERE Date LIKE '" & $NOWDATETIME & "%" & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = Int($aRow) ;以整數值存入變數
If $aRow2 = 0 Then ;如果查無資料則顯示查無資料
_SQLite_QueryFinalize ( $hQuery )
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Date LIKE '" & $NOWDATETIME & "%" & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
GUICtrlSetData($Input2, "", "" ) ;清空事項
GUICtrlSetData($Input3, "", "" ) ;清空處理情況
EndSwitch
WEnd
Update_totall()
GUIDelete($Form2)
EndFunc
Func Ambit_query() ;欄位搜尋
IF GUICtrlRead ($GUI_Input1)<> "" Then ;日期搜尋
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Date) FROM interfix WHERE Date LIKE '" & GUICtrlRead ($GUI_Input1) & "%" & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Date LIKE '" & GUICtrlRead($GUI_Input1) & "%" & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
ElseIf GUICtrlRead ($GUI_Input2)<> "" Then ;追蹤事項搜尋
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Matter) FROM interfix WHERE Matter LIKE '" & "%" & GUICtrlRead ($GUI_Input2) & "%" & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Matter LIKE '" & "%" & GUICtrlRead($GUI_Input2) & "%" & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
ElseIf GUICtrlRead ($GUI_Input3)<> "" Then ;追蹤事項搜尋
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Transact) FROM interfix WHERE Transact LIKE '" & "%" & GUICtrlRead ($GUI_Input3) & "%" & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Transact LIKE '" & "%" & GUICtrlRead($GUI_Input3) & "%" & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
ElseIf GUICtrlRead ($GUI_COMBO1)<> "" Then;班別搜尋
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Shift) FROM interfix WHERE Shift = '" & GUICtrlRead ($GUI_COMBO1) & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Shift = '" & GUICtrlRead($GUI_COMBO1) & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
ElseIf GUICtrlRead ($GUI_COMBO2)<> "" AND GUICtrlRead ($GUI_COMBO3)<> "" Then ;勤務、廠站搜尋
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Service) FROM interfix WHERE Service = '" & GUICtrlRead ($GUI_COMBO2) & "' AND LocaleName = '" & GUICtrlRead($GUI_COMBO3) & "';", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Service = '" & GUICtrlRead($GUI_COMBO2) & "' AND LocaleName = '" & GUICtrlRead($GUI_COMBO3) & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
ElseIf GUICtrlRead ($GUI_COMBO2)<> "" AND GUICtrlRead ($GUI_COMBO6)<> "" Then ;勤務、狀態搜尋
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Service) FROM interfix WHERE Service = '" & GUICtrlRead ($GUI_COMBO2) & "' AND Status = '" & GUICtrlRead($GUI_COMBO6) & "';", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Service = '" & GUICtrlRead($GUI_COMBO2) & "' AND Status = '" & GUICtrlRead($GUI_COMBO6) & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
ElseIf GUICtrlRead ($GUI_COMBO2)<> "" Then;勤務搜尋
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Service) FROM interfix WHERE Service = '" & GUICtrlRead ($GUI_COMBO2) & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Service = '" & GUICtrlRead($GUI_COMBO2) & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
ElseIf GUICtrlRead ($GUI_COMBO3)<> "" And GUICtrlRead ($GUI_COMBO4)<> "" Then ;廠/站,系統搜尋
_SQLite_QuerySingleRow(-1, "SELECT COUNT(LocaleName) FROM interfix WHERE LocaleName = '" & GUICtrlRead ($GUI_COMBO3) & "' And SystemName = '" & GUICtrlRead ($GUI_COMBO4) & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE LocaleName = '" & GUICtrlRead($GUI_COMBO3) & "' And SystemName = '" & GUICtrlRead ($GUI_COMBO4) & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
ElseIf GUICtrlRead ($GUI_COMBO3)<> "" And GUICtrlRead ($GUI_COMBO6)<> "" Then ;廠/站,狀態搜尋
_SQLite_QuerySingleRow(-1, "SELECT COUNT(LocaleName) FROM interfix WHERE LocaleName = '" & GUICtrlRead ($GUI_COMBO3) & "' And Status = '" & GUICtrlRead ($GUI_COMBO6) & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE LocaleName = '" & GUICtrlRead($GUI_COMBO3) & "' And Status = '" & GUICtrlRead ($GUI_COMBO6) & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
ElseIf GUICtrlRead ($GUI_COMBO3)<> "" Then;廠/站搜尋
_SQLite_QuerySingleRow(-1, "SELECT COUNT(LocaleName) FROM interfix WHERE LocaleName = '" & GUICtrlRead ($GUI_COMBO3) & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE LocaleName = '" & GUICtrlRead($GUI_COMBO3) & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
ElseIf GUICtrlRead ($GUI_COMBO4)<> "" And GUICtrlRead ($GUI_COMBO6)<> "" Then;系統,狀態搜尋
_SQLite_QuerySingleRow(-1, "SELECT COUNT(SystemName) FROM interfix WHERE SystemName = '" & GUICtrlRead ($GUI_COMBO4) & "' And Status = '" & GUICtrlRead ($GUI_COMBO6) & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE SystemName = '" & GUICtrlRead($GUI_COMBO4) & "' And Status = '" & GUICtrlRead ($GUI_COMBO6) & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
ElseIf GUICtrlRead ($GUI_COMBO4)<> "" Then;系統搜尋
_SQLite_QuerySingleRow(-1, "SELECT COUNT(SystemName) FROM interfix WHERE SystemName = '" & GUICtrlRead ($GUI_COMBO4) & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE SystemName = '" & GUICtrlRead($GUI_COMBO4) & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
ElseIf GUICtrlRead ($GUI_COMBO5)<> "" And GUICtrlRead ($GUI_COMBO6)<> "" Then ;急迫性,狀態搜尋
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Ranking) FROM interfix WHERE Ranking = '" & GUICtrlRead ($GUI_COMBO5) & "' And Status = '" & GUICtrlRead ($GUI_COMBO6) & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Ranking = '" & GUICtrlRead($GUI_COMBO5) & "' And Status = '" & GUICtrlRead ($GUI_COMBO6) & "'ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
ElseIf GUICtrlRead ($GUI_COMBO5)<> "" Then ;急迫性搜尋
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Ranking) FROM interfix WHERE Ranking = '" & GUICtrlRead ($GUI_COMBO5) & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Ranking = '" & GUICtrlRead($GUI_COMBO5) & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
ElseIf GUICtrlRead ($GUI_COMBO6)<> "" Then;狀態搜尋
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Status) FROM interfix WHERE Status = '" & GUICtrlRead ($GUI_COMBO6) & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = int($aRow)
If$aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Status = '" & GUICtrlRead($GUI_COMBO6) & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
EndIf
clear_columu()
EndFunc
Func sql_data_array() ;取出之資料存入陣列並顯示至ViewList
Local $ArrayData[$aRow2] ;設定二維陣列
Local $Date_interval, $iDateCalc, $aItem
Local $c = 0;初始二維陣列值
$hImage = _GUIImageList_Create()
While _SQLite_FetchData ($hQuery, $aRow) = $SQLITE_OK
$ArrayData[$c]=$aRow
$ArrayData[$c]=$aRow
$ArrayData[$c]=$aRow
$ArrayData[$c]=$aRow
$ArrayData[$c]=$aRow
$ArrayData[$c]=$aRow
$ArrayData[$c]=$aRow
$ArrayData[$c]=$aRow
$ArrayData[$c]=$aRow
$c = $c +1
WEnd
_GUICtrlListView_AddArray($GUI_ListBox, $ArrayData)
_SQLite_QueryFinalize($hQuery)
EndFunc
Func Read_Data() ;讀取全部資料
GUICtrlSetState($GUI_Button1,$GUI_DISABLE )
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Date) FROM interfix WHERE Date LIKE '" & "%" & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = Int($aRow) ;以整數值存入變數
If $aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Date LIKE '" & "%" & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
GUICtrlSetState($GUI_Button1,$GUI_ENABLE )
EndFunc
Func SQLiteDelete() ;刪除一筆資料
Local $Temp
Local $Date_DL =InputBox("刪除追蹤事項","請輸入日期編號","","",150,150) ;輸入BM工單號碼
IF @error <> 1 Then ;InputBox 如點選OK鈕
_SQLite_QuerySingleRow(-1, "SELECT * FROM interfix WHERE Date = '" & $Date_DL & "' COLLATE NOCASE ;", $aRow) ;搜尋該筆工單
$Temp = $aRow
If $Temp = "" Then ;沒有該筆資料
MsgBox(262208, "刪除結果...", "無此筆資料,請重新輸入!")
Else ;有該筆資料就顯示內容
_GUICtrlListView_DeleteAllItems ($GUI_ListBox)
_GUICtrlListView_AddItem($GUI_ListBox, $aRow)
_GUICtrlListView_AddSubItem($GUI_ListBox, _GUICtrlListView_FindInText($GUI_ListBox, $aRow), $aRow, 1)
_GUICtrlListView_AddSubItem($GUI_ListBox, _GUICtrlListView_FindInText($GUI_ListBox, $aRow), $aRow, 2)
_GUICtrlListView_AddSubItem($GUI_ListBox, _GUICtrlListView_FindInText($GUI_ListBox, $aRow), $aRow, 3)
_GUICtrlListView_AddSubItem($GUI_ListBox, _GUICtrlListView_FindInText($GUI_ListBox, $aRow), $aRow, 4)
_GUICtrlListView_AddSubItem($GUI_ListBox, _GUICtrlListView_FindInText($GUI_ListBox, $aRow), $aRow, 5)
_GUICtrlListView_AddSubItem($GUI_ListBox, _GUICtrlListView_FindInText($GUI_ListBox, $aRow), $aRow, 6)
_GUICtrlListView_AddSubItem($GUI_ListBox, _GUICtrlListView_FindInText($GUI_ListBox, $aRow), $aRow, 7)
_GUICtrlListView_AddSubItem($GUI_ListBox, _GUICtrlListView_FindInText($GUI_ListBox, $aRow), $aRow, 8)
GUICtrlSetData($GUI_Input1, $aRow, "")
GUICtrlSetData($GUI_COMBO1, $aRow, "")
GUICtrlSetData($GUI_COMBO2, $aRow, "")
GUICtrlSetData($GUI_COMBO3, $aRow, "")
GUICtrlSetData($GUI_COMBO4, $aRow, "")
GUICtrlSetData($GUI_COMBO5, $aRow, "")
GUICtrlSetData($GUI_Input2, $aRow, "")
GUICtrlSetData($GUI_Input3, $aRow, "")
GUICtrlSetData($GUI_COMBO6, $aRow, "")
_SQLite_QueryFinalize($hQuery)
$a = MsgBox(1,"刪除確認","是否刪除此筆追蹤事項:" & $Date_DL ) ;詢問是否刪除該筆工單
If $a = 1 Then
_SQLite_Exec(-1, "DELETE FROM interfix WHERE Date = '" & $Date_DL & "';") ;刪除該筆工單資料
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除ListView資料
GUICtrlSetData($GUI_Input1, "", "")
GUICtrlSetData($GUI_COMBO1, $Shift, "")
GUICtrlSetData($GUI_COMBO2, $Service, "")
GUICtrlSetData($GUI_COMBO3, $UnitRange, "")
GUICtrlSetData($GUI_COMBO4, $SystemName, "")
GUICtrlSetData($GUI_COMBO5, $Ranking, "")
GUICtrlSetData($GUI_Input2, "", "")
GUICtrlSetData($GUI_Input3, "", "")
GUICtrlSetData($GUI_COMBO6, $Status, "")
_SQLite_QueryFinalize($hQuery)
EndIf
EndIf
EndIf
Update_totall()
EndFunc
Func Enter_data() ;確定修改
GUICtrlSetState($GUI_Button5,$GUI_DISABLE )
IF GUICtrlRead($GUI_Combo1) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Shift = '" & GUICtrlRead($GUI_Combo1) & "' WHERE Date = '" & GUICtrlRead($GUI_Input1) & "';") ;輸入班別
EndIf
IF GUICtrlRead($GUI_Combo2) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Service = '" & GUICtrlRead($GUI_Combo2) & "' WHERE Date = '" & GUICtrlRead($GUI_Input1) & "';") ;輸入勤務別
EndIf
IF GUICtrlRead($GUI_Combo3) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET LocaleName = '" & GUICtrlRead($GUI_Combo3) & "' WHERE Date = '" & GUICtrlRead($GUI_Input1) & "';") ;輸入廠站
EndIf
IF GUICtrlRead($GUI_Combo4) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET SystemName = '" & GUICtrlRead($GUI_Combo4) & "' WHERE Date = '" & GUICtrlRead($GUI_Input1) & "';") ;輸入系統別
EndIf
IF GUICtrlRead($GUI_Combo5) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Ranking = '" & GUICtrlRead($GUI_Combo5) & "' WHERE Date = '" & GUICtrlRead($GUI_Input1) & "';") ;輸入急迫性
EndIf
IF GUICtrlRead($GUI_Input2) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Matter = '" & GUICtrlRead($GUI_Input2) & "' WHERE Date = '" & GUICtrlRead($GUI_Input1) & "';") ;輸入追蹤事項
EndIf
IF GUICtrlRead($GUI_Input3) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Transact = '" & GUICtrlRead($GUI_Input3) & "' WHERE Date = '" & GUICtrlRead($GUI_Input1) & "';") ;輸入處理進度
EndIf
IF GUICtrlRead($GUI_Combo6) <> "" Then
_SQLite_Exec(-1, "UPDATE interfix SET Status = '" & GUICtrlRead($GUI_Combo6) & "' WHERE Date = '" & GUICtrlRead($GUI_Input1) & "';") ;輸入急迫性
EndIf
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Date) FROM interfix WHERE Date = '" & GUICtrlRead($GUI_Input1) & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = Int($aRow) ;以整數值存入變數
If $aRow2 = 0 Then ;如果查無資料則顯示查無資料
_SQLite_QueryFinalize ( $hQuery )
MsgBox(0,"更新結果","未更新資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Date = '" & GUICtrlRead($GUI_Input1) & "' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
GUICtrlSetState($GUI_Button5,$GUI_ENABLE )
Update_totall()
EndFunc
Func Update_totall() ;更新各工單數量
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Ranking) FROM interfix WHERE Ranking = '緊急' And Status <> '已結案';", $aRow) ;執行SQL語法查詢筆數
GUICtrlSetData($Exigency,$aRow)
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Ranking) FROM interfix WHERE Ranking = '重要' And Status <> '已結案';", $aRow) ;執行SQL語法查詢筆數
GUICtrlSetData($Momentous,$aRow)
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Ranking) FROM interfix WHERE Ranking = '一般' And Status <> '已結案';", $aRow) ;執行SQL語法查詢筆數
GUICtrlSetData($Commonly,$aRow)
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Ranking) FROM interfix WHERE Ranking = '其他' And Status <> '已結案';", $aRow) ;執行SQL語法查詢筆數
GUICtrlSetData($other,$aRow)
EndFunc
Func Exigency_query() ;未結案緊急工單查詢
GUICtrlSetState($GUI_Button8,$GUI_DISABLE )
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Ranking) FROM interfix WHERE Ranking = '緊急' And Status <> '已結案';", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = Int($aRow) ;以整數值存入變數
If $aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Ranking = '緊急' And Status <> '已結案' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
GUICtrlSetState($GUI_Button8,$GUI_ENABLE )
Update_totall()
EndFunc
Func Momentous_query() ;未結案重要工單查詢
GUICtrlSetState($GUI_Button9,$GUI_DISABLE )
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Ranking) FROM interfix WHERE Ranking = '重要' And Status <> '已結案';", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = Int($aRow) ;以整數值存入變數
If $aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Ranking = '重要' And Status <> '已結案' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
GUICtrlSetState($GUI_Button9,$GUI_ENABLE )
Update_totall()
EndFunc
Func Commonly_query() ;未結案一般工單查詢
GUICtrlSetState($GUI_Button10,$GUI_DISABLE )
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Ranking) FROM interfix WHERE Ranking = '一般' And Status <> '已結案';", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = Int($aRow) ;以整數值存入變數
If $aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Ranking = '一般' And Status <> '已結案' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
GUICtrlSetState($GUI_Button10,$GUI_ENABLE )
Update_totall()
EndFunc
Func All_query() ;全部未結案工單查詢
GUICtrlSetState($GUI_Button11,$GUI_DISABLE )
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Status) FROM interfix WHERE Status <> '已結案';", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = Int($aRow) ;以整數值存入變數
If $aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Status <> '已結案' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
GUICtrlSetState($GUI_Button11,$GUI_ENABLE )
Update_totall()
EndFunc
Func other_columu() ;未結案其他工單查訊
GUICtrlSetState($GUI_Button10,$GUI_DISABLE )
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Ranking) FROM interfix WHERE Ranking = '其他' And Status <> '已結案';", $aRow) ;查詢資料筆數,並存入$hQuery 變數
$aRow2 = Int($aRow) ;以整數值存入變數
If $aRow2 = 0 Then ;如果查無資料則顯示查無資料
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_GUICtrlListView_DeleteAllItems ($GUI_ListBox) ;清除舊資料顯示
_SQLite_Query(-1, "SELECT * FROM interfix WHERE Ranking = '其他' And Status <> '已結案' ORDER BY Date DESC ;", $hQuery) ;查詢資料,並存入$hQuery 變數
sql_data_array()
EndIf
GUICtrlSetState($GUI_Button10,$GUI_ENABLE )
Update_totall()
EndFunc
Func WM_NOTIFY($hWnd, $iMsg, $iwParam, $ilParam) ;滑鼠點擊事件
Local $tNMHDR, $hWndFrom, $iCode,$hWndListView
$hWndListView = $GUI_ListBox
If Not IsHWnd($GUI_ListBox) Then $hWndListView = GUICtrlGetHandle($g_idListView)
$tNMHDR = DllStructCreate($tagNMHDR, $ilParam)
$hWndFrom = DllStructGetData($tNMHDR, 'hWndFrom')
$iCode = DllStructGetData($tNMHDR, 'Code')
Switch $iCode
Case $NM_DBLCLK
Global $aHit = _GUICtrlListView_SubItemHitTest($GUI_ListBox)
If $aHit <> -1 Then
Local $aRect = _GUICtrlListView_GetSubItemRect($GUI_ListBox, $aHit, $aHit)
Local $sItemText = _GUICtrlListView_GetItemText($GUI_ListBox, $aHit, $aHit)
Local $aPos = ControlGetPos($hWnd, '', $GUI_ListBox)
Local $iStyle = BitOR($WS_CHILD, $WS_VISIBLE, $ES_AUTOHSCROLL, $ES_LEFT)
$hEdit = _GUICtrlEdit_Create($hWnd, $sItemText, $aPos + $aRect, $aPos + $aRect, _GUICtrlListView_GetColumnWidth($GUI_ListBox, $aHit), $iHeight, $iStyle)
_WinAPI_BringWindowToTop($hEdit)
_WinAPI_SetFont($hEdit, $hFont, True)
_GUICtrlEdit_SetMargins($hEdit, $EC_LEFTMARGIN, 4)
_WinAPI_SetFocus($hEdit)
_GUICtrlEdit_SetSel($hEdit, 0, -1)
EndIf
Case $NM_CLICK
Local $tInfo = DllStructCreate($tagNMITEMACTIVATE, $ilParam)
$a = DllStructGetData($tInfo, "Index") ;取得listview 游標id-index
Mouse_L_Click($a)
Case $NM_RCLICK ;滑鼠右鍵點擊
Local $tInfo = DllStructCreate($tagNMITEMACTIVATE, $ilParam)
$a = DllStructGetData($tInfo, "Index") ;取得listview 游標id-index
Mouse_R_Click($a)
EndSwitch
EndFunc ;==>WM_NOTIFY
Func WM_COMMAND($hWnd, $iMsg, $iwParam, $ilParam) ;滑鼠左鍵編選事件
Local $iCode = BitShift($iwParam, 16)
Local $nMsgID = BitAND($iwParam, 0x0000FFFF)
Switch $ilParam
Case $hEdit
Switch $iCode
Case $EN_KILLFOCUS
Local $sItemText = _GUICtrlEdit_GetText($hEdit)
_WinAPI_DestroyWindow($hEdit)
EndSwitch
EndSwitch
If $nMsgID = 1 And $hEdit <> '' Then
Local $sItemText = _GUICtrlEdit_GetText($hEdit)
_WinAPI_DestroyWindow($hEdit)
EndIf
Return $GUI_RUNDEFMSG
EndFunc ;==>WM_COMMAND
Func Mouse_R_Click($a) ;滑鼠右鍵選單
Local $aItem, $sText, $i
$aItem = _GUICtrlListView_GetItemTextArray($GUI_ListBox, $a) ;讀取指定LIST 內容
For $i = 1 To $aItem
If $i = 1 then $sText &= StringFormat("[%2d]日期: %s", $i, $aItem[$i]) & @CRLF
If $i = 2 then $sText &= StringFormat("[%2d]班別: %s", $i, $aItem[$i]) & @CRLF
If $i = 3 then $sText &= StringFormat("[%2d]勤務別: %s", $i, $aItem[$i]) & @CRLF
If $i = 4 then $sText &= StringFormat("[%2d]廠/站: %s", $i, $aItem[$i]) & @CRLF
If $i = 5 then $sText &= StringFormat("[%2d]系統: %s", $i, $aItem[$i]) & @CRLF
If $i = 6 then $sText &= StringFormat("[%2d]急迫性: %s", $i, $aItem[$i]) & @CRLF
If $i = 7 then $sText &= StringFormat("[%2d]追蹤事項: %s", $i, $aItem[$i]) & @CRLF
If $i = 8 then $sText &= StringFormat("[%2d]處理進度: %s", $i, $aItem[$i]) & @CRLF
If $i = 9 then $sText &= StringFormat("[%2d]狀態: %s", $i, $aItem[$i]) & @CRLF
Next
$aItem = _GUICtrlListView_GetItemTextArray($GUI_ListBox, $a) ;讀取指定LIST 內容
IF $aItem <> "" Then ;如果項目有資料則顯示
MsgBox($MB_SYSTEMMODAL, "交接事項內容",$sText)
ClipPut($aItem)
EndIf
EndFunc ;==>Example
Func Mouse_L_Click($a) ;滑鼠左鍵選單
Local $aItem, $sText, $i
$aItem = _GUICtrlListView_GetItemTextArray($GUI_ListBox, $a) ;讀取指定LIST 內容
If $aItem <> "" Then
_SQLite_QuerySingleRow(-1, "SELECT COUNT(Date) FROM interfix WHERE Date = '" & $aItem & "';", $aRow) ;查詢資料筆數,並存入變數
$aRow2 = Int($aRow) ;以整數值存入變數
If $aRow2 = 0 Then ;如果查無資料則顯示查無資料
_SQLite_QueryFinalize ( $hQuery )
MsgBox(0,"查詢結果","查無資料" )
Else ;將資料撈出並顯示
_SQLite_QuerySingleRow(-1, "SELECT * FROM interfix WHERE Date = '" & $aItem & "' COLLATE NOCASE ;", $aRow) ;查詢資料筆數,並存入變數
GUICtrlDelete($GUI_Combo1)
GUICtrlDelete($GUI_Combo2)
GUICtrlDelete($GUI_Combo3)
GUICtrlDelete($GUI_Combo4)
GUICtrlDelete($GUI_Combo5)
GUICtrlDelete($GUI_Combo6)
Sleep(100)
GUICtrlSetData($GUI_Input1, $aRow)
$GUI_COMBO1 = GUICtrlCreateCombo("", 188, 245, 60, 20,$CBS_DROPDOWNLIST);班別
GUICtrlSetData($GUI_COMBO1, $Shift, $aRow)
$GUI_COMBO2 = GUICtrlCreateCombo("", 292, 245, 50, 20,$CBS_DROPDOWNLIST);勤務
GUICtrlSetData($GUI_COMBO2, $Service, $aRow)
$GUI_COMBO3 = GUICtrlCreateCombo("", 387, 245, 50, 20,$CBS_DROPDOWNLIST) ;廠站
GUICtrlSetData($GUI_COMBO3, $UnitRange, $aRow)
$GUI_COMBO4 = GUICtrlCreateCombo("", 482, 245, 130, 20,$CBS_DROPDOWNLIST) ;系統
GUICtrlSetData($GUI_COMBO4, $SystemName, $aRow)
$GUI_COMBO5 = GUICtrlCreateCombo("", 690, 245, 50, 20,$CBS_DROPDOWNLIST) ;急迫性
GUICtrlSetData($GUI_COMBO5, $Ranking, $aRow)
GUICtrlSetData($GUI_Input2, $aRow, "")
GUICtrlSetData($GUI_Input3, $aRow, "")
$GUI_COMBO6 = GUICtrlCreateCombo("", 598, 275, 60, 20,$CBS_DROPDOWNLIST) ;狀態
GUICtrlSetData($GUI_COMBO6, $Status, $aRow)
EndIf
Else
GUICtrlDelete($GUI_Combo1)
GUICtrlDelete($GUI_Combo2)
GUICtrlDelete($GUI_Combo3)
GUICtrlDelete($GUI_Combo4)
GUICtrlDelete($GUI_Combo5)
GUICtrlDelete($GUI_Combo6)
Sleep(100)
$GUI_COMBO1 = GUICtrlCreateCombo("", 188, 245, 60, 20,$CBS_DROPDOWNLIST);班別
GUICtrlSetData($GUI_COMBO1, $Shift, "")
$GUI_COMBO2 = GUICtrlCreateCombo("", 292, 245, 50, 20,$CBS_DROPDOWNLIST);勤務
GUICtrlSetData($GUI_COMBO2, $Service, "")
$GUI_COMBO3 = GUICtrlCreateCombo("", 387, 245, 50, 20,$CBS_DROPDOWNLIST) ;廠站
GUICtrlSetData($GUI_COMBO3, $UnitRange, "")
$GUI_COMBO4 = GUICtrlCreateCombo("", 482, 245, 130, 20,$CBS_DROPDOWNLIST) ;系統
GUICtrlSetData($GUI_COMBO4, $SystemName, "")
$GUI_COMBO5 = GUICtrlCreateCombo("", 690, 245, 50, 20,$CBS_DROPDOWNLIST) ;急迫性
GUICtrlSetData($GUI_COMBO5, $Ranking, "")
$GUI_COMBO6 = GUICtrlCreateCombo("", 598, 275, 60, 20,$CBS_DROPDOWNLIST) ;狀態
GUICtrlSetData($GUI_COMBO6, $Status, "")
GUICtrlSetData($GUI_Input1, "" ) ;清空
GUICtrlSetData($GUI_Input2, "" ) ;清空
GUICtrlSetData($GUI_Input3, "" ) ;清空
EndIf
EndFunc ;==>Example
Func clear_columu() ;清除欄位
GUICtrlDelete($GUI_Combo1)
GUICtrlDelete($GUI_Combo2)
GUICtrlDelete($GUI_Combo3)
GUICtrlDelete($GUI_Combo4)
GUICtrlDelete($GUI_Combo5)
GUICtrlDelete($GUI_Combo6)
Sleep(100)
$GUI_COMBO1 = GUICtrlCreateCombo("", 188, 245, 60, 20,$CBS_DROPDOWNLIST);班別
GUICtrlSetData($GUI_COMBO1, $Shift, "")
$GUI_COMBO2 = GUICtrlCreateCombo("", 292, 245, 50, 20,$CBS_DROPDOWNLIST);勤務
GUICtrlSetData($GUI_COMBO2, $Service, "")
$GUI_COMBO3 = GUICtrlCreateCombo("", 387, 245, 50, 20,$CBS_DROPDOWNLIST) ;廠站
GUICtrlSetData($GUI_COMBO3, $UnitRange, "")
$GUI_COMBO4 = GUICtrlCreateCombo("", 482, 245, 130, 20,$CBS_DROPDOWNLIST) ;系統
GUICtrlSetData($GUI_COMBO4, $SystemName, "")
$GUI_COMBO5 = GUICtrlCreateCombo("", 690, 245, 50, 20,$CBS_DROPDOWNLIST) ;急迫性
GUICtrlSetData($GUI_COMBO5, $Ranking, "")
$GUI_COMBO6 = GUICtrlCreateCombo("", 598, 275, 60, 20,$CBS_DROPDOWNLIST) ;狀態
GUICtrlSetData($GUI_COMBO6, $Status, "")
GUICtrlSetData($GUI_Input1, "" ) ;清空
GUICtrlSetData($GUI_Input2, "" ) ;清空
GUICtrlSetData($GUI_Input3, "" ) ;清空
EndFunc
本帖最后由 kk_lee69 于 2018-3-19 16:15 编辑
回复 1# yohoboy
你移植了甚麼??沒看到你做任何 顏色處裡
你看到的顏色範例是哪個人家怎麼處理的??
Func WM_NOTIFY($hWnd, $iMsg, $iwParam, $ilParam) ;滑鼠點擊事件
Local $tNMHDR, $hWndFrom, $iCode,$hWndListView
$hWndListView = $GUI_ListBox
If Not IsHWnd($GUI_ListBox) Then $hWndListView = GUICtrlGetHandle($g_idListView)
$tNMHDR = DllStructCreate($tagNMHDR, $ilParam)
$hWndFrom = DllStructGetData($tNMHDR, 'hWndFrom')
$iCode = DllStructGetData($tNMHDR, 'Code')
Switch $iCode
Case $NM_DBLCLK
Global $aHit = _GUICtrlListView_SubItemHitTest($GUI_ListBox)
If $aHit <> -1 Then
Local $aRect = _GUICtrlListView_GetSubItemRect($GUI_ListBox, $aHit, $aHit)
Local $sItemText = _GUICtrlListView_GetItemText($GUI_ListBox, $aHit, $aHit)
Local $aPos = ControlGetPos($hWnd, '', $GUI_ListBox)
Local $iStyle = BitOR($WS_CHILD, $WS_VISIBLE, $ES_AUTOHSCROLL, $ES_LEFT)
$hEdit = _GUICtrlEdit_Create($hWnd, $sItemText, $aPos + $aRect, $aPos + $aRect, _GUICtrlListView_GetColumnWidth($GUI_ListBox, $aHit), $iHeight, $iStyle)
_WinAPI_BringWindowToTop($hEdit)
_WinAPI_SetFont($hEdit, $hFont, True)
_GUICtrlEdit_SetMargins($hEdit, $EC_LEFTMARGIN, 4)
_WinAPI_SetFocus($hEdit)
_GUICtrlEdit_SetSel($hEdit, 0, -1)
EndIf
Case $NM_CLICK
Local $tInfo = DllStructCreate($tagNMITEMACTIVATE, $ilParam)
$a = DllStructGetData($tInfo, "Index") ;取得listview 游標id-index
Mouse_L_Click($a)
Case $NM_RCLICK ;滑鼠右鍵點擊
Local $tInfo = DllStructCreate($tagNMITEMACTIVATE, $ilParam)
$a = DllStructGetData($tInfo, "Index") ;取得listview 游標id-index
Mouse_R_Click($a)
EndSwitch
EndFunc ;==>WM_NOTIFY 本帖最后由 yohoboy 于 2018-3-19 19:50 编辑
感谢回覆,代码那边忘了补上要变色的方式,有尝试过
GUICtrlCreateListViewItem
GUICtrlSetColor
_GUICtrlListView_GetItemText
等一些函数,也参考其他楼主一些代码,修改后一些回传的函数也有用msgbox查看也正确,但是行颜色还是不变,所以就刪除了那幾行代碼了,我在看其他現成代碼試看看,謝謝回覆。 回复 3# yohoboy
把你的東西 秀出來別人才知道怎麼幫你
另外不要給一大串的語法通常別人沒有你的環境 沒有你的資料庫所以 無法測試
應該給個簡單範例 自己寫 就會懂得怎麼應用到自己目前的語法中 本帖最后由 yohoboy 于 2018-3-21 00:22 编辑
如下圖紅框,如果超過3天(以今日起算),則該項目文字顏色變成紅色,其餘3天內項目文字顏色不變,我是按下測試鈕再加上如下程式碼,目前怎麼測試都無法變色,環節卡在這。
msgbox 是我加上去查看是否執行正確Func _GuiListView_SetItemColor()
Local $sText,$sText2,$aItem,$iItem,$iDateCalc,$b
$sText2 =_GUICtrlListView_GetItemCount($GUI_ListView)
For $i = 0 To ($sText2 - 1) step 1
$aItem = _GUICtrlListView_GetItemTextArray($GUI_ListView, $i)
$sText = StringLeft($aItem, 10)
$iDateCalc = _DateDiff('d', $sText, _NowCalc())
If $iDateCalc < 3 Then
MsgBox(0,"小於","小於" & $iDateCalc & "天")
Else
MsgBox(0,"大於","大於" & $iDateCalc & "天")
$b = ControlListView($Title, "", $GUI_ListView, "FindItem", $aItem )
MsgBox(0,"$b", $b)
GUICtrlSetColor(_GUICtrlListView_GetItemParam($GUI_ListView, $b), '0x0000FF') ;?
EndIf
Next
EndFunc 回复 5# yohoboy
如果我的觀念沒有錯誤的話~~~
你的作法錯誤了 ~~~
你去看所有的 變色範例不會有人寫個 FUNC 利用 GUICtrlSetColor 想要去改變 LISTVIEW 的顏色
想要讓 LISTVIEW 變色 必須要將處理顏色的語法寫入到 WM_NOTIFY 裡面的 處理顏色的區段
然後在那個區段裡面 要去判斷 你手上的 資料的某個值 是不是超過了超過就變色 不超過就 不變色
所以 你的整個邏輯 處理的位置 是有問題的
看一下下面的這篇
http://www.autoitx.com/forum.php? ... ght=LISTVIEW%2B%BCt 回复 5# yohoboy
是要这种效果? 差不多,不過已經試出來了,目前debug 中,確認ok後會將代碼post 出來,下圖是初步試成功的。
判斷依據 依急迫性等級 排除已經結案的,
緊急7天內黑字,7天以上到14天藍字,超過14天就紅字
重要7天內黑字,7天以上到14天藍字,超過14天就紅字
一般7天內黑字,7天以上到14天藍字,超過14天就紅字
其他黑字
當然天數部分可以依需求調整,以符合實際工作上要求完工期限。
回复 8# yohoboy
OK 觀念是對的............. 問題解決了 應該至少讓人了解 怎麼解決的
這樣這篇文章才有意義
你現在做的 是 整行變色 還有 可以填底色 或者 單格變色 回复 9# kk_lee69
目前還有BUG 要除中,等完整後會把全部程式碼POST上來,基本上我已經在程式碼中加入創造資料庫功能,只要把SQLITE 所需檔案放在程式目錄同一底下就可以測試了。 遇到相同问题,等楼主POST,谢谢 本帖最后由 yohoboy 于 2018-3-26 00:11 编辑
好了,應該沒bug 了(應該吧?), 先說明此程式使用說明
1. 創一個目錄。2.將附件檔案 au3 放到此目錄。3.確認檔案是否有sqlite所需檔案(.def.dll.exe等三個檔)
4.編輯附件檔案,並執行編譯成.exe檔。5.開啟此exe檔,會問你是否要創建資料庫,按確定創建。
6.重新執行。7.按下新增,內容隨便你打,打完後按下確定新增一筆資料。8.看要新增幾筆都可以。
9.修改windows系統時間,重複7到9項目,這時應該可以看到日期也隨之改變。10.點選功能鈕看是否
會隨時間變色。
目前就依此架構建立。可以一邊看程式碼一邊執行,比較能夠了解我怎麼寫的。
感謝以上樓主提供的意見,能順利寫出這程式幫助工作上的需求,謝謝了。{:face (190):}
2018/3/28 抽換附件檔案,還是有bug,所以更新一下。 回复 12# yohoboy
恭喜!! 完成一件作品 總是很開心的!! 回复 12# yohoboy
代码为何是乱码? 回复 14# chzj589
繁體吧
页:
[1]
2