home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC World 2007 June
/
PCWorld_2007-06_cd.bin
/
system
/
r-drive
/
rdi_en_4.exe
/
EULA.hta
< prev
next >
Wrap
Extensible Markup Language
|
2007-01-29
|
3KB
|
159 lines
<?xml version="1.0" encoding="utf-8"?>
<!doctype html public "-//W3C//DTD XHTML 1.0 Transitional//EN">
<html>
<head>
<HTA:APPLICATION ID="o-rtt-license-viewer"
APPLICATIONNAME="R-TT License viewer"
BORDER="thick"
CAPTION="yes"
-ICON=""
SHOWINTASKBAR="yes"
SINGLEINSTANCE="yes"
SYSMENU="yes"
SELECTION="yes"
INNERBORDER="no"
CONTEXTMENU="yes"
WINDOWSTATE="normal"
NAVIGABLE="yes"
SCROLL="no"
VERSION="1.00"
/>
<title>R-Drive Image license agreement</title>
<meta name="Author" content="R-TT" />
<meta name="email" content="support@r-tt.com" />
<meta name="Description" content="" />
<meta http-equiv="MSThemeCompatible" content="Yes" />
<style>
body
{
font-family: Georgia, 'Times New Roman', sans-serif;
font-size: 100%;
color: black;
background: buttonface;
overflow: hidden;
padding: 3pt;
margin: 0px;
height: 100%;
}
#content
{
overflow: auto;
white-space: pre;
background: window;
height: 100%;
padding: 3pt;
border: 1px inset;
}
.err { color: red; }
</style>
<script type="text/JScript">
function o( aId )
{
var obj = document.getElementById( aId );
if( !obj ) obj = document.all(aId);
return obj;
}
function showError( errHTML )
{
o("content").innerHTML = "<div class='err'>" + errHTML + "</div>"
}
function showTextFile( fileName, obj )
{
var ForReading = 1;
var Encoding = 0; // 0 -- ASCII -1 -- Unicode, -2 -- System default
var fso = new ActiveXObject( "Scripting.FileSystemObject" );
var file = null;
try
{
file = fso.OpenTextFile( fileName, ForReading, false, Encoding );
}
catch ( e ) { return false; }
if( !file ) return false;
var text = file.ReadAll();
obj.innerText = text;
file.Close();
return true;
}
onbeforeunload=function()
{
}
// =================================================================
onload = function()
{
var fileName = "EULA\\";
var key = "HKCU\\SOFTWARE\\R-TT\\R-DriveImage\\info\\license_type";
var Shell = new ActiveXObject("WScript.Shell");
var license_type;
try
{
license_type = Shell.RegRead( key );
}
catch( e )
{
showError( "Can not read license type. Reinstall application to solve this problem." );
return;
}
switch( license_type )
{
case "corp":
case "nfr":
case "commercial":
fileName += license_type + ".txt"; break;
default:
showError( "Unknown license type. Reinstall application to solve this problem." );
return;
}
if( !showTextFile( fileName, o("content") ) )
{
showError( "Can not read license file. Reinstall application to solve this problem." );
}
}
</script>
</head>
<body>
<table width="100%" height="100%" border="0">
<tr>
<td height="100%"><div id="content"></div></td>
</tr>
</table>
</body>
</html>