Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Image pathing in user controls
Message
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Divers
Thread ID:
00798637
Message ID:
00798719
Vues:
14
I don't think there is. I've run into the same mess with stylesheets although there at least you can add a second style ref and the second one is ignored.

One thing you can do if you can't get it to work any other way is use as Hector suggested images/someimage and then copy the image folder underneath the user controls directory.

Frankly you're probably better off sticking the user controls into the same directory as main ASPX pages - in a way you treat them like full pages anyway...

I agree though - organizing ASP.Net projects becomes a major PITA in a hurry if you have a lot of pages and controls.



>I'll bet this is an easy question....
>
>My application directory structure is as follows:
>
>application_root
> ->images
> ->usercontrols
> ASPX files go in root
>
>I need to reference images in my user controls (so the pathing looks like "../images/someimage.gif") in my user control source.
>
>When I include the user control on a page and try to run it, the page (obviously) cannot find the image (since ../images takes me outside of my application root).
>
>My question is this, is there some way in the src="" attribute on my HTML controls to specify an application root relative path so that I can see the graphics in UserControl design mode AND when I run my application?
>
>Please say there is a way to do this....
>
>Mary Hintermeier
>RSA
+++ Rick ---

West Wind Technologies
Maui, Hawaii

west-wind.com/
West Wind Message Board
Rick's Web Log
Markdown Monster
---
Making waves on the Web

Where do you want to surf today?
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform