I have this code: Code: For Each oToolStripMenuItem As ToolStripMenuItem In oToolStripMenuItemMain.DropDownItems '... Next First line produces an exception because it runs into a ToolStripSeparator. Any ideas how to modify this loop so it won't? Ty
For Each oToolStripMenuItem As ToolStripMenuItem In oToolStripMenuItemMain.DropDownItems '... Next
Use [CODE] tags and rate useful posts VB: MSDN VBnet DevX vbAccelerator DB: W3Schools SQL TechOnTheNet's Oracle/PLSQL ConnectionStrings Misc (IT): Use XP look (manifest) in your apps (sample) MZ-Tools (free and cool VB add-in) Deploy your apps with Inno Setup Misc: Zeitgeist Movie ... so make the best of this test and don't ask why, it's not a question, but a lesson learned in time...
Try this: Code: For Each oToolStripMenuItem As ToolStripMenuItem In oToolStripMenuItemMain.DropDownItems.OfType(Of ToolStripMenuItem)() '... Next
For Each oToolStripMenuItem As ToolStripMenuItem In oToolStripMenuItemMain.DropDownItems.OfType(Of ToolStripMenuItem)() '... Next
#define true ((rand() % 2)? true: false) // Debug THAT! Rate the posts that helped you! Evaluating Expressions | Simple POP3 Protocol Realization | Timers explained | Delegates explained | A secure login to your app sample | Numeric Textbox | Printer.Print (or I miss VB6 printing in .Net) | Shuffling any IEnumerable | Marshalling structures to byte arrays and back | Invoking a method by its name | Plugins architecture WITHOUT references | Permuter that permutes everything | Encrypt/Decrypt your stuff | Snake Game | Enumerating all Network Adapters in the system | How to make a web request
Sweet Ty
Forum Rules