Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Add reference to a VB.net

Posted on 2006-07-17
4
Medium Priority
?
966 Views
Last Modified: 2006-11-18
Hi!
I need to add a reference to a dll file in my codebehind file.(E.g. reference to System.DirectoryServices.dll in default.aspx.vb file) I know how to do this in Visual studio, but how do you do this in a texteditor like notepad??
Please help me on this one..
0
Comment
Question by:frodehoe
  • 2
4 Comments
 
LVL 23

Accepted Solution

by:
apresto earned 1200 total points
ID: 17121933
Hi frodehoe,

open the vbprog file in notepad

scroll to the <References> Node

and put something like this in there:

<Reference
                    Name = "System"
                    AssemblyName = "System"
                    HintPath = "..\..\..\..\WINNT\Microsoft.NET\Framework\v1.1.4322\System.dll"
                />

obviously changing it for your dll

Apresto
0
 

Author Comment

by:frodehoe
ID: 17122148
Thanks for the quick answer, but I still got the same error. Shouldn't I put this in the codebehind file somewhere?
I use a asp.net file Search.aspx and a codebehind file Search.aspx.vb
0
 
LVL 23

Assisted Solution

by:apresto
apresto earned 1200 total points
ID: 17122168
you will need to recompile the project before it will take effect - have you recompiled
0
 
LVL 7

Assisted Solution

by:skvikram
skvikram earned 300 total points
ID: 17122617
The codebehind file should be named like Search.vb add the following

Imports System.DirectoryServices
Public class CodeBehind
End class

the search.aspx will contain following page directive

<%@ Page Inherits="CodeBehind" Src="Search.vb" %>

Alternatively in search.aspx you can have the following page directive
<%@ Import Namespace="System.DirectoryServices"%>
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I recently went through the process of creating a Calendar Control of events with the basis of using a database to keep track of the dates that are selectable, one requirement was to have the selected date pop-up in a simple lightbox.  At first this…
IntroductionWhile developing web applications, a single page might contain many regions and each region might contain many number of controls with the capability to perform  postback. Many times you might need to perform some action on an ASP.NET po…
Integration Management Part 2
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …
Suggested Courses

824 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question