hello,
I'm developing an app that needs to cache some images from the web the images are likely to be 100x100
I just need to know which is better:
Store the images as files in the iPhone file system
Store them as blob in a sqlite Db along with other data already saved on the database.
Appreciate your help.
...
I have a situation where there is a corrupt WAV file from which I'm trying to recover data.
My colleagues have sliced up the large WAV file into smaller WAV files with proper headers. This has produced some interesting results.
Sliced into 1MB segments we get these results:
The first wave file segment is all noise.
The second wave f...
We do a lot of document scanning, and I find myself now with a bunch of simple scripts that watch incoming folders for files, and then route the files to their final destination (i.e. they might end up in a Sharepoint library, or be encrypted and stored in an archive folder, etc).
I'm considering developing a rather simple application t...
I want to use it during uninstall procedure to warn the user ahead.
The procedure should work for W2000+, hence Vista API's are not allowed.
This seems to catch some conflicts:
if( GetFileAttributes( lpPath ) == INVALID_FILE_ATTRIBUTES )
{
// File does not exist
}
else
{
BOOL bCanDelete = FALSE ;
HANDLE hFile = CreateFile( path,
...
I'm using this code to read a file into a buffer. The file is full of structs of evaluacion type (including some char and int variables).
Now I have the whole file in a buffer, how can I find the values of one variable in the buffer now?
For example buf.notamedia < 4. There are supposed to be many of them inside the file.
#include <unis...
If you have a Windows application that needs to write working files as part of its normal operation (not prompted by the user):
Where on the file system should they be written?
What's the correct way to get this directory in .NET for all Windows versions (XP/V/7/Server)?
(Writing to the same directory as the executable or a "temp" di...
I have found that on one simple program, I was able to add the contents of an implementation file to the corresponding interface file, then I removed the original implementation file from the project, and everything worked fine.
Is it generally the case that the an interface and (corresponding) implementation files can be combined?
T...
I have a web site which handles files management. User can upload file, add description, edit and delete. What are the best practices for that kind of scenario?
I store files in the file system.
How should I handle deleting of the file? In this case I have to entities to delete: file and entry in database. First scenario is that I de...
Using C# (.NET 2.0), what is the best way to retrieve a file listing in a network directory, with preference to either sort by last write time, or to exclude the return based on last write time?
I'm currently bringing back a listing using the GetFiles method of a DirectoryInfo instance. The directories I encounter can contain over 6,00...
I have a application to list all music files in user machine, a "Explorer" button is using to quickly open Windows Explorer and highlight the file in Windows Explorer. I tried ShellExecute, but it doesn't work, the API will launch associate application. Any Windows API can do that? Thanks in advance.
...
Please,
We have the following situation:
Component X that divides a request file into parts, sending each part to an independent processing component Y -through a network- that will reply with a result to component Z , component Z collects all the results of the file parts into a batch result file.
Note:- Request file: file contains ...
I'm using the following command in my web application to find all files in the current directory that contain the string foo (leaving out svn directories).
find . -not -ipath '.*svn*' -exec grep -H -E -o "foo" {} \; > grep_results.txt
How do I find out the files that doesn't contain the word foo?
...
I have a single threaded program (C++, Win32, NTFS) which first creates a quite long temporary file, closes it, opens for read, reads, closes again and tries to delete using DeleteFile().
Usually it goes smoothly, but sometimes DeleteFile() fails, and GetLastError() returns ERROR_ACCESS_DENIED. File is not read-only for sure. It happen...
When I add a WCF service reference in Visual Studio 2008, a directory named Service Reference\ServiceReferenceNamespace is created.
In this directory, there's files named Service.xsd, Service1.xsd, Service2.xsd, Service3.xsd and Service4.xsd. The files rae not duplicates - the different files defines different types and elements. When ...
I want to get all file names from a folder using Ruby.
...
Is there a way in Visual SourceSafe to move a file from one directory to another while retaining its history?
Edit
I actually found a round about way to do this. First I drag the file I want to move to the directory I want to move it to, this creates a "Link" to the file there and then I "permanently destroy" the file in its original ...
Hi. I have been working on an app for a while now, and it is supposed to copy files. I have the code:
- (IBAction)moveFile:(id)sender
{
NSFileManager *filemgr;
filemgr = [NSFileManager defaultManager];
NSString *fileToMove = [NSString stringWithFormat:@"%@", "TestText.txt"];
if ([filemgr copyItemAtPath: fileToMove toPath: @"./T...
Hi,
I have a problem in showing *.mpp (microsoft project files) in my app. I thought of showing in image format but i dont know how to convert it into image format. or is there any other way to view mpp files.
thanks in advance
...
What is the fastest way to create a hash function which will be used to check if two files are equal?
Security is not very important.
Edit: I am sending a file over a network connection, and will be sure that the file on both sides are equal
...
I need to find word count for all of the files within a folder.
Here is the code I've come up with so far:
$f="../mts/sites/default/files/test.doc";
// count words
$numWords = str_word_count($str)/11;
echo "This file have ". $numWords . " words";
This will count the words within a single file, how would I go about counting the words...