Questions tagged [documents]

298 questions
49
votes
13 answers

Creating Microsoft Word (.docx) documents in Ruby

Is there an easy way to create Word documents (.docx) in a Ruby application? Actually, in my case it's a Rails application served from a Linux server. A gem similar to Prawn but for DOCX instead of PDF would be great!
Javier
  • 2,451
  • 4
  • 36
  • 55
20
votes
7 answers

Delete documents of type in Elasticsearch

I want to delete all the documents indexed within a type in Elasticsearch, using the HTTP/REST api, but I don't want to delete the mapping for this type How can I build the query in the URL to do this?
user2816801
  • 205
  • 1
  • 2
  • 7
18
votes
13 answers

Recommended location for document storage - in database or elsewhere?

Background: We have an in house document storage system that was implemented long ago. For whatever reason, using the database as the storage mechanism for the documents was chosen. My question is this: What is the best practice for storing…
Mike Ohlsen
  • 1,892
  • 13
  • 21
18
votes
2 answers

Getting an iOS application's "~/Library" path reliably

This Apple tech note: http://developer.apple.com/library/ios/#qa/qa2010/qa1699.html suggests storing "internal" user documents in a subdirectory off of ~/Library. But I can't find one of the pre-created search domains that would get me this. What's…
Ben Zotto
  • 67,174
  • 23
  • 136
  • 201
15
votes
1 answer

Replacing embedded document in array in MongoDB

Is there an easy way to replace an entire embedded document in an array? Say replacing: { "_id" : "2", "name" : "name2", "xyz..." : "xyz2..." } with: { "_id" : "2", "name" : "name6", "xyz..." : "xyz5..." …
Fredrik L
  • 1,670
  • 4
  • 21
  • 26
15
votes
2 answers

How to save files in External Storage Public Directory DOCUMENTS on Android 4.1.2

i want to save a file on my Android 4.1.2 smartphone in the documents directory. This code snippet: File file = new File(Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_DOCUMENTS),"test.txt"); throws this…
pebbles
  • 324
  • 1
  • 3
  • 16
13
votes
4 answers

how to share odt/doc documents over git

the idea is that i want to share documents over git i thought about using Text Document (looks like docx,odt in functionality ) that can be edited with any text editor (not binary). where to find something like this ? any better solution?
MhdSyrwan
  • 1,441
  • 3
  • 18
  • 25
13
votes
4 answers

Proper method to find user's My Documents folder on Windows with Java?

For whatever reason, I sometimes need to find the current user's My Documents folder on Windows in a Java program to read some files. But as far as I can tell, there is no way to do it that isn't severely flawed. The first wrong way:…
Aleksei Vasiliev
  • 221
  • 1
  • 3
  • 6
13
votes
1 answer

PhoneGap iOS, how to get app "Documents" folder full path?

I need copy photo into this path. but how to get it? “iPhone Simulator/5.1/Applications/996C42CE-B8BF-4F1A-B16C-DBF194BD5A71/Documents/" http://docs.phonegap.com/en/1.8.0/cordova_file_file.md.html#FileTransfer I want to download a image into my…
meadlai
  • 725
  • 1
  • 7
  • 20
11
votes
1 answer

iTunes Documents Directory in my app

how can I setup my app to accept documents via iTunes, like the Air Sharing or VLC app? I mean, I want to allow users to get content from the app using iTunes. Anyone know how? Thanks
Jerem
  • 113
  • 1
  • 4
11
votes
1 answer

Objective C documents directory keeps changing on device

I've been developing for iOS since the beginning and I've run into some trouble. I started making an app that needs to create files and save them to the documents folder and application support, however the good ol' standard way of using the…
Hayden
  • 113
  • 1
  • 5
10
votes
1 answer

MongoDB - How to query Embedded Documents from a collection

Gurus - I'm stuck in a situation that I can't figure out how I can query from the following collection "users", it has 2 embedded documents "signup" and "activity": { "appid": 2, "userid": 404915, "signup": { "dt": "2010-12-28", …
9
votes
2 answers

R text mining documents from CSV file (one row per doc)

I am trying to work with the tm package in R, and have a CSV file of customer feedback with each line being a different instance of feedback. I want to import all the content of this feedback into a corpus but I want each line to be a different…
user2407054
  • 103
  • 1
  • 1
  • 3
8
votes
2 answers

Looping through documents in MongoDB

I want to loop through documents in MongoDB. Basically here is the situation. I have some JTextfields which i want to populate from MongoDB. So each time the user click on the Next button, a new record must be fetched and display it in the…
user1259962
8
votes
1 answer

Mongo: How do I insert another subdocument to an existing document

I've started to learn Mongo. Given the following collection, say called posts, how would I go about inserting a new comment to an already existing document? The examples I've seen on the mongo website are for "simple" collections. Thanks for the…
Harvester316
  • 371
  • 1
  • 6
  • 17
1
2 3
19 20