vb.net

Client View of Everyone Looking at a Webpage

First let me say that I really feel directionless on this question. I am using windows integrated security, and I can use vb.net to look up information about a user from AD. I also have other information about users I can look up from a MS SQL 2005 server by getting the logon identity name. What I would like to do is display information...

IE Automation Book or Resource?? using MSHTML/ShDocVw VB.Net

Can anyone recommend a book or a website that explains Internet Explorer Automation using VB.NET? I understand that mshtml and ShDocVw.dll can do this, but I need a resource that will explain it to me. I want to read/write values as well as click buttons. The only book I have come across so far is .Net Test Automation Recipes. Is this t...

What is the C# version of VB.net's InputDialog?

What is the C# version of VB.net's InputDialog? ...

How do I capture an asterisk on the form's KeyUp event? OR, How do I get a KeyChar on the KeyUp event?

I'm trying to hijack an asterisk with the form's KeyUp event. I can get the SHIFT key and the D8 key on the KeyUp event, but I can't get the * out of it. I can find it easily in the KeyPress event (e.KeyChar = "*"c), but company standards say that we have to use the KeyUp event for all such occasions. Thanks! ...

Yield In VB.NET

C# has the keyword called yield. VB.NET lacks this keyword. I am curious how some of the VB programmers have gotten around the lack of this keyword. Do you implement your own iterator class? Or do you try and code to avoid the need of an iterator? The yield keyword does force the compiler to do some coding behind the scenes. http://...

Using an ASP.NET SiteMap for a Page with multiple paths

I have a certain page (we'll call it MyPage) that can be accessed from three different pages. In the Web.sitemap file, I tried to stuff the XML for this page under the three separate nodes like this: < Page 1 >   < MyPage / >   ... < /Page 1 > < Page 2 >   < MyPage / >   ... < /Page 2 > < Page 3 >   < MyPage / >   ... < /Pag...

Why do C# and VB have Generics? What benefit do they provide? Generics, FTW

From Wikipedia: Generic programming is a style of computer programming in which algorithms are written in terms of to-be-specified-later types that are then instantiated when needed for specific types provided as parameters and was pioneered by Ada which appeared in 1983. This approach permits writing common function...

What's a good f/oss GDI+ (System.Drawing) based graphing and charting component for .NET?

I want to create basic line, bar, pie and area charts for .NET 3.5 WinForms and I'm interested in finding a free, mature, open-source .NET (preferably C# based) project to help me accomplish that. I would consider a WPF based project, however I'm more comfortable in GDI+ so I'd rather it used System.Drawing and/or GDI interop as its bas...

VB.Net "There is a naming violation" Error with open ldap for creating user

I am trying to use directory services to add a directory entry to an openldap server. The examples I have seen look pretty simple, but I keep getting the error "There is an naming violation". What does this message mean? How do I resolve it? I have included the code, ldif file used to create the person container. Public Function Ldap_...

How do I get the mac address or IPAddress from a cisco callmanager?

Hi everyone is there a way to retrieve either the mac address or the IPAddress of phones on a Cisco server using Callmanager version 6 via the axl with VB.net? The server can retrieve the IPaddress itself to use the phone and it's not in the database information retrieved from the server. ...

Moving to ASP.NET - VB or C#?

We have a large ASP classic code base but I'm looking to do future development in ASP.NET (and potentially in the future port across what we have). The natural choice of language seems to be VB (existing code is VBScript) but am I being too hasty? Does the choice of language, in the long run, even make a difference? ...

Why is there not a ForEach extension method on the IEnumerable interface?

Inspired by another question asking about the missing Zip function: Why is there no ForEach extension method in the Enumerable class? Or anywhere? The only class that gets a ForEach method is List<>. Is there a reason why it's missing (performance)? ...

Hidden Features of VB.NET?

I have learned quite a bit browsing through Hidden Features of C# and was surprised when I couldn't find something similar for VB.NET. So what are some of its hidden or lesser known features? ...

How do I work with quarters (quarterly dates) in ASP.Net using VB.Net 2.0?

I know that Sql Server has some handy built-in quarterly stuff, but what about the .Net native DateTime object? What is the best way to add, subtract, and traverse quarters? Is it a bad thing™ to use the VB-specific DateAdd() function? e.g.: Dim nextQuarter As DateTime = DateAdd(DateInterval.Quarter, 1, DateTime.Now) Edit: Expanding...

Prevent a PostBack from showing up in the History

I have a page where I submit some data, and return to the original form with a "Save Successful" message. However, the user would like the ability to return to the previous page they were at (which contains search results) by clicking the browser's Back button. However, due to the postback, when they click the Back button they do not g...

C# VB.NET Conversion

Which tools do you use to convert between C# and VB.NET? ...

Simple way to parse a person's name into its component parts?

A lot of contact management programs do this - you type in a name (e.g., "John W. Smith") and it automatically breaks it up internally into: First name: John Middle name: W. Last name: Smith Likewise, it figures out things like "Mrs. Jane W. Smith" and "Dr. John Doe, Jr." correctly as well (assuming you allow for fields like "prefix" a...

Is there a way to programatically determine if a font file has a specific Unicode Glyph?

I'm working on a project that generates PDFs that can contain fairly complex math and science formulas. The text is rendered in Times New Roman, which has pretty good Unicode coverage, but not complete. We have a system in place to swap in a more unicode complete font for code points that don't have a glyph in TNR (like most of the "str...

How Do VB.Net Optional Parameters work 'Under the hood'? Are they CLS Compliant?

Let's say we have the following method declaration: Public Function MyMethod(ByVal param1 As Integer, _ Optional ByVal param2 As Integer = 0, _ Optional ByVal param3 As Integer = 1) As Integer Return param1 + param2 + param3 End Function How does VB.NET make the optional parameters work within the confines of the CLR? Are...

Using multiple web projects with different languages in Visual Studio

I need to combine a VB web project and a C# web project and have them run alongside each other in the same web root. For instance, I need to be able to navigate to localhost:1234/vbProjPage.aspx and then redirect to localhost:1234/cSharpProjPage.aspx. Is this possible from within Visual Studio 2008? I know you have the ability to crea...