473,396 Members | 1,942 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Have Url - need Physical Path

Hello

In a webpage i have 3 img controls. I want to set the ImageUrl ( only if the
picturefile exist ) else ImageUrl = some default picture.

To check if the file exists i use File.Exist( Path ) but I only know the Url
and File.Exists needs the fullpath.

Can anyone help me.

/Johnny Jensen
Nov 19 '05 #1
1 1899
Hey Again

Found it Server.MapPath( Url ),

/Johnny Jensen

"Johnny Emde" <em**@emde.dk> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
Hello

In a webpage i have 3 img controls. I want to set the ImageUrl ( only if
the picturefile exist ) else ImageUrl = some default picture.

To check if the file exists i use File.Exist( Path ) but I only know the
Url and File.Exists needs the fullpath.

Can anyone help me.

/Johnny Jensen

Nov 19 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Scott Tilton | last post by:
We have a field that gets filled into a database that our ASP website pulls from. What we would like to be able to do is to take that path and convert it to a virtual path so the website can...
1
by: Michiel Schaeverbeke | last post by:
Hi, I'm trying to reach an xml file from within a web application. The file is physically on a different server. When I try to reach it using \\servername\path\ style, I get the error...
8
by: Jaime Stuardo | last post by:
Hi all... How can I get the physical path of a web site from an EXE application? The Web Site is on the same server as the application. Thanks in advance Jaime
4
by: Vaclav Jedlicka | last post by:
Hello, I created a web app using Visual Web Developer 2005 Express Edition. The project is called "mytest". When I view a page in the browser, its URL looks like ...
4
by: =?Utf-8?B?SmVmZiBCZWVt?= | last post by:
Best way I can think to describe this is through an example. I have a virtual directory, let's call it "MyVirtualDirectory" that maps to \\MyServer\Shared. I have a path that is...
5
by: marss | last post by:
Server.MapPath("~/page.aspx") returns the physical file path based on the specified virtual path. Is there any reverse method to get the virtual path based on the physical path (both pathes belong...
2
by: Jex | last post by:
Hi, I hv create an application using C#, Asp.Net (VS 2005) and I add an Installer Class to that application's setup (when deploy that app), so that I can change the version to 2.0, Now, I need...
0
by: Ahmedhussain | last post by:
Hi everyone, I am totally new to IIS. I somehow configured IIS and now whenever I try to add a website, on testing it gives me the error of authorization, i.e. "Cannot verify access to path :...
0
by: eunalp | last post by:
I'm working on a web service that will update the file content of a web application which is under the same server. The web service and the web application are independent from each other however the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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...
0
Oralloy
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,...
0
tracyyun
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...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.