dcsimg
November 19, 2018
Hot Topics:

Writing Active Server components in Visual Basic

  • April 30, 1998
  • By Thornton Rose
  • Send Email »
  • More Articles »


' Class FileIO

Option Explicit

Private objApplication As Application  ' Reference to Application object
Private objResponse As Response        ' Reference to Response object

' OnStartPage():
'
' This procedure is called when an instance of this class is created in an
' Active Server Page. It gets references to the Application and Response
' objects that are being used in the ASP page that created the instance of
' this class.
'
Public Sub OnStartPage(objScriptingContext As ScriptingContext)
   Set objApplication = objScriptingContext.Application()
   Set objResponse = objScriptingContext.Response()
End Sub

' OnEndPage():
'
' This procedure is called when an instance of this class is destroyed in 
' an Active Server Page. It is used to clean up object references.
'
Public Sub OnEndPage()
   Set objApplication = Nothing
   Set objResponse = Nothing
End Sub

' help():
'
' Writes help information to the response stream.
'
Public Sub help()
   objResponse.Write "

Class FileIO

" & vbCrLf objResponse.Write "Usage:" & vbCrLf objResponse.Write "set o = Server.CreateObject(""ASCExample.FileIO"")" & vbCrLf objResponse.Write "

Methods:" & vbCrLf objResponse.Write "

    " & vbCrLf objResponse.Write "
  • help() - shows help" & vbCrLf objResponse.Write "
  • fileSize(strName) - returns size of named file" & vbCrLf objResponse.Write "
  • fileExists(strName) - returns True if named file exists" & vbCrLf objResponse.Write "
  • deleteFile(strName) - deletes named file" & vbCrLf objResponse.Write "
  • appendLine(strName, strLine) - appends line to file" & vbCrLf objResponse.Write "
" & vbCrLf End Sub ' fileSize(): ' ' Returns the size of the file with the given name. ' Public Function fileSize(strFileName) As Long fileSize = FileLen(strFileName) End Function ' fileExists(): ' ' Returns True if the specified file exists. Note that the given file ' specification can contain wildcard characters. ' Public Function fileExists(strFileSpec) As Boolean fileExists = (Dir(strFileSpec) <> "") End Function ' deleteFile(): ' ' Deletes files that match the given file specification, which can include ' wildcard characters. ' Public Sub deleteFile(strFileSpec) Call Kill(strFileSpec) End Sub ' appendLine(): ' ' Appends a line to a text file (which is handy when working with log ' files.) ' Public Sub appendLine(strFileName, strLine) Dim objFileSystem As FileSystemObject Dim objStream As TextStream Set objFileSystem = New FileSystemObject Set objStream = objFileSystem.OpenTextFile(strFileName, 8, True, False) objStream.WriteLine strLine objStream.Close End Sub ' End Class FileIO [end] -->

  • Save everything and compile. That's it.

    Testing

    Testing your Active Server component is easy (although debugging can get tedious). A few lines of VBScript or JavaScript in an ASP page is all that is required. Here's the test script:

    <html> <head> <meta name="WT.qs_dlk" content="W-L1qzoZOVBpqRJKVEmhDgAAABU"/> <meta name="WT.qs_shmv" content="hv20180802-shoemaker.sf.quinstreet.net"/> <meta name="inject_params" content="WT.qs_dlk=W-L1qzoZOVBpqRJKVEmhDgAAABU&"/> <script>!function(){if(!window.BOOMR||!window.BOOMR.version){var e,t,n,o=document.createElement("iframe");o.src="javascript:false",o.title="",o.role="presentation",(o.frameElement||o).style.cssText="width:0;height:0;border:0;display:none;",(n=document.getElementsByTagName("script")[0]).parentNode.insertBefore(o,n);try{t=o.contentWindow.document}catch(n){e=document.domain,o.src="javascript:var d=document.open();d.domain='"+e+"';void(0);",t=o.contentWindow.document}t.open()._l=function(){var t=this.createElement("script");e&&(this.domain=e),t.id="boomr-if-as",t.src="/imageserver/common/sg/1.0/sg.min.js",BOOMR_lstart=(new Date).getTime(),this.body.appendChild(t)},t.write('<body onload="document._l();">'),t.close()}}();</script> <script> document.cookie = 'inject_params=WT.qs_dlk=W-L1qzoZOVBpqRJKVEmhDgAAABU&; path=/; domain=developer.com;'; document.cookie = 'WMUUID=W-L1qzoZOVBpqRJKVEmhDgAAABU; path=/; domain=developer.com;'; </script> <title>ASCExample Tester</title> <script> window.webtrendsAsyncInit=function(){ var dcs=new Webtrends.dcs().init({ dcsid:"dcs38irdn10000g0vc4171yva_9y7z", domain:"www.qsstats.com", timezone:-8, i18n:true, onsitedoms:"developer.com", fpcdom:".developer.com", plugins:{ //hm:{src:"//s.webtrends.com/js/webtrends.hm.js"} } }).track(); }; (function(){ var s=document.createElement("script"); s.async=true; s.src="/imageserver/common/v10/webtrends.min.js"; var s2=document.getElementsByTagName("script")[0]; s2.parentNode.insertBefore(s,s2); }()); </script> <noscript><img alt="dcsimg" id="dcsimg" width="1" height="1" src="//www.qsstats.com/dcs38irdn10000g0vc4171yva_9y7z/njs.gif?dcsuri=/index.php/net/asp/article.php/10917_602621_3/Writing-Active-Server-components-in-Visual-Basic.htm&amp;WT.js=No&amp;WT.tv=10.4.1&amp;dcssip=www.developer.com&amp;WT.qs_dlk=W-L1qzoZOVBpqRJKVEmhDgAAABU&"/></noscript> </head> <h3>ASCExample Tester</h3> <% ' Create a FileIO object. set objFileIO = Server.CreateObject("ASCExample.FileIO") %> <hr> <% ' Get some help from the FileIO object. objFileIO.help %> <hr> <% ' Create a file for testing. strLogFileName = "c:\temp\test.log" objFileIO.appendLine strLogFileName, "This is line 1." %> <!-- Get the file info. --> strLogFileName = <%= strLogFileName %><br> fileExists() => <%= CStr(objFileIO.fileExists(strLogFileName)) %><br> fileSize() => <%= objFileIO.fileSize(strLogFileName) %> bytes <% ' Delete the file. objFileIO.deleteFile(strLogFileName) %> <p> <!-- Check the file existance again. --> File deleted.<br> fileExists() => <%= CStr(objFileIO.fileExists(strLogFileName)) %> </html> [end] </pre> <!--end_section--></p> <br/> <br> <br> <br/>Page 3 of 3<br/><br/><div style="height: 40px;" id="pages"> <div style="margin-left: 50%;"> <ul style="margin-left: -120px;"> <li class="arrow-left"><a href="/net/asp/article.php/10917_602621_2/Writing-Active-Server-components-in-Visual-Basic.htm"><img src="/images0/arrow_left.jpg" width="16" height="16" /></a></li> <li class="begin-li"></li> <li><a href="/net/asp/article.php/602621/Writing-Active-Server-components-in-Visual-Basic.htm">1</a> </li> <li><a href="/net/asp/article.php/10917_602621_2/Writing-Active-Server-components-in-Visual-Basic.htm">2</a> </li> <li><a href="javascript:void(0);">3</a> </li> <li class="end-li"></li> </ul> </div> </div> <br/><br/> <div id="nodeSearchWidget" style="display: none"> <style> #searchWidget{ border-bottom: 1px solid #344a70; } #searchWidget #top_bar{ background-color: #ffc926; height: 28px; width: 590px; padding-top: 8px; padding-left: 8px; padding-right: 8px; border-bottom: 1px solid #344a70; } #searchWidget #top_bar p { font-size:18px; font-family:'Roboto',sans-serif; font-weight:700; color: #000000; line-height: 21px; text-align: left; letter-spacing: 0em; } #searchWidget #top_bar p span{ font-size:10px; font-family:'Roboto Condensed', sans-serif; font-weight:500; color: #31313f; line-height: 9.14px; text-align: left; letter-spacing: 0.02em; float:right; padding-top: 6px; } #searchWidget .searchWidgetSteps h3{ font-size:32px; font-family:'Roboto',sans-serif; font-weight:700; color: #20202f; line-height: 36px; text-align: center; letter-spacing: 0em; margin-top: 20px; word-spacing: 5px; } #searchWidget .searchWidgetSteps{ width: 100%; text-align: center; } #searchWidget .searchWidgetSteps .step-no-question{ width: 100%; display: table; margin: 25px; } #searchWidget .searchWidgetSteps .step-no-question img{ float: right; margin-right: 24px; } .tracker-bar{ margin-bottom: 10px; } #searchWidget #search_step1 .topicsRow{ overflow: auto; display: inline-flex; } #searchWidget .topics { margin-right: 52px; cursor: pointer; } #searchWidget .topics:hover{ text-decoration: underline; } #searchWidget .topics:last-child{ margin-right: 0; } #searchWidget .topics p{ font-size:13.12px; font-family:'Roboto',sans-serif; font-weight:700; color: #000000; text-align: center; line-height: 15.74px; letter-spacing: 0em; margin-top: 5px; } #searchWidget #search-bottom-logo{ clear: both; } #searchWidget #search-bottom-logo img{ padding-left: 25px; padding-right: 25px; } #searchWidget #search_step5 p{ font-size:18px; font-family:'Roboto',sans-serif; font-weight:300; color: #20202f; text-align: center; line-height: 36px; letter-spacing: 0em; } #searchWidget #search_step5 p span{ font-weight:700; } #searchWidget #search_step5 #progresscircle{ margin-left: 32%; } #searchWidget #search_step6{ min-height: 182px; } #searchWidget div.qs-listings .search_step6_child{ background:url('/hqb2b/img/searchwidget/article-match.png') no-repeat 63px 8px; margin-top: 43px; margin-bottom: 10px; float: left; } #searchWidget div.qs-listings .search_step6_child #asset-img{ margin-right: 20px; float: left; margin-left: 122px; display: inline-block; } #searchWidget div.qs-listings .search_step6_child #asset-details{ width: 303px; float: left; margin-bottom: 15px; margin-top: 10px; } #searchWidget div.qs-listings .search_step6_child #asset-details h2{ font-size:23.61px; font-family:'Roboto',sans-serif; font-weight:700; color: #1f1f2c; text-align: left; line-height: 25.76px; letter-spacing: 0em; margin-bottom: 30px; margin-left: 15px; } #searchWidget div.qs-listings .search_step6_child #asset-details p { font-size:10px; font-family:'Roboto Condensed', sans-serif; font-weight:300; color: #1f1f2c; text-align: left; line-height: 10.79px; letter-spacing: 0.02em; margin-left: 20px; } #searchWidget div.qs-listings .search_step6_child #asset-details a { font-size:17.85px; font-family:'Roboto',sans-serif; font-weight:700; color: #ffffff; text-align: center; line-height: 15.3px; letter-spacing: 0em; background-color: #2c9feb; padding-left: 55px; padding-right: 12px; padding-top: 4px; padding-bottom: 5px; border-radius: 20px; text-decoration: none; } #searchWidget div.qs-listings .search_step6_child span{ font-size:18px; font-family:'Roboto',sans-serif; font-weight:700; color: #3399ff; text-align: left; line-height: 50.52px; letter-spacing: 0em; } #searchWidget div.qs-listings .search_step6_child .prev_match{ float: left; cursor: pointer; } #searchWidget div.qs-listings .search_step6_child .next_match{ float: right; cursor: pointer; } #searchWidget div.qs-listings .search_step6_child .prev_match:hover{ text-decoration: underline; } #searchWidget div.qs-listings .search_step6_child .next_match:hover{ text-decoration: underline; } #searchWidget .styled-select { background: url(/hqb2b/img/searchwidget/dropdown_arrow.png) no-repeat 94% 5px; height: 38px; overflow: hidden; width: 288px; } #searchWidget .select-background{ background-color: #2c9feb; } #searchWidget .styled-select select { background: transparent; border: none; height: 38px; padding: 5px; /* If you add too much padding here, the options won't show in IE */ width: 288px; } #searchWidget .rounded { -webkit-border-radius: 20px; -moz-border-radius: 20px; border-radius: 20px; } #searchWidget .inputdiv{ display: table-cell; text-align: center; vertical-align: middle; } #searchWidget .inputdiv select option{ text-align: center; color: #fff; background-color: #2c9feb; } #searchWidget .inputdiv select{ font-size: 15.58px; font-family: 'Roboto',sans-serif; font-weight: 700; color: #FFF; line-height: 18.7px; float: left; letter-spacing: 0em; -webkit-appearance: none; -moz-appearance: none; text-indent: 1px; text-overflow: ''; } #searchWidget .inputdiv select::-ms-expand { display: none; } #searchWidget #searchWidgetContainer { margin: 20px; width: 141px; height: 143px; position: relative; } </style> <div id="searchWidget"> <div id="top_bar"> <p> IT Solutions Builder <span>TOP IT RESOURCES TO MOVE YOUR BUSINESS FORWARD</span> </p> </div> <div id="search_step1" class="searchWidgetSteps" > <h3> Which topic are you interested in? </h3> <div class="topicsRow" id="topic-row1"> <div class="topics" id="B2B_PRODUCT_MOBILE"> <img src="/hqb2b/img/searchwidget/icon-mobile.png"/> <p>Mobile</p> </div> <div class="topics" id="B2B_PRODUCT_SECURITY"> <img src="/hqb2b/img/searchwidget/icon-security.png"/> <p>Security</p> </div> <div class="topics" id="B2B_PRODUCT_NETWORKING"> <img src="/hqb2b/img/searchwidget/icon-networks.png"/> <p>Networks/IoT</p> </div> <div class="topics" id="B2B_PRODUCT_DEVELOPMENT_CLOUD"> <img src="/hqb2b/img/searchwidget/icon-cloud.png"/> <p>Cloud</p> </div> <div class="topics" id="B2B_PRODUCT_STORAGE"> <img src="/hqb2b/img/searchwidget/icon-datastorage.png"/> <p>Data Storage</p> </div> </div> <div class="topicsRow" id="topic-row2"> <div class="topics" id="B2B_PRODUCT_APPLICATIONS"> <img src="/hqb2b/img/searchwidget/icon-apps.png"/> <p>Applications</p> </div> <div class="topics" id="B2B_PRODUCT_DEVELOPMENT"> <img src="/hqb2b/img/searchwidget/icon-dev.png"/> <p>Development</p> </div> <div class="topics" id="B2B_PRODUCT_IT_MANAGEMENT_PRACTICES"> <img src="/hqb2b/img/searchwidget/icon-itmgmt.png"/> <p>IT Management</p> </div> <div class="topics" id="B2B_PRODUCT"> <img src="/hqb2b/img/searchwidget/icon-other.png"/> <p>Other</p> </div> </div> <input type="hidden" name="selectedPortalServiceCode" id="selectedPortalServiceCode"> </div> <div id="search_step2" class="searchWidgetSteps" style="display: none"> <h3> What is your company size? </h3> <div class="step-no-question"> <img src="/hqb2b/img/searchwidget/article-Q2.png"/> <div class="inputdiv"> <div class="styled-select select-background rounded"> <select name="NumberofEmployeesRange" id="numberofEmployeesRange"> <option>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Select company size</option> <option value="9" >1-9</option> <option value="24" >10-24</option> <option value="49" >25-49</option> <option value="99" >50-99</option> <option value="249" >100-249</option> <option value="499" >250-499</option> <option value="999" >500-999</option> <option value="1999" >1000+</option> </select> </div> </div> </div> <div class="tracker-bar"> <img src="/hqb2b/img/searchwidget/tracker-2.png"/> </div> </div> <div id="search_step3" class="searchWidgetSteps" style="display: none"> <h3> What is your job title? </h3> <div class="step-no-question"> <img src="/hqb2b/img/searchwidget/article-Q3.png"/> <div class="inputdiv"> <div class="styled-select select-background rounded"> <select name="Designation" id="designation"> <option>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Select job title</option> <option value="C-Level/President">C-Level/President</option> <option value="Manager">Manager</option> <option value="VP">VP</option> <option value="Staff (Associate/Analyst/etc.)">Staff (Associate/Analyst/etc.)</option> <option value="Director">Director</option> </select> </div> </div> </div> <div class="tracker-bar"> <img src="/hqb2b/img/searchwidget/tracker-3.png"/> </div> </div> <div id="search_step4" class="searchWidgetSteps" style="display: none"> <h3> What is your job function? </h3> <div class="step-no-question"> <img src="/hqb2b/img/searchwidget/article-Q4.png"/> <div class="inputdiv"> <div class="styled-select select-background rounded"> <select name="JobFunction" id="jobFunction"> <option>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Select job function</option> <option value="IT - General">IT - General</option> <option value="IT - Project Management">IT - Project Management</option> <option value="IT - Systems/Network Administration">IT - Systems/Network Administration</option> <option value="IT - Developer">IT - Developer</option> <option value="IT - Tester/QA">IT - Tester/QA</option> <option value="Accounting/Finance/Legal">Accounting/Finance/Legal</option> <option value="Academic/Research">Academic/Research</option> <option value="Administrative">Administrative</option> <option value="General Management">General Management</option> <option value="Human Resources">Human Resources</option> <option value="Marketing">Marketing</option> <option value="Operations">Operations</option> <option value="Sales">Sales</option> <option value="Consultant">Consultant</option> <option value="Other">Other</option> </select> </div> </div> </div> <div class="tracker-bar"> <img src="/hqb2b/img/searchwidget/tracker-4.png"/> </div> </div> <div id="search_step5" class="searchWidgetSteps" style="display: none" > <p><span>Searching our resource database</span> to find your matches...</p> <div id="progresscircle"> <!--<img src="/hqb2b/img/searchwidget/progress.gif" height="140"/>--> <div id="searchWidgetContainer"></div> </div> </div> <div id="search_step6" class="searchWidgetSteps qs-listings" style="display: none"> </div> <div id="search-bottom-logo"> <!-- <img src="/hqb2b/img/searchwidget/eSignLive-Logo-BlackOrange-1.png"/> <img src="/hqb2b/img/searchwidget/Globalscape_Logo.png"/> <img src="/hqb2b/img/searchwidget/IBM_logo.png"/> <img src="/hqb2b/img/searchwidget/Green_Igloo_Logo.png"/> <img src="/hqb2b/img/searchwidget/Intel-logo.svg.png"/>--> </div> <script type="text/javascript" src="/hqb2b/js/underscore.js"> </script> <script type="text/javascript" src="/hqb2b/js/progressbar.js"> </script> <script type="text/javascript" src="/hqb2b/js/searchWidgetTraker.js"> </script> <script> // progressbar.js@1.0.0 version is used // Docs: http://progressbarjs.readthedocs.org/en/1.0.0/ var bar = new ProgressBar.Circle(searchWidgetContainer, { color: '#20202f', // This has to be the same size as the maximum width to // prevent clipping strokeWidth: 4, trailWidth: 1, easing: 'easeInOut', duration: 9000, text: { autoStyleContainer: false }, from: {color: '#2c9feb', width: 4}, to: {color: '#2c9feb', width: 4}, // Set default step function for all animate calls step: function(state, circle) { circle.path.setAttribute('stroke', state.color); circle.path.setAttribute('stroke-width', state.width); var value = Math.round(circle.value() * 100); if (value === 0) { circle.setText(''); } else { circle.setText(value + '%'); } if (value === 99) { $("#search_step5").hide(); $('#search_step6').show('slide', {direction: 'right'}, 500); } } }); bar.text.style.fontFamily = '"Roboto", sans-serif'; bar.text.style.fontSize = '40.25px'; $(".topics").click(function() { $("#search_step1").hide(); $('#search_step2').show('slide', {direction: 'right'}, 500); if (typeof SearchWidgetTracker != 'undefined') SearchWidgetTracker.log(SearchWidgetTracker.link_click, 'topic_link', 'search_widget', $(this).children('p').text()); $("#selectedPortalServiceCode").val($(this).attr('id')); }); $('#search_step2 select').change(function() { $("#search_step2").hide(); if (typeof SearchWidgetTracker != 'undefined') SearchWidgetTracker.log(SearchWidgetTracker.form_elem_change, 'NumberofEmployeesRange', 'search_widget', $('#search_step2 select').val()); $('#search_step3').show('slide', {direction: 'right'}, 500); }) $('#search_step3 select').change(function() { $("#search_step3").hide(); if (typeof SearchWidgetTracker != 'undefined') SearchWidgetTracker.log(SearchWidgetTracker.form_elem_change, 'Designation', 'search_widget', $('#search_step3 select').val()); $('#search_step4').show('slide', {direction: 'right'}, 500); }) $('#search_step4 select').change(function() { $("#search_step4").hide(); if (typeof SearchWidgetTracker != 'undefined') SearchWidgetTracker.log(SearchWidgetTracker.form_elem_change, 'JobFunction', 'search_widget', $('#search_step4 select').val()); $('#search_step5').show('slide', {direction: 'right'}, 500); bar.animate(1.0); // Number from 0.0 to 1.0 }); $('#searchWidget').on("click", "#downloadbtn", function(e) { e.preventDefault(); if (typeof SearchWidgetTracker != 'undefined') SearchWidgetTracker.log(SearchWidgetTracker.button_click, 'asset_button', 'search_widget'); var url = $(this).attr('href'); window.open(url, '_blank'); }); </script> </div> </div> <!-- START COMMENTING CODE --> <p class="style1"> <noscript>Please enable Javascript in your browser, before you post the comment! Now Javascript is disabled.</noscript> </p> <a name="commentresponse"> <div id="comment_response"></div> </a> <div id="comment_error" class="error"></div> <div class="comment_wrapper"> <div style="font-weight: bold;"><font id="commentCount">0</font> Comments&nbsp;<a href="#comment_form" style="text-decoration: underline;">(click to add your comment)</a></div> <div id="comment_pagination_top"></div> <div id="comment_page_container"></div> <div id="comment_pagination_bottom"></div> <div id="comment_form"> <div style="border-bottom: 2px solid rgb(102, 102, 102); width: 100%; height: 20px; margin-bottom: 5px; clear: left;"></div> <img border="0" src="https://assets.devx.com/Icon/icon_comment.png" alt="" />Comment and Contribute<p></p> </div> <div style="background-color:#EFEFEF;"> <p>&nbsp;</p> <form id="commentform" name="commentform" method="post" > <p class="commenttext"> <input type="text" tabindex="1" size="22" value="" id="author" name="author"> <label for="author">Your name/nickname</label> </p> <p class="commenttext"> <input type="text" tabindex="2" size="22" value="" id="email" name="email"> <label for="email">Your email</label> </p> <p class="commenttext"> <input type="text" tabindex="3" value="" size="22" id="blurbTitle" name="blurbTitle"> <label for="blurbTitle">Subject</label> </p> <p class="commenttext"> <textarea id="commentdetails" name="commentdetails" onkeydown="limitText(this.form.commentdetails,this.form.countdown,1200);" onkeyup="limitText(this.form.commentdetails,this.form.countdown,1200);" style="overflow: auto; font-family: arial,helvetica,sans-serif; font-style: normal; font-variant: normal; font-weight: normal; font-size: 9pt; line-height: normal; font-size-adjust: none; font-stretch: normal; -x-system-font: none;" rows="10" cols="80" tabindex="4"></textarea><br/> <span style="font-size:8pt;margin-left:10px;">(Maximum characters: 1200). You have <input type="text" size="4" value="1200" name="countdown"> characters left.</span> <p class="commenttext"> <div class="g-recaptcha" data-sitekey="6LcX1EwUAAAAAIfaONTfx2ElFE1OokB6SZI1zT-W" data-callback="recaptchaCallback" data-expired-callback="recaptchaExpired"></div> </p> <p> <input type="submit" value="Submit Your Comment" tabindex="6" id="submit" disabled="disabled" name="submit" onclick="return validate();" />&nbsp;<img border="0" align="center" src="/images0/ajax-loader.gif" alt="" id="ajax_loading_img" style="vertical-align:middle;visibility:hidden;"> </p> <input type="hidden" id="key" value="1838930" name="key"> <input type="hidden" value="0" id="comment_parent" name="comment_parent"> <input type="hidden" value="0" id="totalComments" name="totalComments"> </form> <p>&nbsp;</p> </div> </div> <script type="text/javascript" src="/javascripts/comments.js"> </script> <br> <!-- END COMMENTING CODE --> <div class="vspace"></div> </div> <!-- article div ends --> </div> <div class="col colRight dimMainRight"> <div class="modal"></div> <div id="newsletter_subscribe" class="section"> <div id="heading" style="margin-top:5px"><h2>Enterprise Development Update</h2></div> <div id="staticText">Don't miss an article. Subscribe to our newsletter below.</div> <div id="nl_error" style="display:none;"></div> <div id="nl_success" style="display:none;"></div> <div id="nl_question_form"> <form id="newsletterform"> <div id="messageContainer" style="display: none;"></div> <div style="float:left;width:70%"> <input type="text" id="nl_email" name="nlemail" maxlength="255" class="nlemail" placeholder="Enter Email Address"> <input type="hidden" name="NewsletterSignup" value="Enterprise Development Update" id="NewsletterSignup"> <input type="hidden" name="nlNewsletterKey" value="1423" id="nlNewsletterKey"> <input type="hidden" name="nlBusinessUnit" value="Internet.com" id="nlBusinessUnit"> <input type="hidden" name="RegistrationWebsite" value="www.developer.com" id="RegistrationWebsite"> </div> <div style="float:left;width:30%"> <input type="submit" name="nlSubmit" onclick="newsletterGlobalSubmit('newsletterform', 'messageContainer', 'messageContainer'); return false;" value="SIGN UP" id="nl_submit_button"><br> </div> </form> </div> <div class="vspace"></div> </div> <div class="vspace"></div> <div class="adsBox"> <!-- QS-AD: 'imu' start --> <script language="JavaScript"> var t=displayDFPTag("imu"); document.write(t); </script> <!-- QS-AD: 'imu' end --> </div> <div class="vspace"></div> <div id="mostPopularStories" class="section"> <div class="sectionHeader"> <h2>Most Popular Developer Stories</h2> <a href="#" class="more"></a> </div> <div class="sectionContent"> <div class="tabs"> <div class="tabsMenu clearfix"> <ul> <li><a href="#mostPopularToday" class="selected">Today</a></li> <li><a href="#mostPopularThisWeek">This Week</a></li> <li><a href="#mostPopularAllTime">All-Time</a></li> </ul> </div> <div class="tabsContents"> <div class="tabsContent selected" id="mostPopularToday"> <ul> <li><a href="http://www.developer.com/java/data/article.php/3417381/Using-JDBC-with-MySQL-Getting-Started.htm"><span class="graytext">1</span> Using JDBC with MySQL, Getting Started</a></li> <li><a href="http://www.developer.com/design/article.php/2109801/Creating-Use-Case-Diagrams.htm"><span class="graytext">2</span> Creating Use Case Diagrams</a></li> <li><a href="http://www.developer.com/java/other/article.php/3556176/An-Introduction-to-Java-Annotations.htm"><span class="graytext">3</span> An Introduction to Java Annotations</a></li> <li><a href="http://www.developer.com/java/other/article.php/3559931/Hibernate-Basics.htm"><span class="graytext">4</span> Hibernate Basics</a></li> <li><a href="http://www.developer.com/net/asp/article.php/3096831/Using-ASPNET-To-Send-Email.htm"><span class="graytext">5</span> Using ASP.NET To Send Email</a></li> </ul> </div> <div class="tabsContent" id="mostPopularThisWeek"> <ul> <li><a href="http://www.developer.com/java/data/article.php/3417381/Using-JDBC-with-MySQL-Getting-Started.htm"><span class="graytext">1</span> Using JDBC with MySQL, Getting Started</a></li> <li><a href="http://www.developer.com/lang/php/article.php/3896056/10-Experimental-PHP-Projects-Pushing-the-Envelope.htm"><span class="graytext">2</span> 10 Experimental PHP Projects Pushing the Envelope</a></li> <li><a href="http://www.developer.com/java/other/article.php/3559931/Hibernate-Basics.htm"><span class="graytext">3</span> Hibernate Basics</a></li> <li><a href="http://www.developer.com/java/other/article.php/3556176/An-Introduction-to-Java-Annotations.htm"><span class="graytext">4</span> An Introduction to Java Annotations</a></li> <li><a href="http://www.developer.com/db/article.php/3379271/Oracle-Programming-with-PLSQL-Collections.htm"><span class="graytext">5</span> Oracle Programming with PL/SQL Collections</a></li> </ul> </div> <div class="tabsContent" id="mostPopularAllTime"> <ul> <li><a href="http://www.developer.com/java/data/article.php/3417381/Using-JDBC-with-MySQL-Getting-Started.htm"><span class="graytext">1</span> Using JDBC with MySQL, Getting Started</a></li> <li><a href="http://www.developer.com/java/other/article.php/3559931/Hibernate-Basics.htm"><span class="graytext">2</span> Hibernate Basics</a></li> <li><a href="http://www.developer.com/db/article.php/3379271/Oracle-Programming-with-PLSQL-Collections.htm"><span class="graytext">3</span> Oracle Programming with PL/SQL Collections</a></li> <li><a href="http://www.developer.com/java/other/article.php/3556176/An-Introduction-to-Java-Annotations.htm"><span class="graytext">4</span> An Introduction to Java Annotations</a></li> <li><a href="http://www.developer.com/design/article.php/2109801/Creating-Use-Case-Diagrams.htm"><span class="graytext">5</span> Creating Use Case Diagrams</a></li> </ul> </div> </div> </div> </div> </div> <!-- Code to put on site page to show pinning option --> <!-- commented out 10/22 as per CR "CHG231107: Remove IE 9 Site pinning check" <script type="text/javascript" language="javascript"> if(jQuery.browser.msie){ if(document.documentMode != undefined && document.documentMode==9){ if (!window.external.msIsSiteMode()) { document.write('<div id="pinMeContainer"><img class="msPinSite" src="/images0/developer64x64.png" height="64" weight="64" /><br/><span id="pinMe">To Pin this site, drag this image to the left to your Windows Taskbar. Try it now!</span></div>'); }else { try { if (window.external.msIsSiteMode()) { jQuery.get('https://www.developer.comlatest_articles', function(data){ displayLatestNews(data); }); } } catch (ex) { } } }else{ document.write('<div id="pinMeContainer"><img class="msPinSite" src="/images0/developer64x64.png" height="64" weight="64" /><br/><span id="pinMe">Upgrade your browser to IE 9 to see the power of Site Pinning!</span></div>'); } } function displayLatestNews(data){ try{ g_ext = window.external; if(data.articles != undefined && data.articles.length){ g_ext.msSiteModeClearJumpList(); g_ext.msSiteModeCreateJumplist('Developer.com Latest News'); for(i=0; i<data.articles.length; i++){ g_ext.msSiteModeAddJumpListItem (data.articles[i].title, data.articles[i].link, 'https://www.developer.comfavicon.ico'); } var dt = new Date(); var updated = (dt.getMonth()+1) +"/"+(dt.getDay()+1)+"/"+dt.getFullYear()+" "+dt.toLocaleTimeString(); g_ext.msSiteModeAddJumpListItem ('Last updated - '+updated, 'https://www.developer.com', 'https://www.developer.com/images0/refresh.ico'); g_ext.msSiteModeShowJumpList(); } }catch(ex){ } } </script> --> <!-- End of code to put on site page to show pinning option --> <div class="adsBox"> <!-- QS-AD: 'imu' start --> <script language="JavaScript"> var t=displayDFPTag("imu"); document.write(t); </script> <!-- QS-AD: 'imu' end --> </div> <div class="vspace"></div> <div id="mostCommentedOn" class="section"> <div class="sectionHeader"> <h2>Most Commented On</h2> <a href="#" class="more"></a> </div> <div class="sectionContent"> <div class="tabs"> <div class="tabsMenu clearfix"> <ul> <li><a href="#mostCommentedOnThisWeek" class="selected">This Week</a></li> <li><a href="#mostCommentedOnThisMonth">This Month</a></li> <li><a href="#mostCommentedOnAllTime">All-Time</a></li> </ul> </div> <div class="tabsContents"> <div class="tabsContent selected" id="mostCommentedOnThisWeek"> <ul> <li><a href="http://www.developer.com/article.php/3896056"><span class="graytext">1</span> 10 Experimental PHP Projects Pushing the<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Envelope</a></li><li><a href="http://www.developer.com/article.php/777761"><span class="graytext">2</span> Day 1: Learning the Basics of PL/SQL</a></li><li><a href="http://www.developer.com/article.php/3336751"><span class="graytext">3</span> C# Tip: Placing Your C# Application in the<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System Tray</a></li><li><a href="http://www.developer.com/article.php/641521"><span class="graytext">4</span> Logical Versus Physical Database Modeling</a></li><li><a href="http://www.developer.com/article.php/3896711"><span class="graytext">5</span> Is Ubuntu Contributing as Much as It Should to<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Free Software Projects?</a></li> </ul> </div> <div class="tabsContent" id="mostCommentedOnThisMonth"> <ul> <li><a href="http://www.developer.com/article.php/777761"><span class="graytext">1</span> Day 1: Learning the Basics of PL/SQL</a></li><li><a href="http://www.developer.com/article.php/3894316"><span class="graytext">2</span> The 5 Developer Certifications You'll Wish You<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Had in 2015</a></li><li><a href="http://www.developer.com/article.php/3896056"><span class="graytext">3</span> 10 Experimental PHP Projects Pushing the<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Envelope</a></li><li><a href="http://www.developer.com/article.php/1495931"><span class="graytext">4</span> An Introduction to Struts</a></li><li><a href="http://www.developer.com/article.php/3894566"><span class="graytext">5</span> Inside Facebook's Open Source Infrastructure</a></li> </ul> </div> <div class="tabsContent" id="mostCommentedOnAllTime"> <ul> <li><a href="http://www.developer.com/article.php/2109801"><span class="graytext">1</span> Creating Use Case Diagrams</a></li><li><a href="http://www.developer.com/article.php/777761"><span class="graytext">2</span> Day 1: Learning the Basics of PL/SQL</a></li><li><a href="http://www.developer.com/article.php/3336751"><span class="graytext">3</span> C# Tip: Placing Your C# Application in the<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System Tray</a></li><li><a href="http://www.developer.com/article.php/3096831"><span class="graytext">4</span> Using ASP.NET To Send Email</a></li><li><a href="http://www.developer.com/article.php/3417381"><span class="graytext">5</span> Using JDBC with MySQL, Getting Started</a></li> </ul> </div> </div> </div> </div> </div> <div class="vspace"></div> <div class="articlecategorysummary"> <iframe id='whitePaperIFrame' scrolling="no" frameborder="0" align="middle" src="https://www.developer.com/sl/assetlisting/?wsn=www.developer.com&amp;wpu=/net/asp/article.php/10917_602621_3/Writing-Active-Server-components-in-Visual-Basic.htm&amp;lurl=https://o1.qnsr.com/cgi/r?WT.qs_dlk=W-L1qzoZOVBpqRJKVEmhDgAAABU;;n=203;c=1397070;s=9487;x=7936;f=201309171321110;u=j;z=TIMESTAMP;k=https://assetform.developer.com/controller&amp;wpos=AssetListing&amp;lyt=l9&amp;title=Top White Papers and Webcasts&css=https://www.developer.com/hqb2b/css/qmp/qmp_default.css" height="725"></iframe> </div> <script type="text/javascript"> var updateIframe = false; var t = 0; function updateQMPIframe() { if(!updateIframe) { if($('#whitePaperIFrame').contents().find('.asset').length > 0) { var height = $('#whitePaperIFrame').contents().find('.qmpContainer').height(); var iframe = document.getElementById('whitePaperIFrame'); var iframeHeight = document.getElementById('whitePaperIFrame').height; if(height>iframeHeight){ height = height + 5; //Add border pixels. iframe.setAttribute( 'height', height); clearTimeout(t); updateIframe = true; } } else { t = setTimeout('updateQMPIframe()', 3000); } } } updateQMPIframe(); </script> </div> <div class="vspace clear"></div> <div class="vspace clear"></div> <div style="clear:both;"> <div style="text-align: center;"> <div id="lb-wrapper" align="center"> <div id="ad_p2-lb" style="text-align:center;"> <!-- QS-AD: 'lb' start --> <script language="JavaScript"> var t=displayDFPTag("lb"); document.write(t); </script> <!-- QS-AD: 'lb' end --> </div> </div> </div> <div align="center"> <a href="/sitemap.html">Sitemap</a> </div> <br/> <FONT SIZE="-1" FACE="arial, helvetica"> <style type="text/css"> #brand-footer{text-align:center;margin:0 auto;} #commonfooterpropertytext{padding-bottom: 12px;} #commonfootercopyright{padding: 3px;} #eweekBrand-footer{text-align:center;margin:0 auto} #footerDisclaimerText{margin: 15px 10px 0px 10px; text-align: justify;} </style> <div id="brand-footer"> <div> <img id="commonfooterlogo" src="" border="0" /> </div> <div id="commonfooterpropertytext"></div> <div id="footerlinks"> <a rel="nofollow" href="/terms">Terms of Service</a> | <a rel="nofollow" href="/licensing">Licensing & Reprints</a> | <a rel="nofollow" href="//quinstreetenterprise.com/about_us" target="_blank">About Us</a> | <a rel="nofollow" href="/privacy">Privacy Policy</a> | <a rel="nofollow" id="commonfootercontactuslink" href="/contact-us.html">Contact Us</a> | <a rel="nofollow" href="//quinstreetenterprise.com/about_us#contactus" target="_blank">Advertise</a> </div> <div id="commonfootercopyright"></div> <div id="footerDisclaimerText"> <p> <strong>Advertiser Disclosure:</strong> Some of the products that appear on this site are from companies from which QuinStreet receives compensation. This compensation may impact how and where products appear on this site including, for example, the order in which they appear. QuinStreet does not include all companies or all types of products available in the marketplace. </p> </div> </div> <script async language="Javascript" src="/icom_includes/footers/scripts/footerbrandingcode.js"> </script> </font> <link href='https://fonts.googleapis.com/css?family=Lato&subset=latin,latin-ext' rel='stylesheet' type='text/css'> <div id="newuserregistrationpopup"> <div id="closepopup"><a class="newuserregistrationpopup-sprite close" href="#"></a></div> <div id="thankuptext">Thanks for your registration, follow us on our social networks to keep up-to-date</div> <div id="socialsharebtn"> <div id="socialbtns"><a class="sprite-user-register-popup-tw newuserregistrationpopup-sprite" href="https://o1.qnsr.com/cgi/r?WT.qs_dlk=W-L1qzoZOVBpqRJKVEmhDgAAABU;;n=203;c=1459370;s=8986;x=7936;f=201411241658150;u=j;z=TIMESTAMP;k=https://twitter.com/DeveloperCom" target="_blank"></a></div> <div id="socialbtns"><a class="sprite-user-register-popup-ln newuserregistrationpopup-sprite" href="https://o1.qnsr.com/cgi/r?WT.qs_dlk=W-L1qzoZOVBpqRJKVEmhDgAAABU;;n=203;c=1459370;s=8986;x=7936;f=201411241658150;u=j;z=TIMESTAMP;k=https://www.linkedin.com/company/developer-com?trk=top_nav_home" target="_blank"></a></div> <div id="socialbtns"><a class="sprite-user-register-popup-gplus newuserregistrationpopup-sprite" href="https://o1.qnsr.com/cgi/r?WT.qs_dlk=W-L1qzoZOVBpqRJKVEmhDgAAABU;;n=203;c=1459370;s=8986;x=7936;f=201411241658150;u=j;z=TIMESTAMP;k=https://plus.google.com/u/0/b/117958898397590965610/+Developerdotcom/posts" target="_blank"></a></div> <div id="socialbtns"><a class="sprite-user-register-popup-rss newuserregistrationpopup-sprite" href="https://o1.qnsr.com/cgi/r?WT.qs_dlk=W-L1qzoZOVBpqRJKVEmhDgAAABU;;n=203;c=1459370;s=8986;x=7936;f=201411241658150;u=j;z=TIMESTAMP;k=https://www.developer.com/developer/dev-25.xml" target="_blank"></a></div> </div> </div> </div> </div> </div> </div> <!-- QS-AD: 'hero' start --> <script language="JavaScript"> var t=displayDFPTag("hero"); document.write(t); </script> <!-- QS-AD: 'hero' end --><script language="JavaScript" type="text/javascript"> <!-- // Make sure all image has an alt tag if it doesn't already $(document).ready(function(){ $("img").each(function() { var img = $(this); if (!img.attr("alt")) img.attr("alt", ""); }); }); //--> </script> <!-- QS-AD: 'siteskin' start --> <script language="JavaScript"> var t=displayDFPTag("siteskin"); document.write(t); </script> <!-- QS-AD: 'siteskin' end --></body> </html>