/Home /Archive /Syndicate /Blog /Support /About /Contact  
All Visual Basic Feeds in one place!





Channel: AddressOf.com - Cory Smith - VB.NET

Going through a bunch of old floppy disks and copying the files to my home server in an effort to get rid of these things, I happened across a bit of source code from WAAAAAAAAAY back.  (March 7th, 1990 to be precise.) For a few years around 1990, a friend of mine (Sean) and I ran a very successful BBS with tons of users and *AWESOME* interaction among them.  This was during a time in BBS usage was at it's height and there were probably thousands to choose from.  So Sean and ... [ read more ]


I found a couple of solutions on the DevExpress website for how to use the ComboBoxEdit component the way I wanted, however, none of them seemed to provide a smooth transition from the WinForms databound ComboBox to the DevExpress counterpart.  So using some fo the examples that I found, reading through the help and reflecting on the subject for a whole five minutes... here is what I ended up with. Option Explicit On Option Strict On Option Infer O ... [ read more ]


Oh yeah, by the way, I'm now an INETA speaker. ;-) What does this really mean?  Well, if you'd like to get me to come out to your user group, all you need to do is put in a request to www.INETA.org and they'll help with the travel/hotel expenses and even pay for the pizza!  So here's a chance that you and I can meet face to face, no matter where you live. :-D For the record, I'm not a "big shot" "important" "super smart" "grad ... [ read more ]


Linq is very, very, very cool.  I can easily envision looking three years from now and wonder "how did we write software without Linq?".  Several recent language editions have helped to reduce code needed and thus made my development life easier.  However, I have to say that Linq is something that seems to hit a home run in several distinct areas to improve my development life.  Over the next few posts, I'm going to outline a few "real world" examples ... [ read more ]


Someone sent me an IM asking if I knew of a way to handle the pressing of the close button on a console application.  After a bit of research, I found a way (and some limitations).  This required stepping outside of the Microsoft .NET Framework utilizing P/Invoke.  This allowed me to capture the application close event (which is initiated via the close button, the close menu item or task manager) and when Windows is shutting down (the user logging off).  You can re ... [ read more ]


If your in the Dallas area (or more specifically, the North Dallas area), swing by NDDNUG tonight for my presentation on developing for Windows Vista using Visual Studio 2005.  (Of course discussing VS'08 can't be avoided and everything I'm speaking on works in VS'08).  Meeting starts at 6:00pm, so I'll need to head out of here in just a few minutes.


I have to admit that lately I've been feeling a little overwhelmed by the amount of new technology that I need to grok in order to stay ahead of the curve.  In a relatively short window of time, we've had Windows Presentation Foundation (WPF), Windows Workflow Foundation (WF), Windows Communication Foundation (WCF), Expression Blend, XNA Studio and Windows Vista (with 7,000+ new API's) released and Silverlight, Dynamic Language Runtime, Core-CLR, yet another version of Ble ... [ read more ]


OK, this is ridiculous!  Why wasn't this information funneled out to the VB MVP's (and other VB'ites like myself)?  How is it that the first word of this is stated in public by none other than Miguel de Icaza (yes, the mono project guy)? What am I talking about here?  Well according to Miguel , he discovered that the Javascript compiler that is used by the DLR (Dynamic Language Runtime) that will be utilized initially in Silverlight 1.1 is written in VB.  Yes, ... [ read more ]


After running Vista x64 on another machine for a few days; installing various pieces of critical software and seeing that everything seemed to be working smoothly... I've made the full leap on my main desktop machine (the one that now has 4GB of memory). Some interesting "facts": Windows Experience Index reports my processor running at a 5.0 (was 4.9 in 32-bit). Memory running at a 4.8 (was 4.6 in 32-bit). I have 66% of my memory free while running Outlook, Visual Studio 2005 ... [ read more ]


I installed Windows Vista Ultimate (x64) last night and everything went pretty smoothly.  This, of course, is on the second machine I have on my desk so I can see what works (and doesn't) before making the full jump on the main machine.  Out Of The Box Experience After the installation and major Windows Update updates, the only thing not working out of the box was my sound card.  I don't know if it was because I technically had two different sound cards in the box, b ... [ read more ]


Caleb has sort of let the cat out of the bag ... Introducing My.Vista. There are over 7,000 new API's in Windows Vista.  Some of them are immediately obvious while others are deep beneath the surface.  I rather enjoy digging around in Windows API land, however, many people don't care to do this so this area is usually off limits to them.  Wouldn't it be nice if there were an easy way to access these from your .NET application?  I've been doing a presen ... [ read more ]


I need to run it through it's paces, but I now have a VS2005 macro that will, whenever I successfully build a release mode project, package the project folder into a zip file named [ProjectName]_src_v[OutputAssemblyFileVersion].zip.  And it doesn't require anything additional to be installed on the machine.  And it's not using the zip functionality from the J# libraries either.  This thing is all about leveraging the zip functionality that is built into Windows XP and ... [ read more ]


I applaud this guys enthusiasm, however, his discovery/technique is something I would strongly urge you to avoid.  There are two major reasons for this: Doesn't work as a "regular user". Will cause you MAJOR support issues as Windows Vista gains momentum.  See reason #1. I've been using a similar technique in XboxFriends in order to handle automatic update from a single assembly deployment.  So for those wondering how this was working, Ralf's p ... [ read more ]


A couple of days ago a noticed this article, downloaded the code, thought about it for a bit and realized that although he had a great idea... I had a few problems with the implementation.  I really distaste the idea of "unsafe" code unless there is absolutely no way around using it... and even then I'd probably choose to implement a solution using C/C++ if that was the case.  I also didn't like the fact that he was using GetEnumerator instead of using the muc ... [ read more ]


Like I stated, don't trust someone elses benchmarks. ;-) Don't get me wrong, in my testing, VB still seems to be a hair faster; but now only by a very slim margin (less than 400ms across all tests).  Please keep in mind that I did not come up with this suite of tests; rather just doing my part to validate the results (since they original results didn't seem to make since to me in the first place). After going to bed last night, I couldn't help to be bothered by the result ... [ read more ]
I so love benchmarks.  There supposed to give us an idea, albiet rough sometimes, about the differences in choosing one thing over another.  By looking at the comparitive numbers, we should be able to make an intelligent decision regarding raw performance.  However, sometimes the tests are a bit skewed.  Case in point, I came across a benchmark .  Not just any old benchmark, but rather one that a company selling a C#->VB converter points to and uses it as the #1 ... [ read more ]


A lot of new stuff available today.  You have the next .NET Framework available .  I also see that the official announcement from Telligent regarding BlogMailr , a free tool that allows you to utilize email to post your blog entries.  Talking with Rob, this seems like a pretty cool idea... so jump over there and give it a look see. So I was going to wait until this Saturday to announce some new things here... Obviously you can see I've made the switch to Community Se ... [ read more ]


(OK, since I lost this post due to other circumstances... here it goes again. - Here's your chance to answer it again.) I can't remember exactly what my questions were, so here goes... Have you used any of the C# to VB conversion utilities available (web-based, etc.)?  If so, what was your overall impression and success rate?  Do you prefer one over another?  If you could pick anything to improve what would it be? (Sorry to those that posted comments already, they got ... [ read more ]


I just noticed in the mono-vb mailing list that Miguel de Icaza announced that: In the next couple of days, I will remove mbas, the Visual Basic runtime and the various other incomplete forks of mbas that we have on the mcs tree from the tree as they are outdated, no longer under development, unmaintained and buggy.     We will replace this with two new components: * Mainsosft's new fresh VB runtime. This fresh VB runtime was written by Rafael Mizrahi and Boris Kir ... [ read more ]


According to Brad Abrams , the Windows Forms documentation team published a new whitepaper about how to create a great layout using the new features of the WinForms in .NET 2.0... meaning you don't have to create the same old “grey” applications everyone has come to know and love. ;-) I've read through it and it's got some great information.  Especially if your interested in knowing how to tweak the new toolstrip control to look however you wish. Although the article is ... [ read more ]


Obviously I've been pretty swamped with work and everything else... including working on XboxFriends.  Here is an image that demonstrates the ToolTip control that is included with Visual Studio 2005 utilizing the information in this article to display a snapshot of information that can add a lot of bang for the buck. Yes! That is a “STANDARD” ToolTip control!


In the last two days, I've encountered at as many instances where certain members within Microsoft just ain't showin' us VB users any love. The latest Microsoft Download Notifications email states: Download the Complete DirectX SDK This software development kit includes the DirectX Runtime and the software you need to create DirectX-compliant applications in C/C++ and C#. The Updater Application Block: Downloads: Home on GotDotNet.com states: There is no Enterprise Library 2. ... [ read more ]


There are a couple of options available for signing your ClickOnce application: When the signing options screen appears (which it does whenever you save a manifest file using MageUI.exe), you'll probably be tempted to use one of the “stored certificates”.  This is probably OK if you never plan on switching machines or changing your overall network environment.  So do yourself a favor and use this dialog to at least create a [name].pfx file for use with the ClickOnce ... [ read more ]
Now that I'm running Vista (Beta 2), I'm obviously doing development in that environment as well.  A couple of things that I've noticed (and, honestly, haven't dug too deeply just yet... so these are initial impressions) is the following: 1. To get the cool “glowing” active command button effect, you need to set the FlatStyle of the button to System. 2. I'm working inside of XboxFriends tonight and decided to mimic the menu effect of Vista type applications; meaning they ar ... [ read more ]


I've been getting a lot of requests to discuss how to create the custom formatted tooltip that is being used in XboxFriends.  I have created a step-by-step article explaining how to create these beauties.  As a preview, here's a screen shot. It's actually pretty straight forward once you understand the basics.  You can go here to read the article .


You know, I'm all for making some things available for free; but at the same time want to protect my “property” as much as possible.  With great tools such as Reflector being available; you really need to consider using obfuscation to at least make it a little more difficult to reverse engineer your code.  In addition, most professional obfuscators offer the ability to encrypt embedded strings; which allows for an added level of “security”.  I quote secur ... [ read more ]


In my previous post regarding trying to use partial as a mechanism to extend existing functionality in a base user control, someone asked: “Does VB work differently or are you just assuming? Using the same namespace across 2 different assemblies (even) works perfectly fine?” Let's answer the first question.  It does appear that VB works differently than say, which in regard to this question I am assuming he is referring to, C#.  This is based on testing and, as such, is ... [ read more ]


I've used this term previously and some people have asked “What exactly does VB'ified mean“? VB'ified is a term I use to describe code that has been modified to “feel” like VB.  This may sound simplistic at first glance; however, there's a lot of areas where this term apply.   So let me point out a few of them: Window Forms Instead of blindly taking a C# Windows Form and converting it to VB, where much of the “Forms Designer Generat ... [ read more ]


As Lutz Roeder describes it, a “.NET version of an old East German Boulderdash game”.  Using the source that he put together to build from, this version is initially a port to Microsoft Visual Basic 2005 and contains new graphics done by yours truly.  In addition to a simple port, I've taken advantage of using Partial Classes to organize the code, utilize the new resource manager for images, icons and level loading and enhanced the code utilizing several other VB 20 ... [ read more ]
Someone at a presentation I presented at recently asked, "Instead of inheriting from a base control (TextBox), couldn't you just create a partial class and add the additional functionality?" It's an interesting idea; however, there are several problems associated with the idea... some technical, others not so technical.  The two biggest reasons are: 1. In my experience, you aren't really able to hijack the System namespace.  By this I mean you aren't able to write the following co ... [ read more ]


I'll be presenting at the Oklahoma City users group meetings tomorrow discussing creating feature rich custom controls (from both the UI and developer viewpoints) including System.Drawing, Generics, SmartTags and the joys of Late Binding. If your in the area, be sure to stop by and say “Hi“. :-D [ update ] You can download the associated files using the following links: Slides Samples


This guy states : “I just can't LIVE without being able to do things like:“ string oink = myHashTable[someKey] as string ; if (oink != null ) “Or“ lock ( this ) {   // yada yada yada } Hmmm... let's see.  He states that VB can't do the above by stating that he “just can't LIVE without being able to do”.  Let me write the above items in VB... Dim oink As String = TryCast (myHashTable(someKey), String) If oin ... [ read more ]
I can't help it... this crap is so wrong that it *MUST* be discussed.  It's been picked up my many people in the blogsphere and used as “reference“ material in forums.  It's wrong, wrong, wrong, WRONG!   You'd think after almost 5 months of being posted people would check their facts.  So since others apparently don't wish to do so, here goes. Where should I start?  Well, let's ignore the “ performance ” portion of this and break down a ... [ read more ]


When: December 13th, 2005 Come to the event for you chance to win a free copy of DVDs containing both Visual Studio 2005 and SQL Server 2005 !  There are *FIVE* of these to be given away, so you chance is pretty good... Who's presenting?  Good question... the answer is that Stephen Swienton (President FWDNUG and ASP.NET MVP) and Cory Smith (VP FWDNUG and VB MVP) are definitely presenting (possibly having one more person yet to be determined).  The content is essent ... [ read more ]


While working with VB 2005, I'll try to take note of the little things that help make VB stand out above other development products.  Here's one that I haven't really heard anyone speak upon and it kind of surprised me when I used it the first time.  Don't get me wrong, it was a wonderful surprise; one of those “why didn't it (the IDE) do that before” sort of thing. When you have a class that is clinging onto some resource during its lifetime, it is appropriate ... [ read more ]


With VB's snippet feature, every time you add a new snippet the coloring stays around until you close the file and re-open it.  This can quickly lead to a lot of visual clutter while your developing if you use snippets a lot.  And why shouldn't you leverage such a feature? Well, during the beta I asked about whether this would be resolved in some manner and it was a bit late in the schedule.  So I set out to figure out a possible work around.  The work around consists of a ... [ read more ]


The .NET Rocks road show was here in the Dallas/Fort Worth area a couple of days ago.  After the show, they did some interviews with the local crowd and I was hanging out with no real intention of being interviewed.  Of course, that didn't work out exactly that way and I did end up having to sit in front of the mic.  It ended up being about a 7 minute interview and was completely done impromptu... thus, I probably sound like a babbling idiot. ;-) Obviously, I recommend listenin ... [ read more ]


... and all I need to do is place the following blurb on my blog: VistaDB 2.1 database for .NET has been released This 2.1 update includes over 60 improvements, including new support for .NET 2.0 and Visual Studio .NET 2005. VistaDB is a small-footprint, embedded SQL database alternative to Jet/Access, MSDE and SQL Server Express 2005 that enables developers to build .NET 1.1 and .NET 2.0 applications. Features SQL-92 support, small 500KB embedded footprint, free 2-User VistaDB Se ... [ read more ]


While working on a side project, I decided to use VS2K5 and SQL2K5.  One of the things I needed to do was take some external data and import it into the database in a normalized manner.  I also needed to insert into some additional tables the newly (automatically) created id to link some data.  Microsoft SQL Server 2005 (and Microsoft SQL 2005 Express Edition) supports a new TSQL keyword called OUTPUT.  Here's basically what it looks like: INSERT INTO tablename (column1, c ... [ read more ]


After a ton of questions regarding the the DriveInfo examples ( Determine Hard Drive Serial Numbers and Revenge of DriveInfo ) asking how to determine other information such as CPU identification, motherboard serial number and BIOS serial numbers I'm updated the WMI version of the application to read this information.  Why the WMI version?  Well as it turns out, it appears that aren't Win32 methods to pull the CPU identification information.  The only examples I could find ... [ read more ]


...yet want to sound like they do.  I would love to see the like of Jay Roxe (Microsoft) put in a room with this Tom fellow and see the sparks fly.  This guy claims that he has the “inside” track as to what Microsoft is thinking in regards to the future of Visual Basic.  This guy just doesn't have a clue.  The MVP Summit is the “inside” track and with programs like VB Insiders existing where some people (including myself) can interact directly with ... [ read more ]


A couple of weeks ago, I started consciously paying attention to people in Microsoft presentations mention the various languages of .NET.  I noticed a couple of things: C++ is extremely rare in being mentioned. J# is usually mentioned in jest... but still very rarely. C# is usually mentioned primarily with VB mentioned secondarily. On the last point, from a historical perspective and a number of users perspective, I'd kind of expect VB to be mentioned firstly and C# secondarily. ... [ read more ]


Hmmm... how should I start this off?  Well, first things first, it was great to see Brian Randell again and his presentation skills were excellent.  Saying that, let's dig into things as a little review and then I'll do a follow up after the fact. The presentation was not exactly what I was expecting.  To me, I thought that I'd be hearing comparisons between VB6 and VB8 with compelling, no question reasons why one should make the move forward.  I also kind of expected a ... [ read more ]


Getting ready to head over to Dallas to hang out in The VB Upgrade Tour presentation .  Although I'm not needing (and haven't been needing for the past 3+ years) to upgrade from VB 6.0 to .NET, it is a topic that comes up often with user group members and various other events.  Most people already know my opinion on the particular subject of people not willing to upgrade, so I'll not dwell on that.  However, I think that events like this will help to get some people to embrac ... [ read more ]


These past couple of months have been extremely busy for me.  With work and extra-workular (yeah, I just made that up) activities, my postings here has taken a bit of a hit.  [Insert obligatory sentense here about how I'm going to get back to blogging on a regular basis.] So we have Visual Studio 2005 being released in a little over a month and the news of what is coming after the next release (language enhancements, LINQ, etc) already spreading like wildfire, so much to do and so l ... [ read more ]


The Central Region DPE team treated a large group of influencer's by hosting an event that I have to say is one of the most incredible experiences I've had a chance to participate.  The Richard Petty Driving Experience! Before I showed up, what I was thinking is that there we were going to have an instructor (read as guide) sit in the passenger seat as you went onto the track and you'd be on the one mile track alone.  Also, 120+ mph... hmmmmph... it's possible that I've driven in th ... [ read more ]


I just updated the VB.NET Coding Guidelines to include a few annotations that help to answer a few questions that people have asked.  I've also removed the ability to make comments directly on this document and they've been moved to another location.  I've copied the original comments over to this other location.  It was beginning to get a little confusing where the guidelines ended and the comments began.  This should help to clear that up.


If your in the following areas (or can be in those areas), be sure to try to attend the Visual Studio 2005 Dev Con event... St. Louis, MO (5/26), Chicago, IL (6/1), Minneapolis, MN (6/1), Kansas City, KS (6/2), Omaha, NE (6/14), Detroit, MI (6/14) and Dallas, TX (6/16) The event costs $99 to attend and you'll receive three books for attending ($90 value).  For more information, visit the official announcement . [ update ] I guess I could add that you'll get some great tra ... [ read more ]


Back in the early 80's, there was the Radio Shack Trs-80 Color Computer series of computers.  Of course, you interacted with it using Microsoft Basic (Extended Basic and eventually Disk Extended Basic).  After looking through a few old magazines I found hiding away in some boxes, I was reminded of a pretty unique method that was used to draw images upon the screen.  It has a lot of similarities with the concept of turtle graphics.  Basically, turtle graphics is the idea of d ... [ read more ]


Has anyone using Visual Studio 2005 noticed the new solution icons? Now you can see (without having to dig or experiment) what version of .NET a solution is targeting.  What a great idea.  Sometimes it's the simplest things. ;-)


I've just added a new article that was spawned by some of the responses to the Default Instances debate (just one of the ways I show in the article).  Rather than keep saying how easy Default Instances will be, I thought that it would be good to show how we would accomplish similar tasks today without them.  Showing these methods in comparison with Default Instances, I figure, could be the best “argument“ for their usage.  So, if you can think of other ways of doing this, please ... [ read more ]


S16;BM10,10R22F2G2L2BL4BU2L15G2BE2 H2BF2BG2L4H2E2R3U4R3L6R3D4R2E1R2 U1R2E1R2R1R2F1R2D1R2F1R2U4R3L6R3 D4L2R1G2F2R2 Does anyone have any idea the above represents and where it comes from?  If you don't know for sure, what would you guess it is? Note: I know what it is, but before explaining it and tell you what I've been playing around with, I'm curious if the above jogs anyone's memory.  If I give to many details, it might spoil the responses. ;-) [ update ] I've posted the wor ... [ read more ]


Yes, you read that correctly!  VB 2005 will have full support for refactoring in the form of a community edition of Refactor! for Visual Basic 2005 .  Refactoring tools include: Rename ( Native to VB 2005, not a part of Refactor!. ) Reorder Parameters Extract Method Extract Property Create Overload Surrounds With Encapsulate Field Reverse Conditional Simplify expression Introduce Local Introduce constant Inline Temp Replace Temp with Query ... [ read more ]


After the last article I pointed out , it's refreshing to see this... VB vs. C# MSIL Code Generation: Are the results equal? He discusses differences in the CIL created by VB and C#.  He attempts to offer some insight as to why the difference exists.  I'm not going to say the article is complete in the dissection of the subject.  However, it serves as a great introduction on the subject and, for those interested, could spawn some late night adventuring into the world of IL ... [ read more ]


© 2005 Serge Baranovsky. All rights reserved.
All feed content is property of original publisher. Designated trademarks and brands are the property of their respective owners.

This site is maintained by SubMain(), a division of vbCity.com, LLC