How to include text from another Scrivener project.

Mi
Mike-QC
Posts: 1
Joined: Wed Nov 22, 2017 9:39 pm
Platform: Mac

Wed Nov 22, 2017 10:05 pm Post

Hi,

I'm posting here what I did to be able to get portion of documents from a Scrivener source to another one. Having been told it was possible, and then, it was not, I guess I think this topic needs some clarification.

First, I do not know if there is another easier way to do this... but if you know, please tell us.

OK, I was told by KB in the blog comments a few weeks ago that what I was trying to achieve will be feasible with Scrivener 3.
This is my basic needs and context: "... Using Scrivener mostly to prepare my teaching and training notes, I constantly reuse part of the information from other files. At the moment I just do an ugly "Copy-Paste" but would prefer to reference the source and be able "at compile" to import as text the reference. Any better idea how I can do that?"
KB answer was "As for reusing information, scrivener has a new placeholder tag. You can use this to include the text from other documents inside Scrivener, or to include the text of text files stored outside Scrivener, embedding it right into the text during Compile. So you should be able to do what you want there in 3.0."

Let's say that you are getting a link from a Scrivener file called FileSource.scriv
Then, you want to import only text from the file to a new document called FileDestination.scriv
From the FileSource.scriv you will use the function "Copy Document Link" and will give you a result like this: x-scrivener-item:///Users/YourUser/Dropbox/Apps/Scrivener/FileSource.scriv?id=E87AC320-8C71-4FA3-9B54-B8FB66515D01

In the FileDestination.scriv you will need to do this to import the content from the FileSource.scriv:
1- You must use the placeholder tag <$include> but do not use the \ sign before the tag
2- Then from the link you copied earlier, remove the scrivener app reference ("x-scrivener-item://")
3- Use the scrivener file name as if it was a folder (Remove the extra char( "?id=")
4- Use the UUID as a folder and add the rtf file it contains
5- You should have the final result like this: <$include:/Users/YourUser/Dropbox/Apps/Scrivener/FileSource.scriv/Files/Data/300BD8FA-398E-46B8-BAF8-A4B4E4941470/content.rtf>

One last thing… It would be nice to have a function that does all of this instead of having to do it manually.
Maybe it already exists?

Hoping this will help someone else …

User avatar
AmberV
Posts: 20608
Joined: Sun Jun 18, 2006 4:30 am
Platform: Mac + Linux
Location: Santiago de Compostela, Galiza
Contact:

Wed Nov 22, 2017 10:45 pm Post

Yeah about that, you might want to be careful when linking directly to internal data storage components in a file format. They are RTF files, and linking to them should be perfectly safe in the sense that it’s a passive read when you compile—but it’s still an internal storage component. :)

All right, here’s something you can try:
  1. Put an inspector footnote into your source document, the one you’re linking to.
  2. Compile the other project to RTF.
Obviously not the desired effect. Try throwing a block quote style on a paragraph and compiling again. There are all kinds of things that can go wrong by ripping the raw source data unprocessed like that. Scrivener has a lot of features that aren’t, strictly speaking, RTF—and it has a lot of features that depend heavily upon local data inside of the project format.

So by all means, Use At Your Own Risk—the simpler the better; it works in theory—but hopefully you can see why we don’t have any menu commands or knowledge base articles for doing that. ;)

To come back to the original point: I think there was perhaps a misunderstanding over the initial question when that answer was given. The feature is strictly designed to:

  • Include from other items in the binder.
  • Or from RTF/TXT files on the disk—and by that we mean normal RTF files, not stuff buried inside of an applications package format. ;)
.:.
Ioa Petra'ka
“Whole sight, or all the rest is desolation.” —John Fowles