Hello.
I'm writing an HTTP Cache library for Java, and I'm trying to use that library in the same application which is started twice. I want to be able to share the cache between those instances.
What is the best solution for this? I also want to be able to write to that same storage, and it should be available for both instances.
Now...
how to delete a file which is in use/open by some process in runtime.
i am using vb.net for my project and a image is shown in picturebox.
and that should be deleted, with out closing that file.
thanks in advance,
vijay
...
I am getting an 'access is denied' error when I attempt to delete a folder that is not empty. I used the following command in my attempt: os.remove("/folder_name"). What is the most effective way of removing/deleting a folder/directory that is not empty? Thanks in advance.
...
How do you get a list of files within a directory so each can be processed?
...
I have been able to zip the contents of my folder. But I would like the zipped file to remain in the folder that was just compressed. For example, I've zipped a folder called test in my C: drive. But I would like my "test.zip" file to be contained in C:\test. How can I do this? Thanks in advance.
clarification of question with code exam...
I have a web application (.war) that contains some static files (e.g. MS word documents). When I try to download these files, JBoss automatically sets some HTTP-headers in the response. Is there a way to configure JBoss (version 3.2.7) to set these headers to specific values (or omit them)?
I'm especially interested in the
Cache-Contr...
I would like to generate a list of files within a directory. Some of the filenames contain Chinese characters.
eg: [试验].Test.txt
I am using the following code:
require 'find'
dirs = ["TestDir"]
for dir in dirs
Find.find(dir) do |path|
if FileTest.directory?(path)
else
p path
end
end
end
Running the script...
Thanks to everyone here, got the Xampp server running!!! and can run my html in subdirectories now, as well. (can't have spaces in the subdirectory names)
NEXT UP - SSI Includes or PHP Includes
Xampp says SSI is deactivated. Tried uncommenting the lines for includes, but it doesn't change the deactivation.
How do I activate SSI?
Then...
Windows Programming: How to put a file that is frequently accessed in the OS cache?
...
Title says it all.
How do you do it, or is it even possible?
I suppose you could fiddle with getCanonicalWhatever and the original path, but that's messy and I don't like it. Please include a definitive reason if you suggest it.
...
Edit on 11/26 - Please note - I am not looking for the "right" way to open/read a file, or the way I should open/read a file every single time. I was just interested to find out what way most people use, and maybe learn a few new methods at the same time :)
A very common block of code in my perl programs is opening a file and reading o...
WinAPI OpenFile function returns HFILE, and GetFileTime for instance needs HANDLE. When I feed it with (HANDLE)some_hFile it seems to work fine. Is there any difference in this types, or one of these is simply rudimental?
...
My program receives large CSV files and transforms them to XML files. In order to have better performance I would like to split this files in smaller segments of (for example) 500 lines. What are the available Java libraries for splitting text files?
...
Hi all,
I'm trying to store in a variable the name of the current file that I've opened from a folder...
How can I do that?
I've tried cwd = os.getcwd() but this only gives me the path of the folder, and I need to store the name of the opened file...
Can you please help me?
Thanks.
...
I have a folder with these files:
alongfilename1.txt <--- created first
alongfilename3.txt <--- created second
When I run DIR /x in command prompt, I see these short names assigned:
ALONGF~1.TXT alongfilename1.txt
ALONGF~2.TXT alongfilename3.txt
Now, if I add another file:
alongfilename1.txt
alongfilename2.txt <--- created third
...
Using the .net framework you have the option to create temporary files with
Path.GetTempFileName();
The MSDN doesn't tell us what happens to temporary files. I remember reading somewhere that they are deleted by the OS when it gets a restart. Is this true?
If the files aren't deleted by the OS, why are they called temporary? They are...
I want a way to list files in a directory and putting a check box beside each one of them so I can select some of them and perform operations with each selected file, what's the best way to do this?
...
We are making an automated patching application and would like to post files on production server through asp.net page (or maybe a web service), since we can only access production server via http. The page should accept files and store them to appropriate location. The path to files will be declared in external XML file.
So, is it possi...
The last line of my file is:
29-dez,40,
How can I modify that line so that it reads:
29-Dez,40,90,100,50
Note: I don't want to write a new line. I want to take the same line and put new values after 29-Dez,40,
I'm new at python. I'm having a lot of trouble manipulating files and for me every example I look at seems difficult...
Hi, I wrote a program out, which was all in one file, and the methods were forward declared in a header. The program initially worked perfectly when it was in one file. But when I separated the program, I kept getting random occurrences for the destructor of one of the classes which was declared in the header file.
I have a static v...