Suppose there is one folder "D:Main" which can contain any word file. On adding any file/files to the folder I need to parse the file and based on some keywords I need to transfer the file to some other sub folders as well as some entry to the database also.
I know something about FileSystemWatcher. If there would have been a button like "Check and Move" then I know that on the button click event I can do something but how to do it automatically. I mean if I add file to the folder manually also it should do the same(files may be uploaded via web as well as manually).I am currently working in web application with asp.net and c# and I have a little knowledge about windows application.
I want to Create Watcher Component how to create ?
ie: I created one Queue ( Private queue ) using MSMQ so the watcher Component will listen the Queue is there any msg if any message available on that Queue.
I have to do some process ie: pass that msg to Business Layer for further manipulation and keep on watch the queue for any other message.
Although it may not seem like that but there is a little questions about this subject.I am not asking if I should use DB or filesystem, the file system it is, but I am asking what is the best way of organizing pictures in file system that will be used with asp.net application? I am talking about tens or even hundreds of thousands of picture.
To elaborate a question a bit.
Where should repository be located, create another VD in IIS or in application VD, or somewhere outside IIS? How to organize file patsh, put them all in one folder or create subfolders. If so how to name all those folders?How to handle multiple sizes of the same image? where to locate them?How to sync folders and images with database?What else crosses your mind, and you think it's important..
I've done something myself allready, but I am asking if someone had some experience with this. Maybe it could be done better yours way.
I put things like this
I stored pictures in IIS folder, because storing them outside of iis make them unable to use in web, because of paths. You cannot use file path in web, it must be virtual file path.
http://images/1.jpg istead of C:images1.jpg in the root I had subfolder for each picture size
root- +400x300 +600x400 +1024x768
Named images by id from database. If the ImageID from database is 45678909, the name of picture is 45678909.jpg an it's location is
I sliced the picture name two by two, and create subfolders. the point was not to have more than 100 files in folder. Was this good idea or stupid one? How would you organize this? For person, this organization with tons of folder is not easy to use.
Name of the image with its relative path I saved in database table with description and time of insert etc. path: 45678945678909.jpg
HOw to view the loaded videos which are in filesytem from MVC pattern architecute. Suggest links or code to view the videos in Windows Media player or other players which supports defaultly by MVC.
I need to retrieve an image from a database file and save it to the file system.
Lets say I have this so far
Code: Dim query As String = "Select Foto From tblImagenes Where ItemId = ?" Dim conn As New OleDbConnection(ConfigurationManager.ConnectionStrings("Conexion1").ConnectionString) Dim com As New OleDbCommand(query, conn)
[Code].......
I-m getting an error about the wrong parameter to the bitmap.
I have an report that is in pdf file. Everytime the user click the button, it will go to SQL database and pull up the data, and then create the pdf file based on that data.
I wanted to save the pdf file the first time user click on the link. So that when he / she come back and open the report, instead of going to the data base and pull the data. It will just pull the pdf file from the file system. Here are the code that I have :
Dim parameterUid As String = CStr(Request.QueryString("Uid"))
Is it possible to read an .aspx-file from the filesystem, probably translate it into the Page-object and then render it into HTML? And then writing it back to the filesystem as a .html file.
The .aspx file on the filesystem is without the codebehind file. If possible provide me some example code.
Now I want to create several filesystemwatchers in my Windows Service and have them monitor different folders but do basically the same thing when files are created. That is, they will be calling the same routines. So my code so far is this:
Code: // 10/14 - Create N fsw's as specified in the config file. int nbrFsw = Convert.ToInt32(ConfigSettings.ReadSetting("NumberOfWatchers")); List<FileSystemWatcher> listOfFsw = new List<FileSystemWatcher>(); for (int i = 0; i < nbrFsw; ++i) { FileSystemWatcher fsw = new FileSystemWatcher();
[Code] ....
Is there a potential problem that all fsw's that get created are calling the same "on created" event handler? Or will this work nicely?
My requirement is this. I need to watch Output folders and when pdf files are created here I upload the files to a server. These Output folders are in web app deployments. I need to do this function for more than one deployment on the same machine, thus my need for more than one fsw.
This will ultimately be a web service but I am trying this out in a windows program, hence the presence of lblMessages which is on a windows form...
I am writing web application using ASP.NET MVC + NHibernate + Postres stack. I wonder if images uploaded should be stored in database as binary blobs or on filesystem (and reference only in db).
One advantage of db storage I can think of is easy backup/recovery of all data without reverting to filesystem copy tools. On the other hand I suspect that filesystem access may be faster (but is it especially when dealing with many concurrent requests?)
I have a File Uploader in my ASP.NET application Using C#, we can upload any type like images, documents, pdf etc.
I m storing it in the Filesystem and having only the Name of the File in DB.My doubt is can we store the entire file, images in DB. State me Which is good practice and why we need to use it.
I have a piece of code which loads either french or english text and 2 link buttons that allow to switch between.
[code]....
What would be an efficient way of displaying the link buttons and text if both English and French exist and the session exists in either EN or FR.
I've thought of using panels to hide the buttons or text, but the main problem is having the page refresh to set the Session variable. Response.redirect(URL) to refresh the page i suppose and i can't find a better way to display the text other than to Response.write it since then i'd need a ton of labels.
I've written a web form application which contains a multiview.. i have a drop down list which selects the view.. On selecting the option in the dropdown list , the content in the view changes... Well can any1 tell me how to implement multiview in asp.net mvc
need to write Cache Methods in my asp.net mvc project.. I created one Class called CacheHelper.cs file.. Mainly In my appliction I am using three types GetData() ( getting data from cache)Add() ( Add data to the Cache) Refresh() ( Refresh data) or Flush()
We have one application, which have to store multiple emails in the msmq and pass to different application...so please tell me how to implementt msmq in .net?
What are the Steps I need to add SSL to my Website hosted at IIS 7 in Windows Server 2008?The application was Done in ASP.NET 3.5 and the application follows SOA (Service Oriented Architecture) with WCF services accessing data from SQL Server through a Business and Data Access Layer.
I am using an SQL data source and binding a control to it. I would like to know if/how i can implement a SELECT * FROM x WHERE ID IN(@ID) @ID = {1,2,3};
we have following scenario. we have 2 web sites one is in asp.net and 2nd in Joomla 1.5.
we want SSO from Joomla to ASP.Net site. Integration Flow as below:
1) Joomla site will have Menu Item named with "Join ASP.Net Site" 2) When Logged in User clicks on the Link we need to pass URL along with Logged in UserName in Joomla
Eg. [URL] (here, MNP is username of the Joomla user who has clicked the link.) if user xyz is logged in then we need link as
I'm trying to wrap my mind around the way ASP.NET MVC implements routing.
From what is my current understanding, it seems my route string much have a "{controller}" and "{action}", otherwise it doesn't work?
How would I define the route that using a SearchController and Search action taking both SearchKeywords and SearchCaseSensitive arguments had the following URL?
domain/SearchKeywords/CaseSensitive
Even simpler, how do I map domain to controller SearchController and to Search?