[HELP] convert js code to vb.net

  • Thread starter Thread starter Salar Music
  • Start date Start date
S

Salar Music

Guest
hi guys.. can anyone help me in convert JS to VB.NET here is code


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!--
Author: Omar Muhammad
Email: knightofbaghdad@yahoo.com
Website: http://aliraqweb.com/en/
Program: The Arabic Writer - الكاتب العربي
Version: 1.2.0
Date: 3/7/2009
Progect Page: https://sourceforge.net/projects/arabicwriter/files/

test string: السلام عليكم اخي العزيز how are you ان شاء الله بخير .. ما شفناك من 2007 شو عم تعمل؟؟
-->
<html>
<head>
<title>Arabic Writer - الكاتب العربي</title>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<script type="text/javascript">
<!--
//defining the Unicode Letters
var alfmd = new Array("ﺁ","ﺁ","ﺂ","ﺂ");
var alfhz = new Array("ﺃ","ﺃ","ﺄ","ﺄ");
var wowhz = new Array("ﺅ","ﺅ","ﺆ","ﺆ");
var alfxr = new Array("ﺇ","ﺇ","ﺈ","ﺈ");
var hamzk = new Array("ﺉ","ﺋ","ﺌ","ﺊ");
var alfff = new Array("ﺍ","ﺍ","ﺎ","ﺎ");
var baaaa = new Array("ﺏ","ﺑ","ﺒ","ﺐ");
var tamrb = new Array("ﺓ","ﺓ","ﺔ","ﺔ");
var taaaa = new Array("ﺕ","ﺗ","ﺘ","ﺖ");
var thaaa = new Array("ﺙ","ﺛ","ﺜ","ﺚ");
var geeem = new Array("ﺝ","ﺟ","ﺠ","ﺞ");
var haaaa = new Array("ﺡ","ﺣ","ﺤ","ﺢ");
var khaaa = new Array("ﺥ","ﺧ","ﺨ","ﺦ");
var daaal = new Array("ﺩ","ﺩ","ﺪ","ﺪ");
var thaal = new Array("ﺫ","ﺫ","ﺬ","ﺬ");
var raaaa = new Array("ﺭ","ﺭ","ﺮ","ﺮ");
var zaaai = new Array("ﺯ","ﺯ","ﺰ","ﺰ");
var seeen = new Array("ﺱ","ﺳ","ﺴ","ﺲ");
var sheen = new Array("ﺵ","ﺷ","ﺸ","ﺶ");
var saaad = new Array("ﺹ","ﺻ","ﺼ","ﺺ");
var daaad = new Array("ﺽ","ﺿ","ﻀ","ﺾ");
var taaah = new Array("ﻁ","ﻃ","ﻄ","ﻂ");
var daaah = new Array("ﻅ","ﻇ","ﻈ","ﻆ");
var aayen = new Array("ﻉ","ﻋ","ﻌ","ﻊ");
var gayen = new Array("ﻍ","ﻏ","ﻐ","ﻎ");
var faaaa = new Array("ﻑ","ﻓ","ﻔ","ﻒ");
var qaaaf = new Array("ﻕ","ﻗ","ﻘ","ﻖ");
var kaaaf = new Array("ﻙ","ﻛ","ﻜ","ﻚ");
var laaam = new Array("ﻝ","ﻟ","ﻠ","ﻞ");
var meeem = new Array("ﻡ","ﻣ","ﻤ","ﻢ");
var nooon = new Array("ﻥ","ﻧ","ﻨ","ﻦ");
var hhhhh = new Array("ﻩ","ﻫ","ﻬ","ﻪ");
var wowww = new Array("ﻭ","ﻭ","ﻮ","ﻮ");
var yaamd = new Array("ﻯ","ﻯ","ﻰ","ﻰ");
var yaaaa = new Array("ﻱ","ﻳ","ﻴ","ﻲ");
var laamd = new Array("ﻵ","ﻵ","ﻶ","ﻶ");
var laahz = new Array("ﻷ","ﻷ","ﻸ","ﻸ");
var laaxr = new Array("ﻹ","ﻹ","ﻺ","ﻺ");
var laaaa = new Array("ﻻ","ﻻ","ﻼ","ﻼ");

//defining variables
var defLang="arabic"; //set default language: [arabic, english]
var e_numbers=0; //enable/disable arabic numbers: [0, 1]
var y=""; //initialize global vars
var old="";
var tstr="";
var msie=opera=0;
if (navigator.userAgent.indexOf("MSIE")>=0)
msie=1;
if (navigator.userAgent.indexOf("Opera")>=0)
opera=1;
//alert(navigator.userAgent);
var numbs0="الارقام العربية غير مفعلة";
var numbs1="الارقام العربية مفعلة";
var numbers="0123456789٠١٢٣٤٥٦٧٨٩"; //defining numbers
var unicode="ﺁﺁﺂﺂﺃﺃﺄﺄﺅﺅﺆﺆﺇﺇﺈﺈﺉﺋﺌﺊﺍﺍﺎﺎﺏﺑﺒﺐﺓﺓﺔﺔﺕﺗﺘﺖﺙﺛﺜﺚﺝﺟﺠﺞﺡﺣﺤﺢﺥﺧﺨﺦﺩﺩﺪﺪﺫﺫﺬﺬﺭﺭﺮﺮﺯﺯﺰﺰﺱﺳﺴﺲﺵﺷﺸﺶﺹﺻﺼﺺﺽﺿﻀﺾﻁﻃﻄﻂﻅﻇﻈﻆﻉﻋﻌﻊﻍﻏﻐﻎﻑﻓﻔﻒﻕﻗﻘﻖﻙﻛﻜﻚﻝﻟﻠﻞﻡﻣﻤﻢﻥﻧﻨﻦﻩﻫﻬﻪﻭﻭﻮﻮﻯﻯﻰﻰﻱﻳﻴﻲﻵﻵﻶﻶﻷﻷﻸﻸﻹﻹﻺﻺﻻﻻﻼﻼ"; //defining arabic unicode chars
var left = "ـئظشسيبلتنمكطضصثقفغعهخحج"; //defining letters that can connect from the left
var right= "ـئؤرلالآىآةوزظشسيبللأاأتنمكطضصثقفغعهخحجدذلإإ"; //defining letters that can connect from the right
var arabic="ًٌٍَُِّْْئءؤرلاىةوزظشسيبلاتنمكطضصثقفغعهخحجدذْلآآلأأـلإإ،؟"; //defining all arabic letters + harakat + symbols
var harakat="ًٌٍَُِّْْ"; //defining the harakat
var sym="ًٌٍَُِّـ.،؟ @#$%^&*-+|\/=~(){}ْ,"; //defining other symbols
var g;

function ProcessInput() //the processing function
{
frm=document.getElementById('form1');
frm.outbox.value="";
old="";
tstr="";
y=frm.inpbox.value;
x=y.split("");
len=x.length;
if (e_numbers==1) //if user choosed to show arabic numbers, then show them.
for (g=0;g<len;g++)
{
if (x[g]=="0")
x[g]="٠";
if (x[g]=="1")
x[g]="١";
if (x[g]=="2")
x[g]="٢";
if (x[g]=="3")
x[g]="٣";
if (x[g]=="4")
x[g]="٤";
if (x[g]=="5")
x[g]="٥";
if (x[g]=="6")
x[g]="٦";
if (x[g]=="7")
x[g]="٧";
if (x[g]=="8")
x[g]="٨";
if (x[g]=="9")
x[g]="٩";
y=x.join("");
}
for (g=0;g<len;g++) //process each letter, submit it to tests and then add it to the output string
{ //ignoring the harakat
b=a=1;
while (harakat.indexOf(x[g-b])>=0)
b=b+1;
while (harakat.indexOf(x[g+a])>=0)
a=a+1;
if (g==0) //determine the position of each letter
{
if (right.indexOf(x[a])>=0)
pos=1;
else
pos=0;
}
else if (g==(len-1))
{
if (left.indexOf(x[len-b-1])>=0)
pos=3;
else
pos=0;
}
else
{
if ((left.indexOf(x[(g-b)])>=0)&&(right.indexOf(x[(g+a)])>=0))
pos=2;
else if ((left.indexOf(x[(g-b)])<0)&&(right.indexOf(x[(g+a)])<0))
pos=0;
else if ((left.indexOf(x[(g-b)])<0)&&(right.indexOf(x[(g+a)])>=0))
pos=1;
else if ((left.indexOf(x[(g-b)])>=0)&&(right.indexOf(x[(g+a)])<0))
pos=3;
}
if (x[g]=="\n") //if this char is a new line, go to add new line function
addnewline();
else if (x[g]=="\r") //if this char is carriage return, skip it.
{}
else if (x[g]=="{") //dealing with parenthesis
addChar("}");
else if (x[g]=="}")
addChar("{");
else if (x[g]=="(")
addChar(")");
else if (x[g]==")")
addChar("(");
else if (x[g]=="ء")
addChar("ﺀ");
else if (x[g]=="آ") //dealing with letters, output each letter with its right position
addChar(alfmd[pos]);
else if (x[g]=="أ")
addChar(alfhz[pos]);
else if (x[g]=="ؤ")
addChar(wowhz[pos]);
else if (x[g]=="إ")
addChar(alfxr[pos]);
else if (x[g]=="ئ")
addChar(hamzk[pos]);
else if (x[g]=="ا")
addChar(alfff[pos]);
else if (x[g]=="ب")
addChar(baaaa[pos]);
else if (x[g]=="ة")
addChar(tamrb[pos]);
else if (x[g]=="ت")
addChar(taaaa[pos]);
else if (x[g]=="ث")
addChar(thaaa[pos]);
else if (x[g]=="ج")
addChar(geeem[pos]);
else if (x[g]=="ح")
addChar(haaaa[pos]);
else if (x[g]=="خ")
addChar(khaaa[pos]);
else if (x[g]=="د")
addChar(daaal[pos]);
else if (x[g]=="ذ")
addChar(thaal[pos]);
else if (x[g]=="ر")
addChar(raaaa[pos]);
else if (x[g]=="ز")
addChar(zaaai[pos]);
else if (x[g]=="س")
addChar(seeen[pos]);
else if (x[g]=="ش")
addChar(sheen[pos]);
else if (x[g]=="ص")
addChar(saaad[pos]);
else if (x[g]=="ض")
addChar(daaad[pos]);
else if (x[g]=="ط")
addChar(taaah[pos]);
else if (x[g]=="ظ")
addChar(daaah[pos]);
else if (x[g]=="ع")
addChar(aayen[pos]);
else if (x[g]=="غ")
addChar(gayen[pos]);
else if (x[g]=="ف")
addChar(faaaa[pos]);
else if (x[g]=="ق")
addChar(qaaaf[pos]);
else if (x[g]=="ك")
addChar(kaaaf[pos]);
else if (x[g]=="ل")
{
g=g+1; //dealing with la combination
if (x[g]=="ا")
addChar(laaaa[pos]);
else if (x[g]=="أ")
addChar(laahz[pos]);
else if (x[g]=="إ")
addChar(laaxr[pos]);
else if (x[g]=="آ")
addChar(laamd[pos]);
else
{
g=g-1;
addChar(laaam[pos]);
}
}
else if (x[g]=="م")
addChar(meeem[pos]);
else if (x[g]=="ن")
addChar(nooon[pos]);
else if (x[g]=="ه")
addChar(hhhhh[pos]);
else if (x[g]=="و")
addChar(wowww[pos]);
else if (x[g]=="ى")
addChar(yaamd[pos]);
else if (x[g]=="ي")
addChar(yaaaa[pos]);
else if (x[g]=="لآ")
addChar(laamd[pos]);
else if (x[g]=="لأ")
addChar(laahz[pos]);
else if (x[g]=="لإ")
addChar(laaxr[pos]);
else if (x[g]=="لا")
addChar(laaaa[pos]);
else if (sym.indexOf(x[g])>=0) //if the char is a symbol, add it
addChar(x[g]);
else if (unicode.indexOf(x[g])>=0) //if the char is an arabic reversed letter, reverse it back!
addChar(x[g]);
else //if the char is none of the above, then treat it as english text (dont reverse)
addEngChar(x[g],g);
}
frm.outbox.value=old+frm.outbox.value; //put together the old text and the last sentence
}
function addChar(chr) //add arabic chars (reverse)
{
frm=document.getElementById('form1');
frm.outbox.value=chr+frm.outbox.value;
}
function addChar2(chr) //add arabic chars from keyboard
{
frm=document.getElementById('form1');
frm.inpbox.value=frm.inpbox.value+chr;
}
function addEngChar(chr,h) //add english chars + numbers + symbols (as is)
{
frm=document.getElementById('form1');
x=y.split("");
while ((arabic.indexOf(x[h])<0)&&(unicode.indexOf(x[h])<0)&&(x[h]!=undefined)) //if this is an english sentence, put it all in one string
{
tstr=tstr+x[h];
h=h+1;
if ((msie==1)||(opera==1)) //solving a ie/opera difference in javascript
{ff=h+1;}
else
{ff=h;}
if (x[ff]=="\n")
break;
}
xstr=tstr.split("");
r=xstr.length-1;
if ((r==1)&&(xstr[1]==" ")) //make sure spaces between arabic and english text display properly
tstr=" "+xstr[0];
else
{
while (xstr[r]==" ")
{
tstr=" "+tstr.substring(0,(tstr.length-1));
r=r-1;
}
}
frm.outbox.value=tstr+frm.outbox.value; //put together the arabic text + the new english text
tstr="";
g=h-1; //set the loop pointer to the first char after the english text.
}
function remChar() //remove char from keyboard
{
frm=document.getElementById('form1');
mainlength=frm.inpbox.value.length;
frm.inpbox.value=frm.inpbox.value.substring(0,mainlength-1);
}
function addnewline() //if new line occurs, save old data in a temp, process new data, then regroup
{
frm=document.getElementById('form1');
old=old+frm.outbox.value+"\n";
frm.outbox.value="";
}
function selectit()
{
output=document.getElementById('outbox');
output.focus();
output.select();
}
function numbs()
{
if (e_numbers==1)
{
e_numbers=0;
setvalue("xnumbers",numbs0);
}
else
{
e_numbers=1;
setvalue("xnumbers",numbs1);
}
}
function copyclip(Data)
{
window.clipboardData.setData('text',Data);
}
function setdefault(deflang)
{
chnglang(deflang);
}
function show(item)
{
document.getElementById(item).style.display="block";
}
function hide(item)
{
document.getElementById(item).style.display="none";
}
function setvalue(item,value)
{
document.getElementById(item).value=value;
}
function setinnerH(item,value)
{
document.getElementById(item).innerHTML=value;
}
function chnglang(langid)
{
if (msie==0)
hide("clipcopy");
//hide all help windows, to determine which one to show now.
hide("arabicH");
hide("englishH");
if (langid=="arabic")
{
numbs0="الارقام العربية غير مفعلة";
numbs1="الارقام العربية مفعلة";
numbs();numbs();
setinnerH("box1info","اكتب او انسخ النص الذي تريد استعماله هنا");
setinnerH("box2info","بعد انتهائك من الكتابة، اضغط (معالجة النص) ثم قم بنسخ النص الناتج من هنا");
setinnerH("chooselang","إختر اللغة");
setvalue("heeelp","مساعدة");
setvalue("laaang","اللغة");
setvalue("keybd","لوحة المفاتيح العربية");
setvalue("kspace"," مسافة ");
setvalue("kclose","إخفاء لوحة المفاتيح");
setvalue("kbspace"," تراجع ");
setvalue("deletetxt","حذف النص");
setvalue("selecttxt","تظليل النص المعالج");
setvalue("clipcopy","نسخ النص المعالج");
setvalue("processtxt","معالجة النص");
show("arabicH");
}
else if (langid=="english")
{
numbs0="Arabic Numbers Disabled";
numbs1="Arabic Numbers Enabled";
numbs();numbs();
setinnerH("box1info","Write the Text you want to Convert here");
setinnerH("box2info","When you are done writing, press (Process Input) button, then copy the text from here");
setinnerH("chooselang","Choose your language");
setvalue("heeelp","help");
setvalue("laaang","Language");
setvalue("keybd","Arabic Keyboard");
setvalue("kspace"," Space ");
setvalue("kbspace","BackSpace");
setvalue("kclose","Hide Keyboard");
setvalue("deletetxt","Clear Fields");
setvalue("selecttxt","Select Output");
setvalue("clipcopy","Copy Output");
setvalue("processtxt","Process Input");
show("englishH");
}
//add new language here!, copy paste the english part (10 lines above this one), and then edit it.
hide("lang");
}
-->
</script>
</head>
<body onload='setdefault(defLang);'>
<center>
<form name='form1' id='form1' action=''>
<br />
<div id='box1info'>
</div>
<textarea dir='rtl' style="color: #000080; font-family: Tahoma" name='inpbox' id='inpbox' rows='9' cols='80'></textarea>
<br />
<br />
<div id='box2info'>
</div>
<textarea dir='rtl' style="color: #000080; font-family: Tahoma" name='outbox' id='outbox' rows='9' cols='80'></textarea>
<br />
<br />
<input id='deletetxt' type=reset value="" />
<input id='clipcopy' onclick='copyclip(frm.outbox.value);' type="button" value="" />
<input id='selecttxt' onclick="selectit();" type="button" value="" />
<input id='processtxt' onclick="ProcessInput();" type="button" value="" />
<br />
<br />
<input id='heeelp' onclick='show("help");' type="button" value="" />
<input id='laaang' onclick='show("lang");' type="button" value="" />
<input id='keybd' onclick='show("keyboard");' type="button" value="" />
<input id='xnumbers' onclick='numbs();' type="button" value="" />

<!-- start All help-->
<div id='help' style='display:none;'>
<!-- start Arabic help-->
<div id='arabicH' style='width:700px; height:560px; top:0px; right:50px; ; background-color:#fff; display:block' dir='rtl' align='right'>
<br /><br />
<h3>تعليمات البرنامج:</h3>
<ol>
<li><h4>ما هو الكاتب العربي؟</h4>
<h5>الكاتب العربي هو برنامج صمم لكي يساعد المصممين العرب في الكتابة بالبرامج التي لا تدعم اللغة العربية
كبرنامج Adobe Photoshop وغيره من برامج التصميم.
</h5>
</li>
<li><h4>كيف يعمل الكاتب العربي؟</h4>
<h5>
صحيح ان بعض البرامج لا تدعم اللغة العربية، ولكن اغلب البرامج تدعم اليونيكود Unicode
وهو نظام حرفي يجمع كل حروف اللغات المختلفة ويدعمها جميعا
</h5>
<h5>
لكنه كما في اغلب اللغات الاجنبية، يكتب من اليسار الى اليمين.. لذلك تجد برنامج الفوتوشوب مثلا يكتب الكلمات بالمقلوب.
اذا فكل ما نحتاجه هو برنامج يعيد ترتيب الحروف التي ندخلها بحيث تظهر بصورة صحيحة داخل البرامج، وهذا هو بالضبط هو ما يفعله الكاتب العربي.
</h5>
</li>
<li><h4>ما هي مميزات الكاتب العربي؟</h4>
<h5>يتميز الكاتب العربي اولا بكونه مجاني ومتاح للجميع استخدامه والتعديل عليه اذا شعروا بالحاجة لذلك. ثانيا.. يتميز بانه لا يحتاج الى مجموعة خطوط لدعمه..
كل ما يلزم هو برنامج يدعم اليونيكود .. حيث ان اغلب انظمة التشغيل تحتوي على خطوط تدعم اليونيكود
مثل خط الـ Arial الشهير وغيره.
كما يتميز بانه يدعم الحروف الانكليزية والرموز والاقواس والارقام العربية والانجليزية والاسطر المتعددة وغيرها
كما ويدعم هذا البرنامج ارجاع النص الناتج الى اصله اذا تم معالجته مرة ثانية بنفس الطريقة..
ويتميز البرنامج بسهولة تعديله من دون الحاجة الى اعادة بناءه.. حيث يمكن تعديل البرنامح كاملا من خلال تعديل ملف الـ HTML المرافق له.
ويحتوي البرنامج على قابلية اظهار لوحة مفاتيح عربية وذلك لدعم الانظمة التي لا تدعم العربية بالمرة.
كما يتميز بانه برنامج محمول يمكنك ان تاخذه معك على الفلاش دسك.
بالاضافة الى ذلك، فان البرنامج يمكن اي يعمل عن طريق تشغيل ملف الـ exe (يتطلب Windows + .NET Framework 2 or higher) او من خلال فتح صفحة الـ HTML المرافقة للبرنامج في اي متصفح انترنت. وبهذه الطريقة يمكن تشغيل هذا البرنامج على اي نظام تشغيل يحتوي على متصفح انترنت
..ويتميز البرنامج بحجمه الصغير جدا.
</h5>
</li>
</ol>
<input onclick='hide("help");' type="button" value="إغلاق" />
</div>
<!-- end arabic help-->

<!-- start English help-->
<div id='englishH' style='width:700px; height:560px; top:0px; right:50px; ; background-color:#fff; display:none' dir='ltr' align='left'>
<br /><br />
<h3>Program Information:</h3>
<ol>
<li><h4>What is the Arabic Writer?</h4>
<h5>The Arabic Writer is a program designed to help Arab Designers to work with Programs that doesn't support Arabic language characters, such as Adobe Photoshop.
</h5>
</li>
<li><h4>How does the Arabic Writer work?</h4>
<h5>
While some programs doesn't support Arabic characters, almost all programs support Unicode, which is a universal charset that includes almost every character of every language.
</h5>
<h5>
But, as in most western languages, its left-to-right oriented, that's why when you try to type Arabic letters in Photoshop, it appears like you are writing backwards.
so, all we need is a program that rearranges the Arabic letters in a way that shows the characters as whole senteces. that's exactly what the Arabic Writer does.
</h5>
</li>
<li><h4>What are the advantages of the Arabic Writer?</h4>
<h5>first of all, its free, and available for everyone to use or edit if needed.
second, it doesn't need a pack of special fonts (as in some programs), as most of the Operating Systems out there have fonts that support unicode like the Arial font for example.
it also supports English letters, symbols, parenthesis, Arabic and English numbers, the use of multiple lines, and it can convert back the generated text if it was processed again in the same manner.
and its very easy to edit the program by editing the HTML file, no need to recompile the code.
it has an on-screen keyboard to support systems that doesn't support the Arabic language at all.
its also portable, and can be run either from the exe file (Requires Windows + .NET Framework 2 or higher), or by simply running the HTML file in any browser. in this way, the program can be used in any operating system.
and its very small in size.
</h5>
</li>
</ol>
<input onclick='hide("help");' type="button" value="close" />
</div>
<!-- end English help-->

<!-- Add new Help Here -->

<!-- End new Help Here -->
</div>
<!-- end All help-->

<!-- start language window-->
<div id='lang' style='border:2px solid #aaa; padding:20px; width:300px; height:100px; top:250px; right:250px; ; background-color:#fff; display:none' align='center'>
<h5 id='chooselang'></h5>
<input onclick='chnglang("arabic");' type="button" value="العربية" />
<input onclick='chnglang("english");' type="button" value="English" />
</div>
<!-- end language window-->
<div id='keyboard' style='border:2px solid #aaa; padding:20px; width:560px; height:150px; top:200px; right:100px; ; background-color:#fff; display:none' dir='rtl' align='center'>
<input id='kbspace' onclick="remChar();" type=button value="Backspace" />
<input onclick="addChar2('د');" type=button value="د">
<input onclick="addChar2('-');" type=button value="-">
<input onclick="addChar2('&#1632;');" type=button value=" &#1632; " />
<input onclick="addChar2('&#1641;');" type=button value=" &#1641; " />
<input onclick="addChar2('&#1640;');" type=button value=" &#1640; " />
<input onclick="addChar2('&#1639;');" type=button value=" &#1639; " />
<input onclick="addChar2('&#1638;');" type=button value=" &#1638; " />
<input onclick="addChar2('&#1637;');" type=button value=" &#1637; " />
<input onclick="addChar2('&#1636;');" type=button value=" &#1636; " />
<input onclick="addChar2('&#1635;');" type=button value=" &#1635; " />
<input onclick="addChar2('&#1634;');" type=button value=" &#1634; " />
<input onclick="addChar2('&#1633;');" type=button value=" &#1633; " />
<input onclick="addChar2('ذ');" type=button value="ذ">
<br />
<input onclick="addChar2('ج');" type=button value=" ج " />
<input onclick="addChar2('ح');" type=button value=" ح " />
<input onclick="addChar2('خ');" type=button value=" خ " />
<input onclick="addChar2('ه');" type=button value=" ه " />
<input onclick="addChar2('ع');" type=button value=" ع " />
<input onclick="addChar2('غ');" type=button value=" غ " />
<input onclick="addChar2('ف');" type=button value=" ف " />
<input onclick="addChar2('ق');" type=button value=" ق " />
<input onclick="addChar2('ث');" type=button value=" ث " />
<input onclick="addChar2('ص');" type=button value=" ص " />
<input onclick="addChar2('ض');" type=button value=" ض " />
<br />
<input onclick="addChar2('ط');" type=button value=" ط " />
<input onclick="addChar2('ك');" type=button value=" ك " />
<input onclick="addChar2('م');" type=button value=" م " />
<input onclick="addChar2('ن');" type=button value=" ن " />
<input onclick="addChar2('ت');" type=button value=" ت " />
<input onclick="addChar2('ا');" type=button value=" ا " />
<input onclick="addChar2('ل');" type=button value=" ل " />
<input onclick="addChar2('ب');" type=button value=" ب " />
<input onclick="addChar2('ي');" type=button value=" ي " />
<input onclick="addChar2('س');" type=button value=" س " />
<input onclick="addChar2('ش');" type=button value=" ش " />
<br />
<input onclick="addChar2('ظ');" type=button value=" ظ " />
<input onclick="addChar2('ز');" type=button value=" ز " />
<input onclick="addChar2('و');" type=button value=" و " />
<input onclick="addChar2('ة');" type=button value=" ة " />
<input onclick="addChar2('ى');" type=button value=" ى " />
<input onclick="addChar2('أ');" type=button value=" أ " />
<input onclick="addChar2('إ');" type=button value=" إ " />
<input onclick="addChar2('لا');" type=button value=" لا " />
<input onclick="addChar2('لأ');" type=button value=" لأ " />
<input onclick="addChar2('ر');" type=button value=" ر " />
<input onclick="addChar2('ؤ');" type=button value=" ؤ " />
<input onclick="addChar2('ء');" type=button value=" ء " />
<input onclick="addChar2('ئ');" type=button value=" ئ " />
<br />
<input onclick="addChar2('؟');" type=button value=" ؟ " />
<input onclick="addChar2('.');" type=button value=" . " />
<input onclick="addChar2(':');" type=button value=" : " />
<input onclick="addChar2('،');" type=button value=" ، " />
<input id='kspace' onclick="addChar2(' ');" type=button value="" />
<input onclick="addChar2('(');" type=button value=" ( " />
<input onclick="addChar2(')');" type=button value=" ) " />
<input onclick="addChar2('$');" type=button value=" $ " />
<input onclick="addChar2('!');" type=button value=" ! " />
<br />
<br />
<input id='kclose' onclick='hide("keyboard");' type="button" value="close" />
</div>
</form>

</center>
</body>




i just know to to convert varible


'defining the Unicode Letters
Dim alfmd() As String = {"ﺁ", "ﺁ", "ﺂ", "ﺂ"}
Dim alfhz() As String = {"ﺃ", "ﺃ", "ﺄ", "ﺄ"}
Dim wowhz() As String = {"ﺅ", "ﺅ", "ﺆ", "ﺆ"}
Dim alfxr() As String = {"ﺇ", "ﺇ", "ﺈ", "ﺈ"}
Dim hamzk() As String = {"ﺉ", "ﺋ", "ﺌ", "ﺊ"}
Dim alfff() As String = {"ﺍ", "ﺍ", "ﺎ", "ﺎ"}
Dim baaaa() As String = {"ﺏ", "ﺑ", "ﺒ", "ﺐ"}
Dim tamrb() As String = {"ﺓ", "ﺓ", "ﺔ", "ﺔ"}
Dim taaaa() As String = {"ﺕ", "ﺗ", "ﺘ", "ﺖ"}
Dim thaaa() As String = {"ﺙ", "ﺛ", "ﺜ", "ﺚ"}
Dim geeem() As String = {"ﺝ", "ﺟ", "ﺠ", "ﺞ"}
Dim haaaa() As String = {"ﺡ", "ﺣ", "ﺤ", "ﺢ"}
Dim khaaa() As String = {"ﺥ", "ﺧ", "ﺨ", "ﺦ"}
Dim daaal() As String = {"ﺩ", "ﺩ", "ﺪ", "ﺪ"}
Dim thaal() As String = {"ﺫ", "ﺫ", "ﺬ", "ﺬ"}
Dim raaaa() As String = {"ﺭ", "ﺭ", "ﺮ", "ﺮ"}
Dim zaaai() As String = {"ﺯ", "ﺯ", "ﺰ", "ﺰ"}
Dim seeen() As String = {"ﺱ", "ﺳ", "ﺴ", "ﺲ"}
Dim sheen() As String = {"ﺵ", "ﺷ", "ﺸ", "ﺶ"}
Dim saaad() As String = {"ﺹ", "ﺻ", "ﺼ", "ﺺ"}
Dim daaad() As String = {"ﺽ", "ﺿ", "ﻀ", "ﺾ"}
Dim taaah() As String = {"ﻁ", "ﻃ", "ﻄ", "ﻂ"}
Dim daaah() As String = {"ﻅ", "ﻇ", "ﻈ", "ﻆ"}
Dim aayen() As String = {"ﻉ", "ﻋ", "ﻌ", "ﻊ"}
Dim gayen() As String = {"ﻍ", "ﻏ", "ﻐ", "ﻎ"}
Dim faaaa() As String = {"ﻑ", "ﻓ", "ﻔ", "ﻒ"}
Dim qaaaf() As String = {"ﻕ", "ﻗ", "ﻘ", "ﻖ"}
Dim kaaaf() As String = {"ﻙ", "ﻛ", "ﻜ", "ﻚ"}
Dim laaam() As String = {"ﻝ", "ﻟ", "ﻠ", "ﻞ"}
Dim meeem() As String = {"ﻡ", "ﻣ", "ﻤ", "ﻢ"}
Dim nooon() As String = {"ﻥ", "ﻧ", "ﻨ", "ﻦ"}
Dim hhhhh() As String = {"ﻩ", "ﻫ", "ﻬ", "ﻪ"}
Dim wowww() As String = {"ﻭ", "ﻭ", "ﻮ", "ﻮ"}
Dim yaamd() As String = {"ﻯ", "ﻯ", "ﻰ", "ﻰ"}
Dim yaaaa() As String = {"ﻱ", "ﻳ", "ﻴ", "ﻲ"}
Dim laamd() As String = {"ﻵ", "ﻵ", "ﻶ", "ﻶ"}
Dim laahz() As String = {"ﻷ", "ﻷ", "ﻸ", "ﻸ"}
Dim laaxr() As String = {"ﻹ", "ﻹ", "ﻺ", "ﻺ"}
Dim laaaa() As String = {"ﻻ", "ﻻ", "ﻼ", "ﻼ"}

'defining dimiables
Dim y As String = "" 'initialize global dims
Dim old As String = ""
Dim tstr As String = ""

'alert(navigator.userAgent)
Dim numbs0 As String = "الارقام العربية غير مفعلة"
Dim numbs1 As String = "الارقام العربية مفعلة"
Dim numbers As String = "0123456789٠١٢٣٤٥٦٧٨٩" 'defining numbers
Dim unicode As String = "ﺁﺁﺂﺂﺃﺃﺄﺄﺅﺅﺆﺆﺇﺇﺈﺈﺉﺋﺌﺊﺍﺍﺎﺎﺏﺑﺒﺐﺓﺓﺔﺔﺕﺗﺘﺖﺙﺛﺜﺚﺝﺟﺠﺞﺡﺣﺤﺢﺥﺧﺨﺦﺩﺩﺪﺪﺫﺫﺬﺬﺭﺭﺮﺮﺯﺯﺰﺰﺱﺳﺴﺲﺵﺷﺸﺶﺹﺻﺼﺺﺽﺿﻀﺾﻁﻃﻄﻂﻅﻇﻈﻆﻉﻋﻌﻊﻍﻏﻐﻎﻑﻓﻔﻒﻕﻗﻘﻖﻙﻛﻜﻚﻝﻟﻠﻞﻡﻣﻤﻢﻥﻧﻨﻦﻩﻫﻬﻪﻭﻭﻮﻮﻯﻯﻰﻰﻱﻳﻴﻲﻵﻵﻶﻶﻷﻷﻸﻸﻹﻹﻺﻺﻻﻻﻼﻼ" 'defining arabic unicode chars
Dim Left As String = "ـئظشسيبلتنمكطضصثقفغعهخحج" 'defining letters that can connect from the left
Dim Right As String = "ـئؤرلالآىآةوزظشسيبللأاأتنمكطضصثقفغعهخحجدذلإإ" 'defining letters that can connect from the right
Dim arabic As String = "ًٌٍَُِّْْئءؤرلاىةوزظشسيبلاتنمكطضصثقفغعهخحجدذْلآآلأأـلإإ،؟" 'defining all arabic letters + harakat + symbols
Dim harakat As String = "ًٌٍَُِّْْ" 'defining the harakat
Dim sym As String = "ًٌٍَُِّـ.،؟ @#$%^&*-+|\/as string =~(){}ْ," 'defining other symbols
Dim g As String

Continue reading...
 
Back
Top