Greetings,
I have a web application that has a folder with a section of my web
application. How can I reference a user control that is one level up in the
directory structure?
<%@ Register TagPrefix="PHM" Tagname="Header Menu" src="HeaderMenu .ascx" %>
but, "HeaderMenu.asc x" is in the parent folder of the folder this aspx
document is in.
Thanks,
-Dave 3 1531
Hello Dave,
as long as the acsx file is still within the project you can use the '~'
shortcut. Which expands to the root dir of your project.
so lets say for example you have
-/ (root project)
|
|- controls/
| |
| |--headerMenu.ascx
|
|-directory1/
|
|-directory2/
|
|--file1.aspx
file1.aspx should have something like <%@ Register ... src="~/controls/headermenu.ascx "
%>
-john Greetings,
I have a web application that has a folder with a section of my web application. How can I reference a user control that is one level up in the directory structure?
<%@ Register TagPrefix="PHM" Tagname="Header Menu" src="HeaderMenu .ascx" %>
but, "HeaderMenu.asc x" is in the parent folder of the folder this aspx document is in.
Thanks,
-Dave
I figured it out. It should be
"../HeaderMenu.ascx "
Although I now have a new question in a new post.
-Dave
"Dave" <no****@yahoo.c om> wrote in message
news:eC******** ******@TK2MSFTN GP12.phx.gbl... Greetings,
I have a web application that has a folder with a section of my web application. How can I reference a user control that is one level up in the directory structure?
<%@ Register TagPrefix="PHM" Tagname="Header Menu" src="HeaderMenu .ascx" %>
but, "HeaderMenu.asc x" is in the parent folder of the folder this aspx document is in.
Thanks,
-Dave
John,
Great! You answered my other question too. Thanks!
-Dave
"john morales" <jmorales@NO_SP AM-gmail-R3M0VE_TH1S.com > wrote in message
news:66******** ************@ms news.microsoft. com... Hello Dave,
as long as the acsx file is still within the project you can use the '~' shortcut. Which expands to the root dir of your project.
so lets say for example you have
-/ (root project) | |- controls/ | | | |--headerMenu.ascx | |-directory1/ | |-directory2/ | |--file1.aspx
file1.aspx should have something like <%@ Register ... src="~/controls/headermenu.ascx " %>
-john
Greetings,
I have a web application that has a folder with a section of my web application. How can I reference a user control that is one level up in the directory structure?
<%@ Register TagPrefix="PHM" Tagname="Header Menu" src="HeaderMenu .ascx" %>
but, "HeaderMenu.asc x" is in the parent folder of the folder this aspx document is in.
Thanks,
-Dave
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Patrick Robinson |
last post by:
Can anyone explain how i can refer to another package that is at the
same 'level' in the directory structure as the one doing the
referring. i.e given the package structure: -
basedir
| |
package1 package2
how can i gain access to a class within package2 from within a source
file from package1 -- i only seem to b able to access classes within
|
by: anonymous |
last post by:
Hi all,
I've been searching the way to achieve the following task.
But no luck so far.
I have a web site(main site), which requires authentication. This
authentication is set at Windows directory level, so user will see the
pop up gray box in order to log in rather than custom web page. The
username and password are stored at active directory level, thus this is
the windows integrated security.
|
by: Marcel Gelijk |
last post by:
Hi,
I am trying to create a User Control that is located in a seperate class
library. The User Control contains a textbox and a button.
The page generates an exception when it tries to access the code variable
that are supposed to be linked to the contained controls.
It runs fines when everything is contained in a single web form project.
What do I need to do to make it work from a class library?
|
by: Earl Teigrob |
last post by:
Background:
When I create a ASP.NET control (User or custom), it often requires security to be set for certain functionality with the control. For example, a news release user control that is comprised of a DataGrid may have separate permissions for adding, deleting and updating a news item.
Problem
Up until now, I have been implementing security directly inside the control. I will test directly against the security model to see if...
|
by: Guadala Harry |
last post by:
I have a user control that I'm inserting into multiple pages. Part of the
HTML content in the user control is a path to an image:
<img src="../images/arrow.gif" width="11" height="8" border="0">
The image appears just fine when viewed from pages that exist one directory
level below the site root, but not when viewed from pages that exist in the
site root (which is as expected).
What I want to do is be able to specify the path to the...
| |
by: louise raisbeck |
last post by:
Resending this as own topic as didnt get answer from original. Would be
grateful for a response from anyone that knows. Thanks.
Hi there, I found your post really helpful..but i wondered if, once I have
exposed a public property containing the value of a textbox in a user
control..how do I grab this from the calling page? I cant think of the
syntax, since my page doesnt know the contents of the class (and therefore,
the public...
|
by: Rich Milburn [MVP] |
last post by:
Ok I am not a programmer, I copied some code and very painfully got it
working in VB6. I can adjust the volume with waveOutSetVolume on winmm.dll.
But I could not seem to be able to figure out how to adjust the master
volume. I thought maybe if I upgraded this into VS2005 VB.Net then it might
be a little easier. But now I am getting PInvokeStackImbalance messages on
this, and it doesn't even run. We're talking a very little program... A...
|
by: CG |
last post by:
Hi
I need to implement some low level security that locks a certain page
if the user does come from a particular link (which is hosted on
another domain). I've considered using HTTP_REFERER variable but
seems this is a little shaky as it is not alway set.
Does anyone have a solution that would allow me to restrict. I figure
I can't use a session as it is linked from another domain - same with
cookies.
|
by: omerbutt |
last post by:
hi every one I am A new Bee to php mysql and i was surfing through the net to learn about how to secure the mysql when you are working in a web environment while working with php html and javascript i came through this article
http://articles.techrepublic.com.com/5100-6350_11-5287638.html
and before i proceede i must tell you that iam using win xp professional sp2
where were given two main and very first step before you start making your...
|
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: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
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: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
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: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |