Hi Phillip,
The problem i'm facing is that i dont know how to point my aspx.vb files to
any dlls in the bin folder, no matter where i place the bin folder.
Nothing is stored on the IIS server, everything is on the network share.
When i create an application, i can change the codebehind to
src=file.aspx.vb that finds the vb files. But how do i tell my application
to go to the bin folder and look for the dll?
my application looks like this:
ASPX file (main.aspx)
===================================================
<%@ Page Language="vb" AutoEventWireup="false" src="main.aspx.vb"
Inherits="main"%>
ASCX control (login.ascx)
===================================================
<%@ Control Language="vb" AutoEventWireup="false" Src="login.ascx.vb"
Inherits="login"
TargetSchema="
http://schemas.microsoft.com/intellisense/ie5" %>
ASCX.VB file
===================================================
Imports Datalib
Imports System.Web.Security
Imports Datalib.NSaccess
Public Class login
Public str As String
Private Sub button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles button1.Click
Dim da As DataClass = New DataClass
<------------------------------------------------------------------------this
is where i get an error.
Dim valid As Boolean = da.validateuser(textbox1.Text, textbox2.Text)
Session("str") = textbox1.Text
' str = Session("str")
If valid Then
Response.Redirect("display.aspx")
Else
label1.Text = "Invalid username or password"
End If
End Sub
End Class
=====================================================
The Datalib is the dll placed in the bin folder. It has code to connect to
the database.
ERROR:
Server Error in '/' Application.
--------------------------------------------------------------------------------
Security Exception
Description: The application attempted to perform an operation not allowed
by the security policy. To grant this application the required permission
please contact your system administrator or change the application's trust
level in the configuration file.
Exception Details: System.Security.SecurityException: Request failed.
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Is it even possible to run Dlls of a share or does it have to be local to
the IIS server? The share is a NETAPP.
Hope im making sense.
thanx
Phillip Williams said:
Hello rvegas,
My previous message was only to explain the use of the Inherits attribute
in
the page class to avoid renaming classes when the folder names change.
As for your question, I think you are trying to use an assembly from one
web
application within its parent web application. (Did I understand it
correctly?) If so then this cannot be solved by defining namespaces. An
ASP.NET application uses assemblies that are either in its own bin folder
or
in the GAC
http://msdn.microsoft.com/library/d...-us/cpguide/html/cpconglobalassemblycache.asp