; TS-XL EN? Inst.exe?????? 
; Windows 98/98SE/Me/2000/XP/Vista
;
; Ver=1.00-yh
;
;------------------------------------------------------
;?????????
;------------------------------------------------------
[initialize]
title				= "TeraStation(TS-XL) Setup Guide Uninstaller"
date				= 081114 ; ??????????ID
run_with_admini		= YES
if_not_admini		= QUIT
goto				= install_check_os

;------------------------------------------------------
;OS??
;------------------------------------------------------
[install_check_os]
command			= check_os_ver4

if_win2000		= uninstall_start
if_winxp		= uninstall_start
if_win2003		= uninstall_start
if_winvista		= uninstall_start
if_win2008		= uninstall_start

if_other		= QUIT

;------------------------------------------------------
;Q&A????????
;------------------------------------------------------
[make_html_fol]
command			= make_folder

folder_path1	= "$PROG$\BUFFALO\TeraStation(TS-XL)\Manual\"

if_success		= copy_qa
if_error		= copy_qa

;------------------------------------------------------
[copy_qa]
command			= copy_file2

type			= COPY_SKIP_NEWFILE
folder1			= "$SETUP$\html", "$PROG$\BUFFALO\TeraStation(TS-XL)\Manual\html"

if_success		= add_group
if_error		= inst_error

;------------------------------------------------------
[add_group]
command			= add_menu_item_b

group			= "TeraStation(TS-XL) Setup Guide"
item1			= "TeraStation(TS-XL) User Manual", "$PROG$\BUFFALO\TeraStation(TS-XL)\Manual\html\index.html"

set_uninst		= YES
open_window		= NO

if_success		= add_desktop_shortcut
if_error		= inst_error

;------------------------------------------------------
[add_desktop_shortcut]
command			= make_shortcut

shortcut1		= "$DESKTOP$\BUFFALO TeraStation(TS-XL) User Manual.lnk", "$PROG$\BUFFALO\TeraStation(TS-XL)\Manual\html\index.html"


if_success		= Kill_Window
if_error		= inst_error
;------------------------------------------------------
[Kill_Window]
command			= find_window
window			= "TeraStation(TS-XL) Setup Guide","CabinetWClass"
option			= SEND_MESSAGE,274,61536,0

if_success		= set_uninst
if_error		= set_uninst
;------------------------------------------------------
[set_uninst]
command			= set_uninst_info

uninst_section	= uninstall_start
display_name	= "BUFFALO TeraStation(TS-XL) Setup Guide"
error_report	= YES

;if_success		= end_install
if_success		= QUIT
if_error		= inst_error

;------------------------------------------------------
[inst_error]
command			= disp_msg_box

string_num		= 3

string1			= "การติดตั้งคู่มือการตั้งค่า TeraStation(TS-XL)"
string2			= "ล้มเหลว"
string3			= "ติดตั้งอีกครั้งหลังจากเริ่มการทำงานของคอมพิวเตอร์ใหม่"

button			= OK
option			= STOP

if_ok_yes		= QUIT


[User_Cansel]
command			= quit
return			= 1

;------------------------------------------------------
;????????
;------------------------------------------------------
[uninstall_start]
command			= disp_dialog

string1			= "ขณะนี้กำลังเริ่มการถอดถอนการติดตั้งคู่มือการตั้งค่า"
string2			= "TeraStation(TS-XL)"
string3			= "คลิกที่ เริ่ม เพื่อถอดถอนการติดตั้งซอฟต์แวร์"
string4			= ""

button2			= เริ่ม, del_file
button3			= ยกเลิก, User_Cansel
focus			= 3

;------------------------------------------------------
[del_file]
command			= del_file

file_path1		= "$DESKTOP$\BUFFALO TeraStation(TS-XL) User Manual.lnk"
folder_path1	= "$PROG$\BUFFALO\TeraStation(TS-XL)\Manual",WITH_FILES
folder_path2	= "$PROG$\BUFFALO\TeraStation(TS-XL)"

if_success		= del_group
if_error		= del_group

;------------------------------------------------------
[del_group]
command			= del_menu_item

group			= "TeraStation(TS-XL) Setup Guide"

if_success		= del_uninst_data
if_error		= del_uninst_data

;------------------------------------------------------
[del_uninst_data]
command			= del_uninst_info

if_success		= report_uninst_error
if_error		= report_uninst_error

;------------------------------------------------------
[report_uninst_error]
command			= disp_error_report

if_no_error		= end_uninstall
if_error		= QUIT

;------------------------------------------------------
[end_uninstall]
command			= disp_dialog

string1			= "การถอดถอนการติดตั้งคู่มือการตั้งค่า TeraStation(TS-XL)"
string2			= "เสร็จสมบูรณ์แล้ว"

button3			= เสร็จสิ้น, QUIT
