hi, I hope someone can help me with this please
I'm trying to move my codebehind files to a folder other than the one
my webform sits in. I've tried changing the 'scr' page level attribute
of my webform, but i get the following parser error;
Parser Error Message: 'c:\WebForm2.as px.vb' is a physical path.
this the code;
<%@ Page Language="vb" AutoEventWireup ="false"
src="c:\WebForm 2.aspx.vb" Inherits="mywor k"%>
Is my syntax for the physical path incorrect? I know it might seem
like a silly question, but what IS the correct syntax? Also, how do i
move this codebehind file?
many thanks
m 6 1851
Try setting the source the same way you would set a link in a web site:
"codebehindfold er/WebForm2.aspx.v b"
Or if the folder is back one folder from the .aspx file:
"../codebehindfolde r/WebForm2.aspx.v b"
Sincerely,
--
S. Justin Gengo, MCP
Web Developer
Free code library at: www.aboutfortunate.com
"Out of chaos comes order."
Nietzche
"Maurice Walmsley" <mb********@hot mail.com> wrote in message
news:92******** *************** ***@posting.goo gle.com... hi, I hope someone can help me with this please
I'm trying to move my codebehind files to a folder other than the one my webform sits in. I've tried changing the 'scr' page level attribute of my webform, but i get the following parser error;
Parser Error Message: 'c:\WebForm2.as px.vb' is a physical path.
this the code; <%@ Page Language="vb" AutoEventWireup ="false" src="c:\WebForm 2.aspx.vb" Inherits="mywor k"%>
Is my syntax for the physical path incorrect? I know it might seem like a silly question, but what IS the correct syntax? Also, how do i move this codebehind file?
many thanks
m
So you have to make your code behind files available on the web (and hope
that IIS filters won't serve them). So much for security...
Jerry
"S. Justin Gengo" <sj*****@aboutf ortunate.com> wrote in message
news:e%******** ********@tk2msf tngp13.phx.gbl. .. Try setting the source the same way you would set a link in a web site:
"codebehindfold er/WebForm2.aspx.v b"
Or if the folder is back one folder from the .aspx file:
"../codebehindfolde r/WebForm2.aspx.v b"
Sincerely,
-- S. Justin Gengo, MCP Web Developer
Free code library at: www.aboutfortunate.com
"Out of chaos comes order." Nietzche
"Maurice Walmsley" <mb********@hot mail.com> wrote in message news:92******** *************** ***@posting.goo gle.com... hi, I hope someone can help me with this please
I'm trying to move my codebehind files to a folder other than the one my webform sits in. I've tried changing the 'scr' page level attribute of my webform, but i get the following parser error;
Parser Error Message: 'c:\WebForm2.as px.vb' is a physical path.
this the code; <%@ Page Language="vb" AutoEventWireup ="false" src="c:\WebForm 2.aspx.vb" Inherits="mywor k"%>
Is my syntax for the physical path incorrect? I know it might seem like a silly question, but what IS the correct syntax? Also, how do i move this codebehind file?
many thanks
m
Unless there's a bug in the filter. If you could have your code-behind in a
location that's not available on the web (like Maurice is trying to do) you
would not have to worry about this.
Jerry
"Kevin Spencer" <ke***@takempis .com> wrote in message
news:O%******** ********@TK2MSF TNGP10.phx.gbl. .. If you set up your filters correctly, there is no security issue. What
he's doing is a perfectly legitimate use of ASP.Net.
-- HTH,
Kevin Spencer Microsoft MVP .Net Developer http://www.takempis.com Neither a follower nor a lender be.
"Jerry III" <je******@hotma il.com> wrote in message news:uH******** ******@TK2MSFTN GP10.phx.gbl... So you have to make your code behind files available on the web (and
hope that IIS filters won't serve them). So much for security...
Jerry
"S. Justin Gengo" <sj*****@aboutf ortunate.com> wrote in message news:e%******** ********@tk2msf tngp13.phx.gbl. .. Try setting the source the same way you would set a link in a web
site: "codebehindfold er/WebForm2.aspx.v b"
Or if the folder is back one folder from the .aspx file:
"../codebehindfolde r/WebForm2.aspx.v b"
Sincerely,
-- S. Justin Gengo, MCP Web Developer
Free code library at: www.aboutfortunate.com
"Out of chaos comes order." Nietzche
"Maurice Walmsley" <mb********@hot mail.com> wrote in message news:92******** *************** ***@posting.goo gle.com... > hi, I hope someone can help me with this please > > > I'm trying to move my codebehind files to a folder other than the
one > my webform sits in. I've tried changing the 'scr' page level
attribute > of my webform, but i get the following parser error; > > Parser Error Message: 'c:\WebForm2.as px.vb' is a physical path. > > this the code; > <%@ Page Language="vb" AutoEventWireup ="false" > src="c:\WebForm 2.aspx.vb" Inherits="mywor k"%> > > > Is my syntax for the physical path incorrect? I know it might seem > like a silly question, but what IS the correct syntax? Also, how do
i > move this codebehind file? > > many thanks > > m
hi all,
thanks for the answers.
I never concidered removing them from the current file to protect them
from web access, but so that I could have my vb files in a central
location (just like classic asp and include files).
I still can't get this to work, though. The issue seems to be with my
use of an absolute path as the src of the codebehind[1] file.
I've tried navigating using relative paths, but get this parser error;
"Cannot use a leading .. to exit above the top directory"
I've tried absolute paths; [src="c:\WebForm 2.aspx.vb"], but get;
"Parser Error Message: 'c:\WebForm2.as px.vb' is a physical path"
The whole point is code 'behind'. I'm sure there is a way to do this,
I just havent found the right syntax/way yet.
cheers
maurice
[1]ofc, the codebehind attrubiute is only used by VS.NET, not the
asp.net page/form itself. The page needs the src attribute.
correct me someone if im wrong but I think not because it works for me
if you are doing that for security reasons, then its not necessary
When you build your app, your dll contains the compiled codebehind so you
can erase the ".aspx.vb" if you wish, you dont need them there.
Just leave the .config, .aspx, global.asax and other configuration files
Xavier
Costa Rica
"Maurice Walmsley" <mb********@hot mail.com> wrote in message
news:92******** *************** ***@posting.goo gle.com... hi, I hope someone can help me with this please
I'm trying to move my codebehind files to a folder other than the one my webform sits in. I've tried changing the 'scr' page level attribute of my webform, but i get the following parser error;
Parser Error Message: 'c:\WebForm2.as px.vb' is a physical path.
this the code; <%@ Page Language="vb" AutoEventWireup ="false" src="c:\WebForm 2.aspx.vb" Inherits="mywor k"%>
Is my syntax for the physical path incorrect? I know it might seem like a silly question, but what IS the correct syntax? Also, how do i move this codebehind file?
many thanks
m
No need for the .vb or .cs
need .dll, .aspx, .config, .asax, images, etc....
"Xavier MT" <xm*****@hotmai l.com> wrote in message
news:Oe******** *****@TK2MSFTNG P09.phx.gbl... correct me someone if im wrong but I think not because it works for me if you are doing that for security reasons, then its not necessary When you build your app, your dll contains the compiled codebehind so you can erase the ".aspx.vb" if you wish, you dont need them there. Just leave the .config, .aspx, global.asax and other configuration files
Xavier Costa Rica
"Maurice Walmsley" <mb********@hot mail.com> wrote in message news:92******** *************** ***@posting.goo gle.com... hi, I hope someone can help me with this please
I'm trying to move my codebehind files to a folder other than the one my webform sits in. I've tried changing the 'scr' page level attribute of my webform, but i get the following parser error;
Parser Error Message: 'c:\WebForm2.as px.vb' is a physical path.
this the code; <%@ Page Language="vb" AutoEventWireup ="false" src="c:\WebForm 2.aspx.vb" Inherits="mywor k"%>
Is my syntax for the physical path incorrect? I know it might seem like a silly question, but what IS the correct syntax? Also, how do i move this codebehind file?
many thanks
m
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Brian |
last post by:
I need to import data from 720 csv files into an Access database so I can do
some editing prior to loading into a SQL Server. These files came from data
output from a mainframe on a monthly basis. There are 15 files created each
month with each file containing specific data.
What I started to do is store the files by year and then by month so I new
when the data is based on. I have linked the table to the database and them
append the...
|
by: Janderlen |
last post by:
Hi,
Im start to learning c#.... My question is
I have a webform1.asp
¿What are the difference between write code c# inside the codebehind of the page (webform1.aspx.cs), and write c# code inside the tab "html" page like <script language=c#> (webform.aspx) ......
Thanks a lot
|
by: Graham Allwood |
last post by:
I'm reading the Essential ASP.NET book by Fritz onion and he says that when
VS.NET creates a new .aspx page for you is uses the codebehind attribute on
the Page directive rather than the src attribute. From what I understand the
src attrib is standard ASP.NET but the codebehind attribute is only
understood by VS.NET. Doesn't this make the pages (source code) less
portable? Is there any reason for this?
Hope someone can help.
|
by: A.M |
last post by:
Hi,
Using VS.NET 2003, If i use SRC page attribute instead of CodeBehind, do i
still have intelisence and generally IDE support for that?
Thanks,
Ali
|
by: nevets2001uk |
last post by:
Hi. I've just started my second ASP.NET (VB) app and I'm using
codebehind this time.
I'm not using visual studio but am instead coding it all in notepad
(HTML, ASP.NET and CSS)
I'm trying to understand how to best use codebehind to do what I want
to achieve. Basically, so far I have a codebehind file for one page
which works as I wanted but I want other pages to share that
codebehind file. That's no problem except I want each one to...
| |
by: Wardeaux |
last post by:
All,
Wanting to find a way to create web pages to add to my website without
having to recompile the codebehind everytime I want to add a new one...
Here's the deal:
I have a web app that takes work orders for 7 different items, each item
gets 1 page for input specs. All works well. I want to add a new item. I
do not want to recompile and redistribute my app everytime just to add a new
input page. Can ASPX resources be compiled into a...
|
by: One Handed Man \( OHM - Terry Burns \) |
last post by:
I want to know if there is any way to specify the location of the class
files in a directory off the route. It is possible to drag the class files
to the Code directory and have it compile OK, unfortunately the designer
kicks up when you try to load the form ( in the root dir ) with the class
files somewhere else. I have tried doing a "..\Code\Webform1.aspx.vb" for
the attribute and several derivitives thereof, but this fails.
Anyone...
|
by: Thomas Andersson |
last post by:
Hi all,
I've been thinking of about adding new languages to our website and is
currently investigating how this could be done. And I know that one way to go
would be to create new aspx-pages with new codebehinds for each page I want
to have translated.
But my question is - is it ok to keep the same codebehind file for a certain
page which is translated into different languages. In this way I only need to
change to aspx-file (html) of...
|
by: Arsalan |
last post by:
Where is Codebehind usually uploaded? Suppose I have aspx pages containing
codebehind in different directories for e.g
myweb/aaa
myweb/bbb
Where do i store the compiled codebehind?
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |