<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress.com" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>

<channel>
	<title>vb6 &amp;laquo; WordPress.com Tag Feed</title>
	<link>http://en.wordpress.com/tag/vb6/</link>
	<description>Feed of posts on WordPress.com tagged "vb6"</description>
	<pubDate>Sat, 05 Dec 2009 19:49:36 +0000</pubDate>

	<generator>http://en.wordpress.com/tags/</generator>
	<language>en</language>

<item>
<title><![CDATA[Just like the VB revolution, only for web]]></title>
<link>http://webgui20.wordpress.com/2009/11/23/just-like-the-vb-revolution-only-for-web/</link>
<pubDate>Mon, 23 Nov 2009 07:45:26 +0000</pubDate>
<dc:creator>webgui20</dc:creator>
<guid>http://webgui20.wordpress.com/2009/11/23/just-like-the-vb-revolution-only-for-web/</guid>
<description><![CDATA[Just a decade and a half ago, the process of building a simple Windows-based application could have ]]></description>
<content:encoded><![CDATA[Just a decade and a half ago, the process of building a simple Windows-based application could have ]]></content:encoded>
</item>
<item>
<title><![CDATA[Tips dan trik Visual Basic 6 (1)]]></title>
<link>http://kuclukblog.wordpress.com/2009/11/14/tips-dan-trik-visual-basic-6-1/</link>
<pubDate>Sat, 14 Nov 2009 10:32:36 +0000</pubDate>
<dc:creator>kuclukblog</dc:creator>
<guid>http://kuclukblog.wordpress.com/2009/11/14/tips-dan-trik-visual-basic-6-1/</guid>
<description><![CDATA[Dalam membuat program, optimasi code sangat penting untuk diketahui yang sedikit banyaknya akan memp]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Dalam membuat program, optimasi code sangat penting untuk diketahui yang sedikit banyaknya akan mempengaruhi proses kinerja dari program. Saya akan coba share tentang tips dan trik dalam pemrograman visual basic 6, dan semoga dapat berguna.</p>
<p>* Penggunaan Option Explicit</p>
<p>Penggunaan Option Explicit sangat berguna di dalam source code, kenapa? karna dengan option explicit, seluruh variabel dan object yang digunakan di dalam kode program harus di definisikan terlebih dahulu, sehingga kita akan dapat memantau penggunaan tipe dari tiap-tiap variabel tersebut. Akan berbeda apabila kita tidak menggunakan option explicit, kita akan seenaknya meng-assign suatu variabel atau objek tanpa mendeklarasikan terlebih dahulu, karna tidak ada pemaksaan untuk itu, sehingga akan sangat memungkinkan banyaknya penggunaan variabel yang bertipe variant, di mana penggunaan variabel dengan tipe tersebut sangat dianjurkan untuk tidak digunakan. Karena menggunakan alokasi memori yang besar.</p>
<p>Untuk menggunakan Option Explicit, cukup mengetikkan Option Explicit pada awal tiap modul. Atau dengan cara klik menu Tools pada IDE VB6, lalu pilih Options, kemudian klik tab Editor dan beri tanda centang pada pilihan Require Variable Declaration. Hal ini secara otomatis akan menyisipkan pernyataan Option Explicit di modul apapun yang akan Anda buat, tapi tidak di modul yang sudah pernah dibuat; sehingga oleh karena itu, Anda harus secara manual menambahkan pernyataan Option Explicit kepada setiap modul yang terdapat di sebuah project.</p>
<p>* Penggunaan string dengan maximal length</p>
<p>Tipe variabel string merupakan salah satu tipe yang menggunakan alokasi memori yang cukup besar. Kadang-kadang kita mendeklarasikan variabel dengan tipe string tanpa membatasi jumlah karakter maksimalnya, sementara kebutuhan maksimal panjang karakter yang kita gunakan, sudah dapat kita perkirakan. Alangkah lebih baik jika maksimal karakter tersebut kita batasi sesuai kebutuhan. Sebagaimana properti yang dimiliki oleh textbox (properti maxlength), untuk variabel string, maksimal panjang karakternya dapat dibatasi pada saat pendeklarasian variabel tersebut. Adapun sintaksnya :</p>
<p>&#8216;Misal : deklarasi variabel strVariable, dengan maksimal panjang karakter yang dibutuhkan : 10</p>
<p>Dim strVariable as string * 10</p>
<p>* Penggunaan array dinamis</p>
<p>Penggunaan array dinamis dapat mengalokasikan penggunaan memori sesuai kebutuhan, karena setiap saat indeks dari array dapat ditambah atau dikurangi pada saat runtime, sehingga penggunaan array tersebut juga akan efisien.</p>
<p>Untuk membuat array dinamis, dapat dilakukan dengan menggunakan keyword ReDim PreServe, di mana saat dilakukan penambahan atau pengurangan jumlah indeks dari array tersebut, nilainya tidak akan terganggu. Berbeda dengan apabila hanya menggunakan keyword ReDim, nilai dari setiap indeks array akan terhapus.</p>
<p>sintaks :</p>
<p>Dim myArray(3)  &#8216;Deklarasi awal</p>
<p>ReDim myArray(10)  &#8216;Mendeklarasikan ulang dengan nilai yang tidak tersimpan</p>
<p>ReDim PreServe myArray(13)  &#8216;Mendeklarasikan ulang dengan nilai yang tidak terganggu(nilainya tidak terhapus)</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[VBSmart Menu XP in Windows Vista]]></title>
<link>http://pandazen.wordpress.com/2009/11/11/vbsmart-menu-xp-in-windows-vista/</link>
<pubDate>Wed, 11 Nov 2009 08:25:51 +0000</pubDate>
<dc:creator>pandazen</dc:creator>
<guid>http://pandazen.wordpress.com/2009/11/11/vbsmart-menu-xp-in-windows-vista/</guid>
<description><![CDATA[I use VBSmart Menu XP (SmartMenuXP.dll and SmartMenuXP.ocx) in Windows 98 and XP for a long time. No]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>I use VBSmart Menu XP (SmartMenuXP.dll and SmartMenuXP.ocx) in Windows 98 and XP for a long time. Now, I switched to Windows Vista Business Edition. It comes the problem, every time I click menu VBSmart Menu XP, the program hangs.</p>
<p>After trying to find many solution, at last, I try to change themes from &#8220;Windows Vista&#8221; to &#8220;Windows Classic&#8221;,then VBSmart was no problem anymore.</p>
<p>In fact, this solution is sufficient, but it was jammed, when to use my program, i have to change the theme again.</p>
<p>Then I tried to restore the theme to &#8220;Windows Vista&#8221;, then I try to change the visual effects settings in</p>
<p>Control Panel \ System and Maintenance \ System</p>
<p>then select &#8220;Advanced system settings&#8221;<br />
in the frame &#8220;Performance&#8221; , click the button  &#8220;Settings&#8221;,<br />
then disable the option &#8220;Enable desktop composition&#8221;.</p>
<p>^_^</p>
<p>&#160;</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Breaking news, C# 4.0 finally catches up to Classic VB!]]></title>
<link>http://dev42.wordpress.com/2009/11/09/breaking-news-c-4-0-finally-catches-up-to-classic-vb/</link>
<pubDate>Mon, 09 Nov 2009 17:43:04 +0000</pubDate>
<dc:creator>dev42</dc:creator>
<guid>http://dev42.wordpress.com/2009/11/09/breaking-news-c-4-0-finally-catches-up-to-classic-vb/</guid>
<description><![CDATA[This bit of nostalgic humour will be lost on n00b developers, or anyone lucky enough to have missed ]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>This bit of nostalgic humour will be lost on n00b developers, or anyone lucky enough to have missed out on developing in VB6 (or older&#8211;I think these features were introduced in VB4 or 5, but can&#8217;t recall for sure).</p>
<p><strong><a href="http://cherupally.blogspot.com/2009/11/c-40-new-features-named-and-optional.html">C# has finally decided to embrace optional parameters and named arguments!</a></strong></p>
<p>That&#8217;s right.  It <em>only </em>took 4 versions to catch up to what you were doing well before the .NET days.  Oh well, better late than never!</p>
<p>Of course, you could at least partially work around this in C# 3.0 and older by putting the method implementation in the most verbose signature version of your method and creating any number of overloads needed.</p>
<p>Using the example from the blog posting linked above (please read it before continuing), you&#8217;d create:</p>
<p>//main method with all the parameters and full implementation<br />
public void SomeMethod(int a, int b, int c)<br />
{<br />
/* put the actual implementation here */<br />
}</p>
<p>//overload to omit the <strong>c</strong> parameter and default to 100<br />
public void SomeMethod(int a, int b)<br />
{<br />
SomeMethod(a, b, 100);<br />
}</p>
<p>//overload to omit the <strong>b </strong>and <strong>c </strong>parameters and use the defaults 50 and 100, respectively<br />
public void SomeMethod(int a)<br />
{<br />
SomeMethod(a, 50, 100);<br />
}</p>
<p>However, if we then want an overload that omits the <strong>b</strong> parameter only, we run into trouble.  If we try this:</p>
<p>public void SomeMethod(int a, int c)<br />
{<br />
SomeMethod(a, 50, 100);<br />
}</p>
<p>We would end up with a compile error, since the signature of this overload would be the same as the first overload I declared above, namely:</p>
<p>public void SomeMethod(int, int)</p>
<p>If a, b, and c were of different datatypes, we could declare any combination of parameters, but this example of all int&#8217;s does demonstrate the weakness of this approach, and why the new <a href="http://cherupally.blogspot.com/2009/11/c-40-new-features-named-and-optional.html">optional parameters and named arguments</a> is so exciting!</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Visual Basic Renk Kodu Üreticisi]]></title>
<link>http://muratfe.wordpress.com/2009/11/04/visual-basic-renk-kodu-ureticisi/</link>
<pubDate>Wed, 04 Nov 2009 09:03:40 +0000</pubDate>
<dc:creator>muratfe</dc:creator>
<guid>http://muratfe.wordpress.com/2009/11/04/visual-basic-renk-kodu-ureticisi/</guid>
<description><![CDATA[Visual Basic 6.0&#8242;da kullanabilecek renk kodları üreten küçük bir programcıktır. İndirme Linki:]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Visual Basic 6.0&#8242;da kullanabilecek renk kodları üreten küçük bir programcıktır.</p>
<p>İndirme Linki:<br />
<a href="http://www.box.net/shared/t8ldpv5p2o">İndirmek için Tıklayın&#8230;</a></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[VB 6 Coding Style]]></title>
<link>http://nasrulfatoni.wordpress.com/2009/11/02/vb-6-coding-style/</link>
<pubDate>Mon, 02 Nov 2009 01:53:24 +0000</pubDate>
<dc:creator>Arul</dc:creator>
<guid>http://nasrulfatoni.wordpress.com/2009/11/02/vb-6-coding-style/</guid>
<description><![CDATA[In general, it&#8217;s more important to have some coding styles than to use a particular set of rul]]></description>
<content:encoded><![CDATA[In general, it&#8217;s more important to have some coding styles than to use a particular set of rul]]></content:encoded>
</item>
<item>
<title><![CDATA[Python - Mini tutorial para VB programmers!]]></title>
<link>http://chevitarese.wordpress.com/2009/10/26/python-mini-tutorial-para-vb-programmers/</link>
<pubDate>Mon, 26 Oct 2009 14:54:18 +0000</pubDate>
<dc:creator>fchevitarese</dc:creator>
<guid>http://chevitarese.wordpress.com/2009/10/26/python-mini-tutorial-para-vb-programmers/</guid>
<description><![CDATA[Olá!! Hoje, procurando um meio de fazer com que uma aplicação em VB6 chame um script Python (Eu não ]]></description>
<content:encoded><![CDATA[Olá!! Hoje, procurando um meio de fazer com que uma aplicação em VB6 chame um script Python (Eu não ]]></content:encoded>
</item>
<item>
<title><![CDATA[DLL Injection dengan Visual Basic]]></title>
<link>http://dotexe.unnes.ac.id/2009/10/23/dll-injection-dengan-visual-basic/</link>
<pubDate>Fri, 23 Oct 2009 15:00:02 +0000</pubDate>
<dc:creator>kulinet</dc:creator>
<guid>http://dotexe.unnes.ac.id/2009/10/23/dll-injection-dengan-visual-basic/</guid>
<description><![CDATA[intipadi.com &#8211; berikut adalah source code DLL injection dengan visual basic, silakan gunakan d]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p><strong>intipadi.com &#8211; </strong>berikut adalah source code DLL injection dengan visual basic, silakan gunakan dan aplikasikan sesuai kebutuhan. <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Download source via Ziddu di:<br />
<em>http://ziddu.com/download/7039852/source-dll-injection-dotexe-intipadi.txt.html</em><br />
<!--more--></p>
<hr />
Upload file anda di Ziddu.com, setiap aksi download file anda akan dibayar! <a href="http://www.ziddu.com/register.php?referralid=(yU+qA(h{">Daftar disini</a></p>
<hr />
berikut source codenya:</p>
<pre><code>Private Type MODULEENTRY32
    dwSize As Long
    th32ModuleID As Long
    th32ProcessID As Long
    GlblcntUsage As Long
    ProccntUsage As Long
    modBaseAddr As Long
    modBaseSize As Long
    hModule As Long
    szModule As String * 256
    szExePath As String * 260
End Type
Private Const TH32CS_SNAPMODULE As Long = &#38;H8
Private Const PAGE_READWRITE As Long = &#38;H4
Private Const MEM_RELEASE As Long = &#38;H8000
Private Const MEM_COMMIT As Long = &#38;H1000
Private Const STANDARD_RIGHTS_REQUIRED As Long = &#38;HF0000
Private Const SYNCHRONIZE As Long = &#38;H100000
Private Const PROCESS_ALL_ACCESS As Long = (STANDARD_RIGHTS_REQUIRED Or SYNCHRONIZE Or &#38;HFFF)
Private Const INFINITE As Long = &#38;HFFFFFF

Private Declare Function VirtualAllocEx Lib "kernel32" (ByVal hProcess As Long, ByVal lpAddress As Long, ByVal dwSize As Long, ByVal flAllocationType As Long, ByVal flProtect As Long) As Long
Private Declare Function VirtualFreeEx Lib "kernel32" (ByVal hProcess As Long, lpAddress As Any, ByVal dwSize As Long, ByVal dwFreeType As Long) As Long
Private Declare Function CreateRemoteThread Lib "kernel32" (ByVal hProcess As Long, lpThreadAttributes As Any, ByVal dwStackSize As Long, lpStartAddress As Long, lpParameter As Any, ByVal dwCreationFlags As Long, lpThreadId As Long) As Long
Private Declare Function OpenProcess Lib "kernel32" (ByVal dwDesiredAccess As Long, ByVal bInheritHandle As Long, ByVal dwProcessId As Long) As Long
Private Declare Function WriteProcessMemory Lib "kernel32" (ByVal hProcess As Long, lpBaseAddress As Any, lpBuffer As Any, ByVal nSize As Long, lpNumberOfBytesWritten As Long) As Long
Private Declare Function GetModuleHandle Lib "kernel32" Alias "GetModuleHandleA" (ByVal lpModuleName As String) As Long
Private Declare Function GetProcAddress Lib "kernel32" (ByVal hModule As Long, ByVal lpProcName As String) As Long
Private Declare Function WaitForSingleObject Lib "kernel32" (ByVal hHandle As Long, ByVal dwMilliseconds As Long) As Long
Private Declare Function CloseHandle Lib "kernel32" (ByVal hObject As Long) As Long
Private Declare Function FreeLibrary Lib "kernel32.dll" (ByVal hLibModule As Long) As Long
Private Declare Function CreateToolhelp32Snapshot Lib "kernel32" (ByVal lFlags As Long, ByVal lProcessID As Long) As Long
Private Declare Function Module32First Lib "kernel32" (ByVal hSnapshot As Long, uProcess As MODULEENTRY32) As Long
Private Declare Function Module32Next Lib "kernel32" (ByVal hSnapshot As Long, uProcess As MODULEENTRY32) As Long
Public Function Inject_Dll(Strdll As String, StrProcID As String)
Dim LoadlibAdr As Long, RemThread As Long, LngModule As Long, LngProcess As Long, LngBytes As Long, LngThreadID As Long
On Error GoTo ErrTrap
    LngProcess = OpenProcess(PROCESS_ALL_ACCESS, False, CLng(StrProcID))
    LoadlibAdr = GetProcAddress(GetModuleHandle("kernel32.dll"), "LoadLibraryA")
    LngModule = VirtualAllocEx(LngProcess, 0, Len(Strdll), MEM_COMMIT, PAGE_READWRITE)
    WriteProcessMemory LngProcess, ByVal LngModule, ByVal Strdll, Len(Strdll), LngBytes
    RemThread = CreateRemoteThread(LngProcess, ByVal 0, 0, ByVal LoadlibAdr, ByVal LngModule, 0, LngThreadID)
    WaitForSingleObject RemThread, INFINITE
    CloseHandle LngProcess
    CloseHandle RemThread
    Injection.injector.Enabled = False
    End
    MsgBox "dll Sucussfuly Injection", vbInformation, "Sucsses"
    Exit Function
ErrTrap:
    MsgBox "dll UnInjection Error", vbCritical, "dll UnInjection Error"
End Function

Public Function UnInject_Dll(Strdll As String, StrProcID As String)
Dim MODE32 As MODULEENTRY32, LngBaseAddr As Long, RetVal As Long, LngCT32S As Long, LngProcess As Long, FreelibAdr As Long, RemThread As Long
On Error GoTo ErrTrap
    LngCT32S = CreateToolhelp32Snapshot(TH32CS_SNAPMODULE, CLng(StrProcID))
    MODE32.dwSize = Len(MODE32)
    RetVal = Module32First(LngCT32S, MODE32)
    Do While RetVal
        If Strdll = Left(MODE32.szExePath, InStr(MODE32.szExePath, Chr(0)) - 1) Then
            LngBaseAddr = MODE32.modBaseAddr
        End If
        RetVal = Module32Next(LngCT32S, MODE32)
    Loop
    CloseHandle LngCT32S
    LngProcess = OpenProcess(PROCESS_ALL_ACCESS, False, CLng(StrProcID))
    FreelibAdr = GetProcAddress(GetModuleHandle("Kernel32.dll"), "FreeLibrary")
    RemThread = CreateRemoteThread(LngProcess, ByVal 0, 0, ByVal FreelibAdr, ByVal LngBaseAddr, 0, 0)
    CloseHandle LngProcess
    CloseHandle RemThread

    MsgBox "dll Sucussfuly Injection", vbInformation, "Sucsses"
    Exit Function
ErrTrap:
    MsgBox "dll UnInjection Error", vbCritical, "dll UnInjection Error"
End Function</code></pre>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Connesione DB SQL Server (solo lettura):]]></title>
<link>http://gabbo70.wordpress.com/2009/10/20/connesione-db-sql-server-solo-lettura-2/</link>
<pubDate>Tue, 20 Oct 2009 08:33:38 +0000</pubDate>
<dc:creator>gabbo70</dc:creator>
<guid>http://gabbo70.wordpress.com/2009/10/20/connesione-db-sql-server-solo-lettura-2/</guid>
<description><![CDATA[Set conn = New ADODB.Connection conn.ConnectionString = &#8220;Driver={SQL Server};Server=NomeServer]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p style="text-align:left;">Set conn = New ADODB.Connection<br />
conn.ConnectionString = &#8220;Driver={SQL Server};Server=NomeServer;Database=NomeDB;Uid=User;Pwd=pass;&#8221;<br />
conn.Open<br />
&#8216;Activo = True</p>
<p style="text-align:left;">Dim rs As ADODB.Recordset<br />
Dim strQry As String<br />
strQry = &#8220;SELECT * FROM NomeTab&#8221;</p>
<p style="text-align:left;">Set rs = New ADODB.Recordset</p>
<p style="text-align:left;">rs.Open strQry, conn, adOpenStatic, adLockReadOnly, adCmdText</p>
<p style="text-align:left;">If rs.EOF Then<br />
MsgBox &#8220;ciao&#8221;<br />
Else<br />
MsgBox rs(&#8220;cliente&#8221;)</p>
<p style="text-align:left;">End If</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Connesione DB SQL Server (solo lettura):]]></title>
<link>http://gabbo70.wordpress.com/2009/10/20/connesione-db-sql-server-solo-lettura/</link>
<pubDate>Tue, 20 Oct 2009 08:32:51 +0000</pubDate>
<dc:creator>gabbo70</dc:creator>
<guid>http://gabbo70.wordpress.com/2009/10/20/connesione-db-sql-server-solo-lettura/</guid>
<description><![CDATA[Set conn = New ADODB.Connection conn.ConnectionString = &#8220;Driver={SQL Server};Server=NomeServer]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p style="text-align:left;">Set conn = New ADODB.Connection<br />
conn.ConnectionString = &#8220;Driver={SQL Server};Server=NomeServer;Database=NomeDB;Uid=User;Pwd=pass;&#8221;<br />
conn.Open<br />
&#8216;Activo = True</p>
<p style="text-align:left;">Dim rs As ADODB.Recordset<br />
Dim strQry As String<br />
strQry = &#8220;SELECT * FROM NomeTab&#8221;</p>
<p style="text-align:left;">Set rs = New ADODB.Recordset</p>
<p style="text-align:left;">rs.Open strQry, conn, adOpenStatic, adLockReadOnly, adCmdText</p>
<p style="text-align:left;">If rs.EOF Then<br />
MsgBox &#8220;ciao&#8221;<br />
Else<br />
MsgBox rs(&#8220;cliente&#8221;)</p>
<p style="text-align:left;">End If</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Connessione db Access (let+scrit)]]></title>
<link>http://gabbo70.wordpress.com/2009/10/20/connessione-db-access-letscrit/</link>
<pubDate>Tue, 20 Oct 2009 08:20:02 +0000</pubDate>
<dc:creator>gabbo70</dc:creator>
<guid>http://gabbo70.wordpress.com/2009/10/20/connessione-db-access-letscrit/</guid>
<description><![CDATA[Dim con1 As New ADODB.Connection Conn.Open &#8220;Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\pr]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Dim con1 As New ADODB.Connection</p>
<p>Conn.Open &#8220;Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\prova\db1.mdb&#8221;<br />
Dim rs As New ADODB.Recordset</p>
<p>rs.Open &#8220;SELECT * FROM prova1&#8243;, con1, 1, 2</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Crea datareader con access e popola treeview]]></title>
<link>http://gabbo70.wordpress.com/2009/10/20/crea-datareader-con-access-e-popola-treeview/</link>
<pubDate>Tue, 20 Oct 2009 08:17:49 +0000</pubDate>
<dc:creator>gabbo70</dc:creator>
<guid>http://gabbo70.wordpress.com/2009/10/20/crea-datareader-con-access-e-popola-treeview/</guid>
<description><![CDATA[crea datareader con access e popola treeview: Dim conStr As String = &#8220;Provider=Microsoft.JET.O]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><div>crea datareader con access e popola treeview:</div>
<p>Dim conStr As String = &#8220;Provider=Microsoft.JET.OLEDB.4.0;data source=c:\prova\prova.mdb&#8221;</p>
<p>Dim strSQL As String = &#8220;SELECT * FROM Tabella1&#8243;</p>
<p>Dim conn As OleDb.OleDbConnection = New OleDb.OleDbConnection(conStr)</p>
<p>Dim objCommand As OleDb.OleDbCommand<br />
objCommand = New OleDb.OleDbCommand(strSQL, conn)</p>
<p>conn.Open()</p>
<p>Dim rdr As OleDb.OleDbDataReader = objCommand.ExecuteReader</p>
<p>tw1.Nodes.Clear()<br />
Do While rdr.Read<br />
Dim nd As New TreeNode<br />
nd.Text = rdr.Item(&#8220;aaa&#8221;)</p>
<p>nd.Tag = rdr.Item(&#8220;bbb&#8221;)</p>
<p>tw1.Nodes.Add(nd)<br />
Loop<br />
&#8216;cleanup</p>
<p>rdr.Close()</p>
<p>&#8216;cmd.Dispose()</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[ខ្មែរយូនីកូដប្រើជាមួយ VB6 បានទេ ?]]></title>
<link>http://ikhmer2.wordpress.com/2009/10/19/%e1%9e%81%e1%9f%92%e1%9e%98%e1%9f%82%e1%9e%9a%e1%9e%99%e1%9e%bc%e1%9e%93%e1%9e%b8%e1%9e%80%e1%9e%bc%e1%9e%8a%e1%9e%94%e1%9f%92%e1%9e%9a%e1%9e%be%e1%9e%87%e1%9e%b6%e1%9e%98%e1%9e%bd%e1%9e%99-vb6/</link>
<pubDate>Tue, 20 Oct 2009 00:25:03 +0000</pubDate>
<dc:creator>ម៉ន</dc:creator>
<guid>http://ikhmer2.wordpress.com/2009/10/19/%e1%9e%81%e1%9f%92%e1%9e%98%e1%9f%82%e1%9e%9a%e1%9e%99%e1%9e%bc%e1%9e%93%e1%9e%b8%e1%9e%80%e1%9e%bc%e1%9e%8a%e1%9e%94%e1%9f%92%e1%9e%9a%e1%9e%be%e1%9e%87%e1%9e%b6%e1%9e%98%e1%9e%bd%e1%9e%99-vb6/</guid>
<description><![CDATA[ខ្ញុំមានតែ Visual Basic 6.0 តើខ្ញុំអាចសរសេរកូដជាមួយនឹងខ្មែរយូនីកូដបានទេ ? បើខ្ញុំចង់ប្រើ ខ្មែរយូនីកូ]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>ខ្ញុំមានតែ Visual Basic 6.0 តើខ្ញុំអាចសរសេរកូដជាមួយនឹងខ្មែរយូនីកូដបានទេ ?</p>
<p><img class="alignnone size-full wp-image-983" title="khmer_unicode_vb6" src="http://ikhmer2.wordpress.com/files/2009/10/khmer_unicode_vb61.jpg" alt="khmer_unicode_vb6" width="487" height="241" /></p>
<p>បើខ្ញុំចង់ប្រើ ខ្មែរយូនីកូដ ដើម្បីអោយឈ្មោះជា String សម្រាប់ Label1, Text1,<br />
Command1 ដែលមានដូចជារូបខាងលើនេះ តើខ្ញុំត្រូវធ្វើអ្វីខ្លះ ?</p>
<p>បើបងប្អូនណាដឹង សូមជួយប្រាប់ផង ។</p>
<p>សូមអរគុណ !</p>
<p> </p>
<p>មើលទៅដូចជាយ៉ាប់ណាស់ តែខ្ញុំបានរកឃើញ Visual Basic 2008 Express<br />
ដែលអាចយកមកប្រើដោយអត់អស់លុយពី Microsoft ។</p>
<p><img class="alignnone size-full wp-image-986" title="khmer_unicode_vb2008a" src="http://ikhmer2.wordpress.com/files/2009/10/khmer_unicode_vb2008a.jpg" alt="khmer_unicode_vb2008a" width="315" height="406" /></p>
<p><img class="alignnone size-full wp-image-987" title="khmer_unicode_vb2008b" src="http://ikhmer2.wordpress.com/files/2009/10/khmer_unicode_vb2008b.jpg" alt="khmer_unicode_vb2008b" width="328" height="238" /></p>
<p>ដូច្នេះខ្ញុំត្រូវរៀនប្រើ Visual Basic 2008 Express វិញ ហើយប្រហែល<br />
ជាឈប់ប្រើ Visual Basic 6.0 ហើយតាមមើល ។</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[HTML Ipsum Presents]]></title>
<link>http://betageekers.wordpress.com/2009/10/16/html-ipsum-presents/</link>
<pubDate>Fri, 16 Oct 2009 01:35:46 +0000</pubDate>
<dc:creator>janhell</dc:creator>
<guid>http://betageekers.wordpress.com/2009/10/16/html-ipsum-presents/</guid>
<description><![CDATA[Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Vestib]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Vestibulum tortor quam, feugiat vitae, ultricies eget, tempor sit amet, ante. Donec eu libero sit amet quam egestas semper. Aenean ultricies mi vitae est. Mauris placerat eleifend leo. Quisque sit amet est et sapien ullamcorper pharetra. Vestibulum erat wisi, condimentum sed, commodo vitae, ornare sit amet, wisi. Aenean fermentum, elit eget tincidunt condimentum, eros ipsum rutrum orci, sagittis tempus lacus enim ac dui. Donec non enim in turpis pulvinar facilisis. Ut felis. Praesent dapibus, neque id cursus faucibus, tortor neque egestas augue, eu vulputate magna eros eu erat. Aliquam erat volutpat. Nam dui mi, tincidunt quis, accumsan porttitor, facilisis luctus, metus.</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Tip &amp; Trik VB.6]]></title>
<link>http://sagala78.wordpress.com/2009/10/13/tip-trik-vb-6/</link>
<pubDate>Tue, 13 Oct 2009 03:07:33 +0000</pubDate>
<dc:creator>ariantonius</dc:creator>
<guid>http://sagala78.wordpress.com/2009/10/13/tip-trik-vb-6/</guid>
<description><![CDATA[pada kesempatan ini saya akan bercerita, menuangkan ilmu untuk berbagi dengan teman-teman, yaitu ten]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>pada kesempatan ini saya akan bercerita, menuangkan ilmu untuk berbagi dengan teman-teman, yaitu tentang tip &#38; trik php query b.base</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[.NET Framework Using Visual Basic]]></title>
<link>http://enggtech.wordpress.com/2009/10/11/net-framework-using-visual-basic/</link>
<pubDate>Sun, 11 Oct 2009 19:53:14 +0000</pubDate>
<dc:creator>Visitor Blogs</dc:creator>
<guid>http://enggtech.wordpress.com/2009/10/11/net-framework-using-visual-basic/</guid>
<description><![CDATA[Application Configuration * .NET Configuration System * Configuration API * Config Files Security * ]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>Application Configuration</p>
<p>* .NET Configuration System<br />
* Configuration API<br />
* Config Files Security<br />
* Standard Config Sections<br />
* Demo: Application Settings<br />
* Read AppSettings<br />
* View Raw AppSettings XML<br />
* Demo: Connection Strings<br />
* Conn. Strings in web.config<br />
* Read Connection Strings<br />
* Retrieve all Conn. Strings<br />
* Other Standard Sections<br />
* Demo: Impersonate Setting</p>
<p>Manipulate Config Files</p>
<p>* Demo: Write to AppSettings<br />
* Add a Setting<br />
* Remove a Setting<br />
* Standard Config. Settings<br />
* Toggle Debugging in Setting<br />
* Read machine.config<br />
* Read Root web.config<br />
* Read App. web.config<br />
* Config Files in WinForms<br />
* Section Groups / Props.<br />
* Read machineKey section<br />
* Section Collections<br />
* Read from Pages Section<br />
* Enumerating Section Groups</p>
<p>Custom Config Sections</p>
<p>* Create a Custom Section<br />
* Write Section Handlers<br />
* Declarative Section Handler<br />
* Link Class in web.config<br />
* Test Declarative Header<br />
* Programmatic Section Handler<br />
* Property Validators<br />
* Test Programmatic Header<br />
* More Complex Sect. Header<br />
* View Class Code</p>
<p>Custom Config Providers</p>
<p>* View SettingsProvider<br />
* User vs App. Scope<br />
* Use SettingsProvider<br />
* userSettings Section<br />
* SQL Settings Provider<br />
* View AssemblyInfo<br />
* GetPropertyValues Code<br />
* GetValue Code<br />
* SetPropertyValues Code<br />
* Scope Support Functions<br />
* Test the Provider</p>
<p>Installation Components</p>
<p>* Overview<br />
* Pre-Defined Components<br />
* Create a Windows App<br />
* Add an Installer<br />
* View Installer Code<br />
* Add Code to Form<br />
* Create Deployment Project<br />
* Build the App<br />
* Test the App</p>
<p>Custom Install Components</p>
<p>* Overview<br />
* Create Install Comp.<br />
* InstallHappened Event<br />
* Database events Code<br />
* Run Installation Code<br />
* InstallUtil.exe Tool<br />
* AssemblyInstaller Class<br />
* View Installer Code</p>
<p>Configuring Assemblies</p>
<p>* Specify Framework Version<br />
* Specific Assembly Versions<br />
* Concurrent Garbage Coll.<br />
* Register Remote Objects<br />
* .NET Configuration Tool</p>
<p>Event Logs</p>
<p>* Overview: Tools<br />
* WinForms Components<br />
* Use an Event Log<br />
* Security Note About Logs<br />
* EventLog Class<br />
* Create an Event Log<br />
* Setup Form Code<br />
* Create/Delete Logs Code<br />
* Read From an Event Log<br />
* Log Changed Code<br />
* Get Log Entries Code<br />
* Write to an Event Log<br />
* WriteEvent Method</p>
<p>Processes</p>
<p>* Run ProcessManager Demo<br />
* List Running Processes<br />
* List Process&#8221;s Modules<br />
* Retrieve Current Process<br />
* Starting a New Process</p>
<p>Application Performance</p>
<p>* Run Perf. Counter App<br />
* Windows Perf. Tool<br />
* Create Perf. Counters<br />
* Using Perf. Counters</p>
<p>Debugging</p>
<p>* Run Debugging Sample<br />
* View Debug Sample Code<br />
* Overview: Stack Trace<br />
* Examine Stack Trace<br />
* Stack Trace Code<br />
* Debugger Attributes<br />
* BrowsableAttribute<br />
* DisplayAttribute<br />
* HiddenAttribute<br />
* StepThroughAttribute<br />
* TypeProxyAttribute<br />
* VisualizerAttribute<br />
* View Text Visualizer<br />
* Impl. Custom Visualizer</p>
<p>Tracing</p>
<p>* Run Tracing Demo<br />
* Trace Sources<br />
* Trace Switches<br />
* Trace Listeners<br />
* Filtering Traces<br />
* Configuring Traces</p>
<p>Instrumenting</p>
<p>* The Debug Class<br />
* Write Debug Information<br />
* Debug Fail<br />
* Assertions<br />
* The Trace Class<br />
* Debug vs Trace<br />
* Trace Switching<br />
* Correlating Traces<br />
* Enable Debugging/Tracing</p>
<p>Management</p>
<p>* WMI Object Browser<br />
* Interesting WMI Classes<br />
* Access Windows Resources<br />
* Enum. Physical Drives<br />
* Enum. Logical Disks<br />
* Enum. Network Adapters<br />
* Enum. System Processes<br />
* Enum. Paused Services</p>
<p>Events</p>
<p>* WMI Query<br />
* Sample App. Code<br />
* Synchronous WMI Events<br />
* Asynchronous WMI Events</p>
<p>Code Access Security</p>
<p>* Overview: CAS<br />
* CAS: Evidence<br />
* CAS: Security Policy<br />
* CAS: Code Groups<br />
* CAS: Permissions<br />
* Sample Runtime Sec. Pol.<br />
* CAS / Windows Security<br />
* Configuring CAS<br />
* Framework Config. Tool<br />
* Default Permission Sets<br />
* Create Permission Set<br />
* Analyze Assemblies<br />
* Reset All Sec. Pols.</p>
<p>Assemblies</p>
<p>* Use CAS in Assemblies<br />
* Testing CAS<br />
* VS Project Sec. Settings<br />
* Set Security on Assemblies<br />
* Add RequestMinimum<br />
* Add RequestOptional<br />
* Add UIPermission<br />
* Edit File/UI Permissions<br />
* Add RequestRefuse</p>
<p>Methods</p>
<p>* Use CAS with Methods<br />
* Method Permission Requests<br />
* Setup Method Example<br />
* Declarative Demand<br />
* Imperative Demand<br />
* Declarative Demand Fail<br />
* Imperative Demand Fail<br />
* Declarative Link Demand<br />
* Declarative Assert<br />
* Imperative Assert<br />
* Declarative Permit Only<br />
* Imperative Permit Only<br />
* Declarative Inheritance<br />
* Analyze Permissions<br />
* Safe Error Handling<br />
* Custom Permission Sets<br />
* Named Permission Sets</p>
<p>Windows Identity</p>
<p>* Authentication<br />
* .NET Role-Based Security<br />
* IIdentity / IPrincipal<br />
* Identities / Principals<br />
* Windows Identity<br />
* Use Windows Identity<br />
* Windows Principal<br />
* Use Windows Principal<br />
* Group Membership<br />
* Use Group Membership<br />
* Impersonation<br />
* Use Impersonation<br />
* Create an IIS Directory</p>
<p>Security Demands</p>
<p>* PrincipalPermission Class<br />
* Declarative Demands<br />
* Imperative Demands<br />
* Generic/Custom Identities<br />
* Generic Identities/Principals<br />
* Use Generic Objects<br />
* Custom Identities/Principals</p>
<p>Windows Security</p>
<p>* DACLs / SACLs<br />
* Effective Permissions<br />
* Explore DACLs / SACLs<br />
* Access Control<br />
* Classes/Enumerations<br />
* Access/Audit Rule Classes</p>
<p>Access Audit Rules</p>
<p>* Run Access Control Demo<br />
* View Access Control Code<br />
* Retrieve Security Info<br />
* Retrieve Access Rules<br />
* Retrieve Audit Rules<br />
* Get Rules for Directories<br />
* Get Rules for Registry<br />
* Change Access Rules<br />
* Allowing Access<br />
* Denying Access<br />
* Removing Access<br />
* Change Audit Rules<br />
* AuditFlags.None value</p>
<p>Low Level Security</p>
<p>* ACL / ACE Classes<br />
* CommonSecurityDescriptor<br />
* PropagationFlags Enums.<br />
* Maintain Security Settings<br />
* Ownership<br />
* Securing New Objects<br />
* Access Object Ownership<br />
* Inheritance/Propagation<br />
* SetAccessRuleProtection</p>
<p>Cryptography</p>
<p>* Cryptography Overview<br />
* Protection Issues<br />
* Algorithms<br />
* Block Padding<br />
* Cryptography in .NET<br />
* Hashing Data<br />
* Hashing Algorithms<br />
* Algorithm Characteristics<br />
* .NET Framework Classes<br />
* Cryptography Demo<br />
* Hashing Code<br />
* Hashing a File<br />
* Message Integrity<br />
* Compare Hash Codes<br />
* CryptoConfig Object<br />
* Key Hashing Algorithm</p>
<p>Encryption</p>
<p>* Symmetric Key Encryption<br />
* Algorithms<br />
* Algorithm Characteristics<br />
* Symmetric in .NET<br />
* Symmetric Key Demo<br />
* Symmetric Key Code<br />
* Encrypt/DeCrypt Data<br />
* Random Number<br />
* Asymmetric Key Encryption<br />
* RSA<br />
* Asymmetric in .NET<br />
* Asymmetric Key Demo<br />
* Asymmetric Key Code</p>
<p>Digital Sigs and DPAPI</p>
<p>* Digital Signature Hierarchy<br />
* Digital Signature Demo<br />
* Digital Signature Code<br />
* DSACryptoServiceProvider<br />
* Data Protection API (DPAPI)<br />
* The DPAPI Process<br />
* Store Options<br />
* ProtectedMemory Class<br />
* ProtectedMemory Demo<br />
* ProtectData Option</p>
<p>Handle Concurrency Errors</p>
<p>* Handle Optimistic Concurrency<br />
* Use Update Criteria<br />
* Demo: Run Scripts from VS<br />
* Update w/Stored Procs<br />
* Check Validations<br />
* Perform the Update<br />
* @@ERROR/@@ROWCOUNT<br />
* Handle Concurrency Errors<br />
* Try/Catch in SQL Server 2K5<br />
* SQL Server 2K5 Scripts<br />
* Data Updates with ADO.NET<br />
* Page_Load/Refresh Data<br />
* Code for Updating Changes<br />
* Code for Cancel Changes<br />
* RowUpdated event<br />
* Code for Concurrency Errors</p>
<p>Asynchronous Processing</p>
<p>* Async Query Execution<br />
* Async Completion Signaling<br />
* Asynchronous Processing<br />
* View Connection String<br />
* View SQL Strings<br />
* SqlCommands/WaitHandles<br />
* Setup Asynchronous Loop<br />
* Setup the Results Textbox</p>
<p>Development Enhancements</p>
<p>* Enumerate SQL Servers<br />
* MARS Scenarios and Caveats<br />
* Mutliple Active Result Sets<br />
* Demo: Max DataTypes<br />
* Retrieve Max DataTypes<br />
* Retrieve Text Values<br />
* Enable Query Notifications<br />
* Rules for Query Notifications<br />
* Code: Query Notifications<br />
* View Global.asax</p>
<p>Advanced.NET Framework 2.0 Using VB 2005</p>
<p>Multithreaded Applications</p>
<p>* Creating Multithreaded Apps<br />
* Thread Class<br />
* Join() Method<br />
* ThreadStart Delegates<br />
* Demo: Creating a Thread<br />
* Demo: Synchronizing Threads<br />
* Demo: Starting a Thread<br />
* ThreadPool Class<br />
* Reverse DNS Lookups<br />
* Demo: ThreadPool Class<br />
* Timer Class<br />
* Demo: Timer Class<br />
* Modifying the UI from a Thread<br />
* Calling the Invoke Method<br />
* Background Worker<br />
* Calling an Async. Method<br />
* Demo: Asynchronous Call<br />
* ThreadState Enumeration<br />
* ThreadPriority Enumeration<br />
* Demo: Thread State<br />
* Demo: Thread Priority</p>
<p>Locking</p>
<p>* Deadlock<br />
* Race Conditions<br />
* Demo: Race Condition<br />
* Demo: Deadlock<br />
* Thread Safe Code and Locking<br />
* Monitor Class<br />
* SyncLock Statement<br />
* Interlocked Class<br />
* ReaderWriterLock Class<br />
* Demo: Non-Thread Safe<br />
* Demo: Monitor Lock<br />
* Demo: SyncLock<br />
* Demo: Interlocked Class<br />
* Demo: ReaderWriterLock 1<br />
* Demo: ReaderWriterLock 2<br />
* WaitHandle Class<br />
* AutoResetEvent Class<br />
* ManualResetEvent Class<br />
* Demo: AutoResetEvent<br />
* Demo: ManualResetEvent</p>
<p>Synchronization</p>
<p>* Mutex Class<br />
* Semaphore Class<br />
* Demo: Local Mutex<br />
* Demo: Global Mutex<br />
* Demo: Semaphore<br />
* RegisterWaitForSingleObject<br />
* Demo: Wait<br />
* ExecutionContext Class<br />
* Demo: ExecutionContext<br />
* Demo: ExecutionContext(Run)</p>
<p>Encoding</p>
<p>* Using Encoding<br />
* ASCII Encoding<br />
* ANSI Code Pages<br />
* Unicode<br />
* UTF-8<br />
* UTF-16<br />
* Other Encoding Schemes<br />
* Demo: Enumerating Encodings<br />
* Demo: Encoding a String<br />
* Demo: File Writing/Reading<br />
* Demo: Fallback<br />
* Demo: Exception Fallback</p>
<p>Using Culture Information</p>
<p>* Types of Cultures<br />
* Invariant Culture<br />
* Neutral Cultures<br />
* Specific Cultures<br />
* CultureInfo Class<br />
* CurrentUI/Current (Culture)<br />
* Getting the List of Cultures<br />
* Demo: Retrieving Cultures<br />
* Culture Names<br />
* Language Code<br />
* Country or Region Code<br />
* Using a CultureInfo Object<br />
* Assigning CultureInfo<br />
* Parsing Dates<br />
* Parsing Numbers<br />
* Demo: Parsing Dates<br />
* Demo: Parsing Numbers</p>
<p>Creating Windows Services</p>
<p>* Overview<br />
* Examples of Win Services<br />
* Creating a Windows Service<br />
* Visual Studio Settings<br />
* Starting a Visual Studio Project<br />
* Naming the Service<br />
* OnStart and OnStop Methods<br />
* Installing the Service<br />
* Service Process Installer<br />
* Service Installer<br />
* Starting the Service<br />
* Stopping the Service<br />
* Windows Event Logs<br />
* Registry Entries<br />
* Creating the Setup Program<br />
* Uninstalling the Service<br />
* Adding Functionality<br />
* Testing the Service</p>
<p>Debugging Windows Services</p>
<p>* Creating a Test Harness<br />
* Running the Test Harness<br />
* Debug the Running Service<br />
* ServiceController Comp.<br />
* Demanding Permissions<br />
* Override Other Service Methods<br />
* Two-way Communication</p>
<p>Application Domains</p>
<p>* Overview<br />
* Creating an App. Domain<br />
* Unloading a Domain<br />
* Configuring a Domain<br />
* Retrieving Setup Information<br />
* Loading Assemblies<br />
* Demo: Student Projects<br />
* Demo: Domain Security<br />
* Demo: Evidence<br />
* Demo: Evidence on Domain</p>
<p>.NET Framework Class Library</p>
<p>* Overview<br />
* System Types<br />
* Value Type / Ref. Types<br />
* Built-in Value Types<br />
* Number Types<br />
* Demo: Numeric Types<br />
* ToString Method<br />
* Demo: Numeric ToString<br />
* Instance vs. Shared<br />
* Nullable Type<br />
* Numeric Shared Methods<br />
* Demo: Nullable Value<br />
* Dates and Times<br />
* Demo: Date/Time Properties<br />
* Demo: Date/Time ToString<br />
* Date/Time Instance Methods<br />
* Date/Time Shared Methods</p>
<p>Reference Types</p>
<p>* Copy a Value Type<br />
* Copy a Reference Type<br />
* Value vs Ref. Types<br />
* Work with Strings<br />
* Overview: Stringbuilder<br />
* String ReferenceTypes<br />
* Demo: String Formatting<br />
* Demo: Concatenate Strings<br />
* Demo: Stringbuilder<br />
* Overview: Arrays<br />
* Array Methods<br />
* Iterating Arrays<br />
* Demo: Work with Arrays<br />
* Handling Exceptions<br />
* Demo: Work w/Exceptions</p>
<p>Custom Types</p>
<p>* Overview: Custom Types<br />
* Value vs Ref. Type<br />
* Constants<br />
* Enumerations<br />
* Demo: Constants<br />
* Demo: Enumerations<br />
* More Complex Enum.<br />
* Structures<br />
* Demo: Simple Structure<br />
* Constructors<br />
* Properties<br />
* Add Methods to Structure<br />
* Property vs Method<br />
* More Complex Structure</p>
<p>Advanced Custom Types</p>
<p>* Using Attributes<br />
* Built-in Attributes<br />
* TypeForwardedToAttribute<br />
* Build Your Own Attributes<br />
* Implement Interfaces<br />
* Use IComparable<br />
* Use IDisposable<br />
* Use IConvertible<br />
* Use ICloneable<br />
* Use IEquatable<br />
* Use IFormattable<br />
* Create Custom Interfaces<br />
* View Custom interface</p>
<p>Delegates and Events</p>
<p>* Overview: Delegates<br />
* Overview: Events<br />
* Custom Event Handler<br />
* Generic Classes<br />
* Create Generic Types<br />
* Consume Generic Type<br />
* Add Constraints<br />
* Demo: Generic Class<br />
* Demo: Constraints</p>
<p>Simple Collections</p>
<p>* System.Collections<br />
* Overview: ArrayList<br />
* Demo: ArrayList<br />
* Common Functionality<br />
* IEnumerable Interface<br />
* IEnumerator Interface<br />
* ICollection Interface<br />
* IList Interface<br />
* CollectionBase Class<br />
* ReadOnlyCollectionBase<br />
* Implement Custom Collection<br />
* Sequential Lists<br />
* Queue Class<br />
* Stack Class<br />
* Demo: Queue<br />
* Demo: Stack</p>
<p>Dictionaries and Sorting</p>
<p>* Dictionary Classes<br />
* Handle Key/Value Pairs<br />
* Hashtable<br />
* GetEnumerator<br />
* Demo: Hashtable<br />
* Demo: DictionaryEntry<br />
* Determine Duplicates<br />
* IEqualityComparer<br />
* Demo: IEqualityComparer<br />
* SortedList<br />
* Demo: SortedList<br />
* Sort Collections<br />
* Comparer Class<br />
* Implement ICompare<br />
* SortedList Collection<br />
* Custom Sort Collection</p>
<p>Generic Collections</p>
<p>* Generic Collections<br />
* Generic List Class<br />
* Use Predicates<br />
* Demo: Array List Issues<br />
* Demo: Generic List<br />
* Demo: Iterate Generic List<br />
* Demo: Find / Predicates</p>
<p>Additional Generic Collections</p>
<p>* Generic Dictionary Class<br />
* Sorted Classes<br />
* Queues and Stacks<br />
* Generic Queue Class<br />
* Generic Stack Class<br />
* Demo: Generic Dictionary<br />
* Demo: Generic SortedList<br />
* Demo: Generic Queue<br />
* Demo: Generic Stack<br />
* Generic LinkedList<br />
* LinkedList Methods<br />
* LinkedListNode Class<br />
* Demo: Generic LinkedList<br />
* Demo: LinkedListNode</p>
<p>Specialized Collections</p>
<p>* Generic Collection Classes<br />
* Generic Collection Enums<br />
* Demo: Gen Collections<br />
* Specialized Collections<br />
* StringCollection<br />
* StringDictionary<br />
* NameValueCollection<br />
* Demo: StringCollection<br />
* Demo: StringDictionary<br />
* Demo: NameValueCollection<br />
* BitArray<br />
* BitVector32<br />
* Demo: BitArray<br />
* Demo: BitVector32</p>
<p>Isolated Storage (IS)</p>
<p>* Overview: IS<br />
* IsolatedStorageFile Class<br />
* Retrieve IS for Machine<br />
* Work with Folders<br />
* Demo: Work with Folders<br />
* Work with Files<br />
* IS File Permission Attrib<br />
* Demo: Work with Files<br />
* Access from Other Apps<br />
* Demo: Create/Store Files<br />
* Demo: Open/Read Files<br />
* Compress Files in IS<br />
* CompressDecompressIS Class<br />
* Demo: Compress File in IS</p>
<p>Debug JavaScript</p>
<p>* Overview: Debug JavaScript<br />
* Demo: Debug Sample<br />
* View Page Source<br />
* Attach to IE Process<br />
* Types of Debuggers<br />
* VS Script Explorer<br />
* Test Breakpoint<br />
* Overview: Visualizers<br />
* Quick Watch Window<br />
* Add a Watch<br />
* ScriptManager ScriptMode<br />
* Examine ScriptResource File<br />
* Debug JavaScript File<br />
* Sys.Stringbuilder<br />
* Debug in Framework</p>
<p>Debug in Internet Explorer</p>
<p>* Overview: Debug in IE<br />
* Demo: Debug in IE<br />
* Nikhil&#8221;s Web Dev Helper<br />
* HTTP Logging<br />
* Deserialize to JSON<br />
* Script Console<br />
* Sys.Debug<br />
* Create Debug Scripts<br />
* trace v. traceDump<br />
* Script Class Browser</p>
<p>Retrieve Data</p>
<p>* Overview: ADO.NET<br />
* ADO.NET Classes<br />
* OleDb vs SqlClient<br />
* ADO.NET Architecture<br />
* DataTable Object<br />
* Demo: Fill DataTable<br />
* Connect to Data Source<br />
* Set Up Connections<br />
* Make the Connections<br />
* The using statement<br />
* Exception Handling<br />
* Overview: Commands<br />
* Overview: Command Object<br />
* Overview: Read Data<br />
* Demo: SqlDataReader</p>
<p>.NET Configuration</p>
<p>* Benefits<br />
* Navigate Hierarchy<br />
* machine.config<br />
* Demo: config files<br />
* Root web.config<br />
* Application web.config<br />
* Use location Element<br />
* Config File Elements<br />
* system.web Element<br />
* Demo: web.config<br />
* appSettings Section<br />
* connectionStrings Section<br />
* system.web Section<br />
* ASP.NET Configuration Tools<br />
* Config Security Features<br />
* Web Site Admin Tool<br />
* Demo: Web Site Admin Tool<br />
* Unified Error Handling</p>
<p>Security Trimming</p>
<p>* Demo: Navigation Security<br />
* Authentication/Authorization<br />
* Website Admin Tool<br />
* Configure Authentication<br />
* Enable User Login<br />
* Test the Application<br />
* Set Up Roles<br />
* Override Automatic Trimming</p>
<p>Caching</p>
<p>* Improvements<br />
* Types of Caching in ASP.NET<br />
* Page Output Caching<br />
* Caching Static Pages<br />
* Demo: Caching Example Pgs<br />
* Caching Multiple Pg Versions<br />
* Demo: Multiple Page Versions<br />
* Varying by Form Parameters<br />
* Demo: Form Parameters<br />
* Varying by HTTP Header<br />
* Demo: Vary by HTTP Header<br />
* Varying by Browser<br />
* Demo: Varying by Browser<br />
* Varying by a Custom String<br />
* Demo: Varying by String</p>
<p>Page Fragments</p>
<p>* Demo: Cache Page Fragments<br />
* Using VaryByControl<br />
* Demo: Using VaryByControl<br />
* Multiple Versions of a Control<br />
* Demo: Multiple Ctrl Versions<br />
* Post-Cache Substitution<br />
* Call a Method to Insert HTML<br />
* Demo: WriteSubstitution<br />
* Caching Configuration<br />
* Demo: Caching Configuration</p>
<p>Web Parts</p>
<p>* Web Parts in Action<br />
* Demo: Personalization<br />
* Design and Edit Modes<br />
* Demo: Design and Edit Modes<br />
* Catalog Mode<br />
* Demo: Catalog Mode<br />
* Connect Mode<br />
* Demo: Connect Mode<br />
* Custom Properties and Menus<br />
* Demo: Properties and Menus<br />
* Web Part Server Controls<br />
* WebPartManager<br />
* ProxyWebPartManager<br />
* WebPartZone<br />
* CatalogZone<br />
* EditorZone<br />
* ConnectionsZone</p>
<p>Coding Web Parts</p>
<p>* Page&#8221;s Display Mode<br />
* Demo: Control Display Mode<br />
* Demo: Personalization Scope<br />
* Resetting Personalization Data<br />
* Demo: Reset Data<br />
* Coding Connections<br />
* Demo: Web Part Connections<br />
* User Controls as Web Parts<br />
* Demo: User Controls<br />
* Custom Controls as Web Parts<br />
* Demo: Custom Controls</p>
<p>Security Models</p>
<p>* X.509 Certificates<br />
* Client Side<br />
* Server Side<br />
* Policy Assertion<br />
* Client Configuration<br />
* Demo: Create Certificates<br />
* Run Certificate Manager<br />
* X.509 Cert. Settings<br />
* Service Configuration<br />
* Demo: Service Config<br />
* Kerberos<br />
* Kerberos Client Config.<br />
* Demo: Client Config<br />
* Kerberos Service Config.<br />
* Demo: Server Config<br />
* Set up Web Service</p>
<p>Exploring MTOM</p>
<p>* Overview: MTOM<br />
* MTOM Structure<br />
* MTOM uses XOP<br />
* Use / Non-use of MTOM<br />
* Non-use of MTOM<br />
* Use of MTOM<br />
* MTOM and WSE3.0</p>
<p>Ntier Data</p>
<p>* Overview: 2-Tier<br />
* Overview: N-Tier<br />
* Demo: Split DataSet Code<br />
* Create N-Tier App<br />
* Define 2-Tier DataSource<br />
* DataSet Project Property<br />
* Create Multi-Tier Form<br />
* Define N-Tier DataSource<br />
* Test N-Tier App<br />
* LINQ to SQL<br />
* LINQ to SQL Mappings<br />
* DataContext Class<br />
* Entity Classes<br />
* Object Relational Designer<br />
* Demo: LINQ to SQL<br />
* View Designer Class<br />
* Create Front End<br />
* Configure Behavior<br />
* Specify Mappings</p>
<p>Code Access Security</p>
<p>* Overview of Security<br />
* Evidence<br />
* Security Zones<br />
* Security Policy<br />
* Security Policy Levels<br />
* Code Groups<br />
* Permission Sets<br />
* Security Policy Overview<br />
* Demo: Code Access Security<br />
* CLR Grants Permissions<br />
* Configuring Security Policy<br />
* Demo: Granting Permissions</p>
<p>Permissions</p>
<p>* Checking For Permissions<br />
* Code Access Permissions<br />
* Using Declarative Syntax<br />
* Demo: Check Permissions</p>
<p>Role Based Security</p>
<p>* Overview<br />
* Identity<br />
* WindowsIdentity Class<br />
* GenericIdentity Class<br />
* Principal<br />
* WindowsPrincipal Class<br />
* GenericPrincipal Class<br />
* PrincipalPermission<br />
* Demo: Role-based Security</p>
<p><strong>Windows Communication Framework (WCF) services that support Representational State Transfer (REST) and syndication</strong></p>
<p>Intro To WCF</p>
<p>* History<br />
* Service Orientation<br />
* Principles<br />
* What&#8217;s Wrong<br />
* WCF to the Rescue<br />
* WCF vs Web Services<br />
* WCF<br />
* Demo: WCF Service</p>
<p>Building Blocks</p>
<p>* WCF Building Blocks<br />
* Service<br />
* Service Contracts<br />
* Data Contracts<br />
* Endpoints<br />
* Bindings<br />
* Provided Bindings<br />
* Demo: WCF Service<br />
* Hosting Service<br />
* Client to Call Service</p>
<p>IIS And Self Hosting</p>
<p>* Hosting a WCF Service<br />
* Hosting Options<br />
* Which Should You Use?<br />
* Demo: Hosting Using IIS<br />
* Self Host WCF Services<br />
* Demo: Self Hosting<br />
* Multiple Endpoints<br />
* Two Services</p>
<p>Sessions</p>
<p>* Sessions<br />
* Bindings and Sessions<br />
* Instancing<br />
* PerCall Instancing<br />
* PerSession Instancing<br />
* Single Instancing<br />
* Demo: TCP Sessions<br />
* Demo: HTTP Sessions<br />
* Demo: Instancing<br />
* Control Sessions<br />
* Demo: Control Sessions<br />
* Sessions and Concurrency<br />
* Single Thread Concurrency<br />
* Reentrant Thread Concurrency<br />
* Multiple Threads Concurrency<br />
* Demo Scenario<br />
* Demo: Concurrency</p>
<p>Transactions</p>
<p>* Transactions<br />
* Enable Transactions in WCF<br />
* Starting a Transaction<br />
* Demo: Configure Transactions<br />
* Transactions and Sessions<br />
* Demo: Transactions-Sessions</p>
<p>Security Basics</p>
<p>* Security Concepts<br />
* WCF Security Mechanisms<br />
* Transport Level Security<br />
* Message Level Security<br />
* Pros and Cons<br />
* Default Security Settings<br />
* Demo: Encrypting Messages</p>
<p>Authentication</p>
<p>* Overview<br />
* Transport Security Credentials<br />
* Message Security Credentials<br />
* Default Security Settings<br />
* Scenario<br />
* Demo: Passing Credentials<br />
* Demo: User Authentication<br />
* Scenario<br />
* Demo: Basic Authentication<br />
* ASP Membership Provider<br />
* Configure Web Site Security<br />
* Configure Binding and Service<br />
* Demo: ASP.NET Membership</p>
<p>Authorization</p>
<p>* Overview<br />
* Role Based Authorization<br />
* Role Based Security<br />
* Identity<br />
* Principal<br />
* WindowsPrincipal Class<br />
* GenericPrincipal Class<br />
* PrincipalPermission<br />
* Demo: Using Identities<br />
* Demo: Generic Indentity<br />
* ASP.Net Role Provider<br />
* Configure Web Site Security<br />
* Configure Binding and Service<br />
* Demo: ASP.NET Role Provider</p>
<p><strong>Windows Workflow Foundation</strong><br />
Workflow Services</p>
<p>* Windows Workflow Foundation<br />
* Sequential Workflow<br />
* State Machine Workflow<br />
* Workflow Services<br />
* ReceiveActivity<br />
* Authoring Styles<br />
* Hosting Workflow Services<br />
* Demo: Workflow Service<br />
* Demo: Hosting Workflow IIS</p>
<p>Stateful Workflow Services</p>
<p>* Overview<br />
* Using the State Activity<br />
* Using the SetState Activity<br />
* Using the EventDriven Activity<br />
* Workflow Persistence<br />
* SQL Persistence Service<br />
* Demo:StateMachine Workflow<br />
* Demo: Setup Persistence</p>
<p>Restful Services</p>
<p>* REST<br />
* REST Principles<br />
* Why use REST vs SOAP?<br />
* REST and WCF<br />
* WebGet Attribute<br />
* WebHttpBinding<br />
* WebServiceHost<br />
* Demo: RESTful Service<br />
* Uploading Data</p>
<p>Syndication</p>
<p>* Overview<br />
* Syndication and WCF<br />
* Syndication Classes<br />
* Demo: Syndication Feed<br />
* Demo: ATOM Feed<br />
* Demo: ATOM and RSS</p>
<p>Workflow Foundation</p>
<p>* Overview: WF<br />
* What App Types Benefit<br />
* What is Needed for WF<br />
* Verify Pieces are Installed<br />
* Two Types of Workflows<br />
* Base Classes<br />
* Workflow Activities<br />
* Create First Workflow<br />
* Workflow Activities<br />
* Add Code Activities<br />
* Test the Workflow<br />
* Debug Your Workflow<br />
* Workflow Architecture<br />
* Types of Host Apps<br />
* Workflow Startup Code<br />
* Two Ways to Create Workflows<br />
* Create Workflow w/XOML</p>
<p>Windows Form Host</p>
<p>* Hosting Workflow<br />
* Pass Parameters<br />
* Demo: Create Host App<br />
* Demo: Create Workflow<br />
* Add Amount/ItemName<br />
* Set Delay Activity Behavior<br />
* Add IfElse Activity Condition<br />
* Add Code Activities<br />
* Create the Form<br />
* WorkFlowCompleted<br />
* Create Parameters Coll.<br />
* Test the Workflow</p>
<p>CAG / Replicator</p>
<p>* Overview: CAG<br />
* Demo: CAG Activity<br />
* Replicator Activity<br />
* Demo: Replicator Activity<br />
* Using a Custom Activity<br />
* Demo: Custom Activity</p>
<p>Chaining</p>
<p>* Forward Chaining<br />
* Demo: Forward Chaining<br />
* Attribute Chaining<br />
* Explicit Chaining<br />
* Demo: Attribute Chaining<br />
* Demo: Explicit Chaining<br />
* Control Chaining<br />
* Demo: Halt Chaining</p>
<p>Call Host Methods</p>
<p>* Overview: Host Methods<br />
* Cross-Threading Issues<br />
* Important Specifics<br />
* Create a Console Host<br />
* Create Shared Interface<br />
* Create the Workflow<br />
* Interface Implementation<br />
* ExternalDataExchangeService<br />
* Add Windows App Host<br />
* Review: Host Methods</p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Exceptions, Error Handlers: How to Guides: .NET Reference]]></title>
<link>http://enggtech.wordpress.com/2009/10/11/exceptions-error-handlers-how-to-guides-net-reference/</link>
<pubDate>Sun, 11 Oct 2009 19:34:44 +0000</pubDate>
<dc:creator>Visitor Blogs</dc:creator>
<guid>http://enggtech.wordpress.com/2009/10/11/exceptions-error-handlers-how-to-guides-net-reference/</guid>
<description><![CDATA[Exception Class (System). Visual Basic (Declaration) &lt;SerializableAttribute&gt; _ &lt;ComVisibleA]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p><span><span id="ctl00_MTCS_main_ctl222_ctl00_ctl00"></p>
<div id="ctl00_MTCS_main_ctl222_ctl00_ctl00_VisualBasicDeclaration" class="libCScode">
<div class="CodeSnippetTitleBar">
<div class="CodeDisplayLanguage"><strong><a href="http://msdn.microsoft.com/en-us/library/system.exception.aspx">Exception Class (System)</a></strong>.</div>
<div class="CodeDisplayLanguage"></div>
<div class="CodeDisplayLanguage">Visual Basic (Declaration)</div>
</div>
<div style="background-color:#dddddd;" dir="ltr">
<pre class="libCScode" style="white-space:pre-wrap;">&#60;SerializableAttribute&#62; _
&#60;ComVisibleAttribute(<span style="color:blue;">True</span>)&#62; _
&#60;ClassInterfaceAttribute(ClassInterfaceType.None)&#62; _
<span style="color:blue;">Public</span> <span style="color:blue;">Class</span> Exception _
    <span style="color:blue;">Implements</span> ISerializable, _Exception</pre>
</div>
</div>
<p></span></span></p>
<p><span>A <span><span class="input">catch</span></span> block handles an exception of type <span><span class="input">T</span></span> if the type filter of the catch block specifies <span><span class="input">T</span></span> or any type that <span><span class="input">T</span></span> derives from. The system stops searching after it finds the first <span><span class="input">catch</span></span> block that handles the exception. For this reason, in application code, a <span><span class="input">catch</span></span> block that handles a type must be specified before a <span><span class="input">catch</span></span> block that handles its <strong>base types</strong>, as demonstrated in the example that follows this section. A catch block that handles <strong><span><span class="input">System.Exception</span></span></strong> is specified last.</span></p>
<p><span>If none of the <span><span class="input">catch</span></span> blocks associated with the current <span><span class="input">try</span></span> block handle the exception, and the current <span><span class="input">try</span></span> block is nested within other <span><span class="input">try</span></span> blocks in the current call, the <span><span class="input">catch</span></span> blocks associated with the next enclosing <span><span class="input">try</span></span> block are searched. If no <span><span class="input">catch</span></span> block for the exception is found, the system searches previous nesting levels in the current call. If no <span><span class="input">catch</span></span> block for the exception is found in the current call, the exception is passed up the call stack, and the previous stack frame is searched for a <span><span class="input">catch</span></span> block that handles the exception. The search of the call stack continues until the exception is handled or until <strong>no more frames exist on the call stack</strong></span></p>
<p><span></p>
<h3 class="subHeading">Exception Type Categories</h3>
<div class="subsection">
<p>Two categories of exceptions exist under the base class <span><span class="selflink">Exception</span></span>:</p>
<ul>
<li>The pre-defined common language runtime exception classes derived from <span><a id="ctl00_MTCS_main_ctl223_ctl00_ctl02" href="http://msdn.microsoft.com/en-us/library/system.systemexception.aspx">SystemException</a></span>.</li>
<li>The user-defined application exception classes derived from <span><a id="ctl00_MTCS_main_ctl223_ctl00_ctl03" href="http://msdn.microsoft.com/en-us/library/system.applicationexception.aspx">ApplicationException</a></span>.</li>
</ul>
<p><span></p>
<h3 class="subHeading">Performance Considerations</h3>
<div class="subsection">
<p>A significant amount of system resources and execution time are used when you throw or handle an exception. Throw exceptions only to handle truly extraordinary conditions, not to handle predictable events or flow control. For example, your application can reasonably throw an exception if a method argument is invalid because you expect to call your method with valid parameters. An invalid method argument means something extraordinary has occurred. Conversely, do not throw an exception if user input is invalid because you can expect users to occasionally enter invalid data. In such a case, provide a retry mechanism so users can enter valid input.</p>
<p>Throw exceptions only for extraordinary conditions, then catch exceptions in a general purpose exception handler that applies to the majority of your application, not a handler that applies to a specific exception. The rationale for this approach is that most errors can be handled by validation and error handling code in proximity to the error; no exception needs to be thrown or caught. The general purpose exception handler catches truly unexpected exceptions thrown anywhere in the application.</p>
<p>In addition, do not throw an exception when a return code is sufficient; do not convert a return code to an exception; and do not routinely catch an exception, ignore it, then continue processing.</p>
<p><span> </span><span></p>
<div class="MTPS_CollapsibleRegion">
<div class="CollapseRegionLink"><!-- ApplyClick with current id --> <strong> Thread Safety </strong></div>
<div class="MTPS_CollapsibleSection" style="display:block;"><a id="threadSafetyToggle"></a>Any public <span class="input">static</span> (<span class="input">Shared</span> in Visual Basic)  members of this type are thread safe. Any instance members are not guaranteed to be thread safe.</div>
</div>
<p></span></div>
<p></span></div>
<p></span></p>
<p><a href="http://msdn.microsoft.com/en-us/library/system.exception.aspx"><br />
</a></p>
<p><strong><a href="http://msdn.microsoft.com/en-us/library/5b2yeyab.aspx">Handling and Throwing Exceptions</a></strong>.</p>
<p>Allows exceptions to be thrown across process and even machine boundaries.</p>
<p>Exceptions offer several advantages over other methods of error notification, such as return codes. Failures do not go unnoticed. Invalid values do not continue to propagate through the system. You do not have to check return codes. Exception-handling code can be easily added to increase program reliability. Finally, the runtime&#8217;s exception handling is faster than Windows-based C++ error handling.</p>
<p>Because execution threads routinely traverse managed and unmanaged blocks of code, the runtime can throw or catch exceptions in either managed or unmanaged code. Unmanaged code can include both <strong>C++-style SEH </strong>Exceptions and <strong>COM-based</strong> HRESULTS.</p>
<p><strong><a href="http://msdn.microsoft.com/en-us/library/system.applicationexception.aspx">ApplicationException Class (System)</a></strong></p>
<p>If you are designing an application that needs to create its own exceptions, you are advised to derive custom exceptions from the Exception class. It was originally thought that custom exceptions should derive from the ApplicationException class; however in practice this has not been found to add significant value.</p>
<p><strong><a href="http://msdn.microsoft.com/en-us/library/system.systemexception.aspx">SystemException Class (System)</a></strong></p>
<p>SystemException does not provide information as to the cause of the Exception. In most scenarios, instances of this class should not be thrown. In cases where this class is instantiated, a human-readable message describing the error should be passed to the constructor.</p>
<p>SystemException is thrown by the common language runtime when errors occur that are nonfatal and recoverable by user programs. These errors result from failed runtime check (such as an array out-of-bound error), and can occur during the execution of any method. SystemException adds no new functionality to Exception.</p>
<p><strong><a href="http://msdn.microsoft.com/en-us/library/6kzk0czb.aspx">Exceptions Overview</a>.</strong></p>
<p><span>The runtime uses an exception handling model based on exception objects and protected blocks of code. An <span><a id="ctl00_MTCS_main_ctl19_ctl00_ctl00" href="http://msdn.microsoft.com/en-us/library/system.exception.aspx">Exception</a></span> object is created to represent an exception when it occurs.</p>
<p>The runtime creates an exception information table for each executable. Each method of the executable has an associated array of exception handling information (which can be empty) in the exception information table. Each entry in the array describes a protected block of code, any exception filters associated with that code, and any exception handlers (catch statements). This exception table is extremely efficient and there is no performance penalty in processor time or in memory use when an exception does not occur. You use resources only when an exception occurs.</p>
<p>The exception information table represents four types of exception handlers for protected blocks:</p>
<ul>
<li>A finally handler that executes whenever the block exits, whether that occurs by normal control flow or by an unhandled exception.</li>
<li>A fault handler that must execute if an exception occurs, but does not execute on completion of normal control flow.</li>
<li>A type-filtered handler that handles any exception of a specified class or any of its derived classes.</li>
<li>A user-filtered handler that runs user-specified code to determine whether the exception should be handled by the associated handler or should be passed to the next protected block.</li>
</ul>
<p>Each language implements these exception handlers according to its specifications. For example, Visual Basic 2005 provides access to the user-filtered handler through a variable comparison (using the <strong>When</strong> keyword) in the catch statement; C# does not implement the user-filtered handler.</p>
<p></span></p>
<p>Note that the order of exception handlers is important: the innermost exception handler is evaluated first. Also note that exception handlers can access the local variables and local memory of the routine that catches the exception, but any intermediate values at the time the exception is thrown are lost.</p>
<p>If no match occurs in the current method, the runtime searches each caller of the current method, and it continues this path all the way up the stack. If no caller has a match, the runtime allows the debugger to access the exception. If the debugger does not attach to the exception, the runtime raises the <span><a id="ctl00_MTCS_main_ctl19_ctl00_ctl01" href="http://msdn.microsoft.com/en-us/library/system.appdomain.unhandledexception.aspx">UnhandledException</a></span> event. If there are no listeners for the <strong>UnhandledException</strong> event, the runtime dumps a stack trace and ends the program.</p>
<p><strong><a href="http://msdn.microsoft.com/en-us/library/5whzhsd2.aspx">Exception Class and Properties</a></strong>.</p>
<p>The <span><a id="ctl00_MTCS_main_ctl01" href="http://msdn.microsoft.com/en-us/library/system.exception.aspx">Exception</a></span> class is the base class from which exceptions inherit. Most exception objects are instances of some derived class of<strong> Exception</strong>, but you can throw any object that derives from the <span><a id="ctl00_MTCS_main_ctl02" href="http://msdn.microsoft.com/en-us/library/system.object.aspx">Object</a></span> class as an exception.</p>
<blockquote><p>Note that not all languages support throwing and catching objects that do not derive from <strong>Exception</strong>. In almost all cases, it is recommended to throw and catch only <strong>Exception</strong> objects.</p></blockquote>
<p><span> </span><strong>The <span><a id="ctl00_MTCS_main_ctl04" href="http://msdn.microsoft.com/en-us/library/system.exception.innerexception.aspx">InnerException</a></span> property. </strong></p>
<p>This property can be used to create and preserve a series of exceptions during exception handling. You can use this property to create a new exception that contains previously caught exceptions. The original exception can be captured by the second exception in the <strong>InnerException</strong> property, allowing code that handles the second exception to examine the additional information.</p>
<ul>
<li>For example, suppose you have a method that reads a file and formats the data. The code tries to read from the file, but a FileException is thrown. The method catches the FileException and throws a BadFormatException. In this case, the FileException can be saved in the <strong>InnerException</strong> property of the BadFormatException.</li>
</ul>
<p>To improve the caller&#8217;s ability to determine the reason an exception is thrown, it is sometimes desirable for a method to catch an exception thrown by a helper routine and then throw an exception more indicative of the error that has occurred. A new and more meaningful exception can be created, where the inner exception reference can be set to the original exception. This more meaningful exception can then be thrown to the caller. Note that with this functionality, you can create a series of linked exceptions that ends with the exception that was thrown first.</p>
<blockquote><p>It is not recommended that you catch a <strong>SystemException</strong>, nor is it good programming practice to throw a <strong>SystemException</strong> in your application.</p></blockquote>
<p>The most severe exceptions — those thrown by the runtime or in nonrecoverable conditions — include</p>
<ul>
<li><span><a id="ctl00_MTCS_main_ctl07" href="http://msdn.microsoft.com/en-us/library/system.executionengineexception.aspx">ExecutionEngineException</a></span>,</li>
<li><span><a id="ctl00_MTCS_main_ctl08" href="http://msdn.microsoft.com/en-us/library/system.stackoverflowexception.aspx">StackOverflowException</a></span>,</li>
<li><span><a id="ctl00_MTCS_main_ctl09" href="http://msdn.microsoft.com/en-us/library/system.outofmemoryexception.aspx">OutOfMemoryException</a></span>.</li>
</ul>
<p>Interoperation exceptions derive from <strong>SystemException</strong> and are further extended by <span><a id="ctl00_MTCS_main_ctl10" href="http://msdn.microsoft.com/en-us/library/system.runtime.interopservices.externalexception.aspx">ExternalException</a></span>.</p>
<ul>
<li><span><a id="ctl00_MTCS_main_ctl11" href="http://msdn.microsoft.com/en-us/library/system.runtime.interopservices.comexception.aspx">COMException</a></span> is the exception thrown during COM interop operations and derives from <strong>ExternalException</strong>.</li>
<li><span><a id="ctl00_MTCS_main_ctl12" href="http://msdn.microsoft.com/en-us/library/system.componentmodel.win32exception.aspx">Win32Exception</a></span></li>
<li><span><a id="ctl00_MTCS_main_ctl13" href="http://msdn.microsoft.com/en-us/library/system.runtime.interopservices.sehexception.aspx">SEHException</a></span></li>
</ul>
<p><strong><a href="http://msdn.microsoft.com/en-us/library/seyhszts.aspx">Best Practices for Handling Exceptions</a></strong>.</p>
<p>1. Know when to set up a try/catch block. For example, you can programmatically check for a condition that is likely to occur without using exception handling. In other situations, using exception handling to catch an error condition is appropriate.</p>
<p>The method you choose depends on how often you expect the event to occur. If the event is truly exceptional and is an error (such as an unexpected end-of-file), using exception handling is better because less code is executed in the normal case. If the event happens routinely, using the programmatic method to check for errors is better. In this case, if an exception occurs, the exception will take longer to handle.</p>
<ul>
<li>When creating <strong>user-defined exceptions,</strong> you must ensure that the metadata for the exceptions is available to code executing remotely, including when exceptions occur across application domains. For example, suppose <strong>Application Domain </strong>A creates Application Domain B, which executes code that throws an exception. For Application Domain A to properly catch and handle the exception, it must be able to find the assembly containing the exception thrown by Application Domain B. If Application Domain B throws an exception that is contained in an assembly under its application base, but not under Application Domain A&#8217;s application base, Application Domain A will not be able to find the exception and the common language runtime will throw a <span><a id="ctl00_MTCS_main_ctl07" href="http://msdn.microsoft.com/en-us/library/system.io.filenotfoundexception.aspx">FileNotFoundException</a></span>. To avoid this situation, you can deploy the assembly containing the exception information in two ways:
<ul>
<li>Put the assembly into a common application base shared by both application domains
<p>- or -</li>
<li>If the domains do not share a common application base, sign the assembly containing the exception information with a <strong>strong name </strong>and deploy the assembly into the <strong>global assembly cache</strong>.</li>
</ul>
</li>
</ul>
<ul>
<li>In C# and C++, use at least the <strong>three common constructors</strong> when creating your own exception classes. For an example, see <span><a id="ctl00_MTCS_main_ctl08" href="http://msdn.microsoft.com/en-us/library/87cdya3t.aspx">How to: Create User-Defined Exceptions</a></span>.</li>
</ul>
<div class="CollapseRegionLink"><strong><span id="ctl00_MTCS_main_ctl18_ctl00_ctl00"> Visual Basic </span>Example </strong></div>
<div class="MTPS_CollapsibleSection" style="display:block;"><a id="exampleToggle"></a><span id="ctl00_MTCS_main_ctl18_ctl00_ctl00"></p>
<div id="ctl00_MTCS_main_ctl18_ctl00_ctl00_VisualBasic" class="libCScode">
<div class="CodeSnippetTitleBar">
<div class="CodeDisplayLanguage"></div>
</div>
<div style="background-color:#dddddd;" dir="ltr">
<pre class="libCScode" style="white-space:pre-wrap;"><span style="color:blue;">Imports</span> System
<span style="color:blue;">Public</span> <span style="color:blue;">Class</span> EmployeeListNotFoundException
   <span style="color:blue;">Inherits</span> Exception

   <span style="color:blue;">Public</span> <span style="color:blue;">Sub</span> <span style="color:blue;">New</span>()
   <span style="color:blue;">End</span> <span style="color:blue;">Sub</span> <span style="color:green;">'New</span>

   <span style="color:blue;">Public</span> <span style="color:blue;">Sub</span> <span style="color:blue;">New</span>(message <span style="color:blue;">As</span> <span style="color:blue;">String</span>)
      <span style="color:blue;">MyBase</span>.New(message)
   <span style="color:blue;">End</span> <span style="color:blue;">Sub</span> <span style="color:green;">'New</span>

   <span style="color:blue;">Public</span> <span style="color:blue;">Sub</span> <span style="color:blue;">New</span>(message <span style="color:blue;">As</span> <span style="color:blue;">String</span>, inner <span style="color:blue;">As</span> Exception)
      <span style="color:blue;">MyBase</span>.New(message, inner)
   <span style="color:blue;">End</span> <span style="color:blue;">Sub</span> <span style="color:green;">'New</span>
<span style="color:blue;">End</span> <span style="color:blue;">Class</span> <span style="color:green;">'EmployeeListNotFoundException</span></pre>
</div>
</div>
<p></span></div>
<ul>
<li>Return null for extremely common error cases. For example, <span><a id="ctl00_MTCS_main_ctl12" href="http://msdn.microsoft.com/en-us/library/system.io.file.open.aspx">Open</a></span> returns <span><span class="input">null</span></span> if the file is not found, but throws an exception if the file is locked.</li>
<li>Design classes so that an exception is <strong>never thrown in normal </strong>use. For example, a <span><a id="ctl00_MTCS_main_ctl13" href="http://msdn.microsoft.com/en-us/library/system.io.filestream.aspx">FileStream</a></span> class exposes another way of determining whether the end of the file has been reached. This avoids the exception that is thrown if you read past the end of the file.</li>
<li>Use <strong>exception builder methods</strong>. It is common for a class to throw the same exception from different places in its implementation. To avoid excessive code, use helper methods that create the exception and return it. For example:
<p><span id="ctl00_MTCS_main_ctl18"></p>
<div id="ctl00_MTCS_main_ctl18_VisualBasic" class="libCScode">
<div class="CodeSnippetTitleBar">
<div class="CodeDisplayLanguage"><strong>Visual Basic </strong></div>
</div>
<div style="background-color:#dddddd;" dir="ltr">
<pre class="libCScode" style="white-space:pre-wrap;"><span style="color:blue;">Class</span> File
   <span style="color:blue;">Private</span> fileName <span style="color:blue;">As</span> <span style="color:blue;">String</span>

   <span style="color:blue;">Public</span> <span style="color:blue;">Function</span> Read(bytes <span style="color:blue;">As</span> <span style="color:blue;">Integer</span>) <span style="color:blue;">As</span> <span style="color:blue;">Byte</span>()
      <span style="color:blue;">If</span> <span style="color:blue;">Not</span> ReadFile(handle, bytes) <span style="color:blue;">Then</span>
         <span style="color:blue;">Throw</span> NewFileIOException()
      <span style="color:blue;">End</span> <span style="color:blue;">If</span>
   <span style="color:blue;">End</span> <span style="color:blue;">Function</span> <span style="color:green;">'Read</span>

   <span style="color:blue;">Function</span> NewFileIOException() <span style="color:blue;">As</span> FileException
      <span style="color:blue;">Dim</span> description <span style="color:blue;">As</span> <span style="color:blue;">String</span> = __unknown <span style="color:green;">' Build localized string, including fileName.</span>
      <span style="color:blue;">Return</span> <span style="color:blue;">New</span> FileException(description) <span style="color:green;">'</span>
   <span style="color:blue;">End</span> <span style="color:blue;">Function</span> <span style="color:green;">'NewFileIOException</span>
<span style="color:blue;">End</span> <span style="color:blue;">Class</span> <span style="color:green;">'File</span></pre>
</div>
</div>
<p></span></li>
</ul>
<p><a href="http://msdn.microsoft.com/en-us/library/awy7adbx.aspx">Handling COM Interop Exceptions</a>.</p>
<p><strong><a href="http://msdn.microsoft.com/en-us/library/s74yzzb5.aspx">Choosing When to Use Structured and Unstructured Exception Handling</a>.</strong></p>
<p>you might use unstructured exception handling under these circumstances:</p>
<ul>
<li>You are upgrading an application written in an <strong>earlier version </strong>of Visual Basic.</li>
<li>You are developing a preliminary or draft version of an application and you don&#8217;t mind if the program fails to shut down gracefully.</li>
<li>You know in advance <strong>exactly what will cause </strong>the exception.</li>
<li>A deadline is pressing, you need to take shortcuts, and are willing to sacrifice flexibility for speed.</li>
<li>Code is trivial or <strong>so short </strong>that you only need to test the branch of code generating the exception.</li>
<li>You need to use the <strong><span><span class="input">Resume Next</span></span> </strong>statement, which is not supported in structured exception handling.</li>
</ul>
<p><span>The <strong>common language runtime </strong>catches exceptions that are not caught by a catch block. Depending on how the runtime is configured, either a debug dialog box appears, or the program stops executing and a dialog box with exception information appears. For information about debugging, see <a id="ctl00_MTCS_main_ctl16_ctl00_ctl02" href="http://msdn.microsoft.com/en-us/library/7fe0dd2y.aspx">Debugging and Profiling Applications</a>.</span></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[VB.NET Ebook Gratis dalam Bahasa Indonesia]]></title>
<link>http://actualtraining.wordpress.com/2009/10/04/vb-net-ebook-gratis-dalam-bahasa-indonesia/</link>
<pubDate>Sun, 04 Oct 2009 15:00:08 +0000</pubDate>
<dc:creator>Erick Kurniawan</dc:creator>
<guid>http://actualtraining.wordpress.com/2009/10/04/vb-net-ebook-gratis-dalam-bahasa-indonesia/</guid>
<description><![CDATA[Satu bulan yang lalu saya dan teman saya Bapak Rully selesai menulis sebuah buku gratis dalam bahasa]]></description>
<content:encoded><![CDATA[Satu bulan yang lalu saya dan teman saya Bapak Rully selesai menulis sebuah buku gratis dalam bahasa]]></content:encoded>
</item>
<item>
<title><![CDATA[Visual Basics 6 Enterprise]]></title>
<link>http://deadlogical.wordpress.com/2009/10/04/visual-basics-6-enterprise/</link>
<pubDate>Sun, 04 Oct 2009 09:45:07 +0000</pubDate>
<dc:creator>DeadLogical</dc:creator>
<guid>http://deadlogical.wordpress.com/2009/10/04/visual-basics-6-enterprise/</guid>
<description><![CDATA[This is a full VB6 download free of charge, includes cracked keys. http://www.linkmoney.com/link.asp]]></description>
<content:encoded><![CDATA[This is a full VB6 download free of charge, includes cracked keys. http://www.linkmoney.com/link.asp]]></content:encoded>
</item>
<item>
<title><![CDATA[Mengaktifkan Scroll Mouse Pada Datagrid vb6]]></title>
<link>http://marapulagibullu.wordpress.com/2009/09/19/scroll-mouse-vb6/</link>
<pubDate>Sat, 19 Sep 2009 19:27:30 +0000</pubDate>
<dc:creator>Steve Malo</dc:creator>
<guid>http://marapulagibullu.wordpress.com/2009/09/19/scroll-mouse-vb6/</guid>
<description><![CDATA[Setelah sekian lama mencari, akhirnya ktemu jg,&#8230;.. Tulisan ini hanya skedar bwt orng2 yng meng]]></description>
<content:encoded><![CDATA[Setelah sekian lama mencari, akhirnya ktemu jg,&#8230;.. Tulisan ini hanya skedar bwt orng2 yng meng]]></content:encoded>
</item>
<item>
<title><![CDATA[FileSystemObject and ReadLine Limitations]]></title>
<link>http://shepardroad.wordpress.com/2009/09/15/filesystemobject-and-readline-limitations/</link>
<pubDate>Tue, 15 Sep 2009 19:49:43 +0000</pubDate>
<dc:creator>sokmonkey67</dc:creator>
<guid>http://shepardroad.wordpress.com/2009/09/15/filesystemobject-and-readline-limitations/</guid>
<description><![CDATA[After a VBScript was implemented into a file move task that my team&#8217;s application depends upon]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>After a VBScript was implemented into a file move task that my team&#8217;s application depends upon, a limitation of the <a title="FileSystemObject" href="http://msdn2.microsoft.com/en-us/library/z9ty6h50.aspx">FileSystemObject</a> caused data to be lost.&#160; This brought about the realization that care must be taken when using the FSO (FileSystemObject) to perform tasks on fixed-width flat-file data files.&#160; In this case, the ReadLine method was being used to read in each line in such a file and getting the length of the string using the LEN() function. The problem here is that the <a title="ReadLine Method" href="http://msdn2.microsoft.com/en-us/library/h7se9d4f.aspx">ReadLine</a> method reads the entire line <em>up to but not including </em>the newline character.&#160; This causes a significant problem when this length value is used to feed a line of data to a mainframe program which is expecting the count to include the newline character.&#160; This was previously not a problem because the FSO was not previously used to manage information about record lengths in the file.&#160; However, one this change was introduced, this limitation became an issue in our environment. </p>
<p>There are so many related topics that are potential candidates for future posts, such as using VBScript in environments where byte counting is required, or using it to customize enterprise-class COTS applications through a scripting interface, to how such a seemingly minimal change can impact a production environment, etc&#8230;but at the end of the day, as the development landscape and paradigms change, implementing old technology should be done so with care.&#160; Technologies and platforms such as the .NET Framework offer more powerful and robust capabilities which overall far outweigh the simplicity and familiar comfort that the VB6/COM world has given us for years.&#160; </p>
<p>//T </p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[NSIS (Nullsoft Scriptable Install System) and VB6-NSIS Converter]]></title>
<link>http://billhensley.wordpress.com/2009/09/15/nsis-nullsoft-scriptable-install-system-and-vb6-nsis-converter/</link>
<pubDate>Tue, 15 Sep 2009 00:49:27 +0000</pubDate>
<dc:creator>Bill Hensley</dc:creator>
<guid>http://billhensley.wordpress.com/2009/09/15/nsis-nullsoft-scriptable-install-system-and-vb6-nsis-converter/</guid>
<description><![CDATA[I just love Open Source software. I have a number of Visual Basic 6 projects that I use quite often ]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>I just love Open Source software.  I have a number of Visual Basic 6 projects that I use quite often for work and school.  I move them to different computers.</p>
<p>I usually use the VB6 Package and Deployment Wizard to build an install package for these.  However, at least three of these VB6 packages have cratered while trying to get them to install on the target system.  One time, the target system was a computer on the E-4B, and I was trying to help a guy get it to install, with little luck.  The errors being reported were (1) random and not consistent, and (2) cryptic, to say the least.</p>
<p>I can hand-install most any Windoze program with a little patience, but in that case I was 1400 miles away, and it needed to be installed that day!</p>
<p>I searched around on the web and found NSIS.  Just a bit more searching and I found a companion to NSIS that acted as a VB6-NSIS Converter.  The way it works, you run the VB6 Package and Deployment Wizard.  If the installer fails, then run the VB6-NSIS converter, point it at the VB6 &#8220;SETUP.LST&#8221;, and it creates a script for NSIS.  Then run NSIS, point it at the converted script, and it builds a nice setup.exe file.  Burn it to CD or email it to it&#8217;s destination, or copy it to a flash drive, and you are on your way.  </p>
<p>In every case where the built-in VB6 tool at trouble, NSIS/VB6 converter got the job done.  Great stuff.</p>
<p>Almost forgot:</p>
<p><a href="http://nsis.sourceforge.net/Main_Page">http://nsis.sourceforge.net/Main_Page</a></p>
<p><a href="http://nsis.sourceforge.net/VB_Converter">http://nsis.sourceforge.net/VB_Converter</a></p>
</div>]]></content:encoded>
</item>
<item>
<title><![CDATA[Visual WebGui rescues Talex in web enabling its HelpDesk system frontend]]></title>
<link>http://webgui20.wordpress.com/2009/09/13/visual-webgui-rescues-talex-in-web-enabling-its-helpdesk-system-frontend/</link>
<pubDate>Sun, 13 Sep 2009 15:33:07 +0000</pubDate>
<dc:creator>webgui20</dc:creator>
<guid>http://webgui20.wordpress.com/2009/09/13/visual-webgui-rescues-talex-in-web-enabling-its-helpdesk-system-frontend/</guid>
<description><![CDATA[A new Visual WebGui legacy application migration to Web case study is available. Taldesk, Talex Help]]></description>
<content:encoded><![CDATA[A new Visual WebGui legacy application migration to Web case study is available. Taldesk, Talex Help]]></content:encoded>
</item>
<item>
<title><![CDATA[Save your Visual Basic 6.0 applications with the new migration solution]]></title>
<link>http://webgui20.wordpress.com/2009/09/08/save-your-visual-basic-6-0-applications-with-the-new-migration-solution/</link>
<pubDate>Tue, 08 Sep 2009 15:51:36 +0000</pubDate>
<dc:creator>webgui20</dc:creator>
<guid>http://webgui20.wordpress.com/2009/09/08/save-your-visual-basic-6-0-applications-with-the-new-migration-solution/</guid>
<description><![CDATA[Save your Visual Basic 6.0 applications with the new ArtinSoft/Visual WebGui VB 6.0 to Web &amp; Clo]]></description>
<content:encoded><![CDATA[Save your Visual Basic 6.0 applications with the new ArtinSoft/Visual WebGui VB 6.0 to Web &amp; Clo]]></content:encoded>
</item>
<item>
<title><![CDATA[Aplikasi Penjualan (Point Of Sale)]]></title>
<link>http://gudangprogram.wordpress.com/2009/09/06/aplikasi-penjualan-point-of-sale/</link>
<pubDate>Sun, 06 Sep 2009 16:36:00 +0000</pubDate>
<dc:creator>gudangprogram</dc:creator>
<guid>http://gudangprogram.wordpress.com/2009/09/06/aplikasi-penjualan-point-of-sale/</guid>
<description><![CDATA[&lt;img src=gambar/vb-penjualan.jpg&gt; Terdiri dari contoh-contoh aplikasi untuk Penjualan / POS ba]]></description>
<content:encoded><![CDATA[<div class='snap_preview'><p>&#60;img src=gambar/vb-penjualan.jpg&#62;</p>
<p>Terdiri dari contoh-contoh aplikasi untuk Penjualan / POS baik grosir, toko retail,butik, dan bisnis lainnya. Anda akan diberikan bagaimana mekanisme kerja dari sistem penjualan dari yang sederhana sampai tingkat lanjut baik manual maupun dengan sistem barcode.</p>
<p>download disini</p>
</div>]]></content:encoded>
</item>

</channel>
</rss>
