Tip Bank

DevX - Software Development Resource

Generate a String of Specified Characters and of Desired Length

The following function generates a string of specified characters and of desired length: public static String getStringOfChars(char ch,int length) { StringBuffer sb=new StringBuffer(); sb.setLength(length); return sb.toString().replace(‘u0000’,ch); }

DevX - Software Development Resource

Prefer Templates to Macros

Because macros do not behave as function calls but merely as text substitutions, they might exhibit strange behaviors during complex calls. For instance: #define mul (t) t*t*tmul(3+3) gives 24 though

DevX - Software Development Resource

Create Rollover Graphics in ASPX Pages

Although this tip creates onmouseover and onmouseout attributes in the IMG tag within the A tag when rendered to the browser, it could be used to set any attributes. Create

DevX - Software Development Resource

Import Web Content into Your Excel Workbook

Importing Web content into your Excel workbook is simple using Micorosoft’s WinHTTP tools (they are free and included with IE). First, create and save an Excel Workbook. Next, access the