I want to define my xml file path in my .js file . how to define relatiove path in js file . i have already done in my javascript which is located at aspx page . like
var strPath = "<%=Url.Content("~") %>Configuration/ConfigError.xml";
but i want to define this type of path in my .js file .
I am developing a couple of small ASP.NET application and would like to know what pattern. approach do you use in your projects.
My projects involve databases, using Data access and Business logic layers.
The data-access approach that I was using so far is the following(I read in some book and liked it):
For DAL layer:
Creating an abstract class that will define all database manipulation methods to implement. The abstract class will contain a static "Instance" property, that will load (if instance == null) an instance (Activator.CreateInstance) of the needed type (a class that implements it).
Creating a classes that implement this abstract class, the implementation will be according to the databases (SQL, mySQL and etc) in use.
With this I can create different implementation according to database in use.
For BLL layer:
A class that encapsulates all all retrieved fields , and static methods that will call the DAL classes.
as Service but here as you see in row with id=2 there isn't any data in service2 and service3 columns and just in service1 is data(ser4) so it show in lblservice data like below ser4, , , ...
but I want if in one of column doesn't be data it doesn't show (,) that come after data I mean I want if in 1 columns be data in show:
I have a database where i have the physical path where image of a person is stored . now i want a code by which i can display the image of that person in a aspx window.
as i am new to asp.net & C# can somebody provide me the full code of aspx page and the C# code behind it?
Is it possible for an ASP.NET web application installed on a web server to connect to an Access database stored on a local PC (which is NOT the web server)? I would like the web application to allow the user to specify the path/complete file specification to the database. Or, based on login information specified by the user, the web application might determine the path to the database via an administrative database stored on the web server. The user/customer would be responsible for the storage of the Access database. If the answer to my first question is "YES", how do I programmatically specify/format the path to the Access database on the local PC so the web application can locate the database?
The path has to be something more than "C:foldernamesubfoldernamedatabase.mdb". When I use a path like this, the web application produces an error indicating that the database does not exist or cannot be found. So, I'm fairly sure that the web application is not starting with Drive C: on the local PC to find the database. For all I know, the web application may be interpreting Drive C: as Drive C: on the web server. I'm wondering if I need to specify a computer name before "C:" in the database path.
i have stored the images in mysql using the varchar datatype and i am storing the path of that and i want to retrive that images in the gridview of asp.net
how can we save the uploaded file path in to database and then retrieve it in gridview as a link so when user click on that it will open that file in browser.
But when I upload image with Fileupload and click on btnupload button below error happen..
Server Error in '/' Application.
Access to the path 'C:Inetpubvhostsbehtop.comhttpdocsimageHouseservices8.jpg' is denied. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.UnauthorizedAccessException: Access to the path
How to display images in crystal report from database am inserting address (image folder) of images into the database, not inserting images into the database...
I'm downloading a binary file from a SQL database to a client machine and want to instead download it to a folder on a server. THe code I'm using is below. How would I change the .AddHeader(I assume) to send the file to a folder on my server rather than the computer running the web page.Protected Sub download(ByVal dt As DataTable)
I want to save three images path in table also upload images in folder,how it is possible?[Using ajax file upload control]table columns are imagepath1,imagepath2,imagepath3. URL....
Here is what I am basically trying to accomplish I want to upload images to the server separated into categories and save the file path into the database. I have found plenty of documentation on saving to a file and the file path to a database. But, I haven't found anything that will allow me to seperate the images into categoies.
I have made three tables in the database
[code]....
What I am trying to do is create a gallery for our clients to browse and download different vesions of posters and ad cards.
I'm trying to display images in a GridView (yes, still this...). [edit] Before I can come to that I have to upload some images to the database.
I've followed this tutorial for the "upload image to database" code (this worked fine for uploading images, but I don't know if the images were converted to byte):
[URL]
and I've followed this tutorial for the "display images in gridview" code (and "retrieve file" from the tutorial below).
[URL]
It doesn't quite work, the GridView shows but without images
Now I'm trying to change the "save file" code according to this tutorial:
[URL]
but I don't understand everything in it. When I try to upload an image I get an error on this line:
if (Request.QueryString["vid"] != null) { frmViedo.DataSource = video.GetVideoById(Convert.ToInt32(Request.QueryString["vid"])); frmViedo.DataBind(); } public OleDbDataReader GetVideoById(int id) { string strSelect = "select * from Video where VID = @VID"; return ExecuteReader(CommandType.Text, strSelect, new OleDbParameter[]{ new OleDbParameter("@VID" , id), }); }
But it don't work and i get this error :
Adobe Flash is disabled for this page, click player area to enable. Why?
Over here I have created a folder with name Data inside my solution, so the Server.Mappath("Data") as well the statemet for converting assigning the src property of the IFrame I1 is working properly. But I want to use the files from a folder which resides in a network folder like
I am developing audio related project for that i have stored movie names with mp3 file paths in database I am displaying movie names in grid view after clicking on movie name related mp3 file paths will be display in details view i am unable to play that files in details view how to do this ? Here i am storing original mp3 files in one folder in solution explorer and paths in database