vb.net

Visual Basic - Object reference not set to an instance of an object

I'm receiving the following error in VB.Net. "Object reference not set to an instance of an object" It highlights "Next" at the end of the For Loop. Any help would be great. Imports System.IO Public Class LoginForm Dim Username() As String Dim Password() As String Dim Index As Integer Public Function encrypt(ByVal da...

You are not authorized to view this page active directory problem

I am getting the following error while browsing my asp.net page deployed in IIS..I am using active directory data retrieval in my website and credentials to the active directory is stored in the web.config file ... You are not authorized to view this page You do not have permission to view this directory or page using the credentials th...

How do I create a Windows Service using vb.net in Studio 2008 Standard (No template)

Hello, I want to create a Windows Service using VB.Net, but in VS2008 Standard, you don't seem to get the "Windows Service" template I've used before. What's the best way of creating such a service, without resorting to using the C++ template? Thanks ...

C function in VB.NET

I'm having some problems calling a C function from a DLL, and was hoping someone could help me out. The function is returning -101 which translates as a "bad parameter". The values I am passing have been returned from another, successful function call, so my current assumption is that I've built the structure incorrectly. Any help is ...

Is there a quick way to pull all of the users from Active Directory?

I'm trying to pull the username of every user available through active directory. Here is the code my colleague first tried to use, but this method is burning all of the memory out and throwing out of memory exceptions. Is there a quick alternative? Dim userList As ArrayList = New ArrayList Dim sPath As String = "LDAP://test.ca/OU=foo...

Connecting to SOTAMAS90 ODBC ?

How do I connect to Mas90's file using their ODBC that they setup - SOTAMAS90? how do I do this in vb.net ? ...

What is the definition of ":=" in vb

I came across some sample code in VB.Net which I have some experience with and kinda having a duh moment figuring out the meaning of :=. RefreshNavigationImages(bForward:=True, startIndex:=-1) The sig for this method is RefreshNavigationImages(boolean, int). Is this a default value if null? Like "bIsSomething ?? false"? Tried to bin...

Visual Studio AutoComplete simulates enter being pressed when selecting

Visual studio nicely provides built-in auto-complete functionality for text boxes and combo boxes. I am using the suggest method of auto complete that provides the user with a list of choices filteres by what they have type. The problem I am having is that when the user makes a selection (via the mouse) VS places the selected text into ...

Free or commercial code analysis service for Visual Basic

Anyone know a good code analysis service or tool for vb.net? Like the one for c# with visual studio 2008 team edition or style cop for c# Update: My bad ,I am only using the visual studio pro in my new work place,so I could not use the code analysis for visual studio 2008 team edition ...

VB 2008 & Debugger ?

using vb.net 2008 When I put a break on a line and then press F5 the debugger does break on the line which I put the Break (F9) but Step In (F8) as well as F5 are grayed out, not working, as well as a bunch of other debug tools. Any clue why this is? Is there a setting that needs to be set? ...

Sending emails with VB.NET

I am building a room booking system for my college and I would like to send out an email when a teacher books a room to remind them. I have found one on the internet at this link: http://www.osix.net/modules/article/?id=377 But when I try and use that code I get an error: "Value of type 'String' cannot be converted to 'System.Net.Mail....

Raising event in custom control.

Hi all, I'm writing a custom textblock control thats populate hyperlinks and raises event when clicked to hyperlink. I wrote this code but I got stucked. My code is : Imports System.Text.RegularExpressions Public Class CustomTextBlock Inherits TextBlock Public Event Klik As EventHandler(Of EventArgs) Public ReadOnly InlineCollection...

Regex with vb.net

Hi, I have the following html contained in a string. <tr>    <td>Hello</td> </tr> <tr>    <td>World</td> </tr> <tr>    <td>lets all smile</td> </tr> I would like to use RegEx to find the <tr></tr> that contains the text "World". The difficulty is that there might be other <td> around the one that contains the search text....

Does an exception inside a TRY block break its execution?

I'm importing several fields, and that is, about 25 lines of code each importing one field (in my case, there's really no other way). It's in a try-catch block, but there are some times, that this field doesn't exist in the source, but I have to get the rest. from 20. I get 10 the 11th one doesn't exist (exception) I still need from 12 ...

Accessing XML file using JavaScript And ASP.net |VB code

Am trying to read in data from an xml file but using javascript which is embedded into my asp.net|vb code. I am new to asp.net but coming from a programming background. so I declared the xml objects for the appropriate browsers, as well as the name of the local xml to read data from, I then start by appending the create the table tag a...

Auto Suggested Text Box with concatenated string with LINQ to SQL

Hi, I'm creating a text box with auto-suggested. So, it works well. It suggests only first name, but I want it to suggest the full name (first and last name which two different columns). Take a look at the following code behind that worked as expected : <System.Web.Services.WebMethod()> _ Public Shared Function GetNames(ByVal prefixTex...

Accessing Internet Explorer using vb.net

I'm trying to create a little executable that when launched opens an IE browser to various websites like news sites all in different tabs. for example, a tab for wsj, nytimes, etc. How do I access IE with vb.net? What reference do I need to add? I can't find any sample code that I can make work I think it is because I am missing a lib...

opening/printing tiff files in VB.NET Visual Studio 2005

I'm trying to use my existing application to open tiff files for clients and staff in order to print or view the reports that we have scanned into our server. Unfortunately I have been unable to find a free, preferably open source library or wrapper for a library that will work in VB.NET running through Visual Studio 2005. Does anyone k...

LDAP Gettling a list of logon names

I have the need in my program to get the list of user logon names in a group. This is what I have so far but it only returns all the users...which I need cut down to those in a group, of which i have the name of. Option Explicit On Imports System.DirectoryServices Imports System.DirectoryServices.ActiveDirectory Module Module1 ...

ProAspCompLib.dll - what is this for?

Trying to dissect a very badly written ASP.NET app. Can someone tell me what this assembly (ProAspCompLib.dll) is used for? ...