Adding citations in word without parentheses

2»
  • edited October 14, 2018
    Any format. It doesn’t use BibLaTeX for citations, it uses CSL to convert them to flat text.
  • just to give it another push, i believe many would love a possibity to site without parentheses. And to manage that in an easy way as tomka suggested earlier. I do agree also with Mojo Dodo, that this might be a feature for people using other progams e.g. citavi.
  • Just to add to this discussion, I have asked for a feature like this back in the days (2009 I think) and I am happy to see there are more people with the same need.

    As many have stated before in this thread, it is very common to cite either:

    1. (Author et al. Year)

    2. Author et al. (Year)

    1. is the most common, but 2. is also used quite a lot when writing papers. For example, when starting with a reference or stating the author(s) first:

    Author (year) discovered ....
    ....such discovery was successfully used by Author et al. (Year) in Sri Lanka...

    I have been waiting for this feature for years, almost 10 now!!!

    Another use of 2. is when building a Table with a literature review, where you have many results from many papers and you cite the references in the last column. In this case all the references need the 2. Author et al. (Year) format. Doing this with the Suppress author or editing in Word is indeed possible but very tedious if you have many references.

    As others already explained it, a simple button/option (with maybe a short cut) to go for option 2. would be awesome!!!

    Default would be option 1. as it is now but with one more click, one could choose option 2. for those cases when you need it.

    Really looking forward for this!

    By the way, a big THANK YOU to all Zotero developers. I have been using it non-stop since 2007. I cannot imagine working without it.
  • It’s being very actively discussed by the Zotero and citeproc-js developers
  • To return to lauriehall's original question, how to render some citations (e.g. in a table) without parentheses: it is possible to manually delete the parentheses in just those citations, but it has the drawback that they then won't update automatically. Another possibility is to edit the style sheet to remove the parentheses (in APA, edit the citation prefix/suffix fields), then manually put parentheses *around* (not in) those citations that you do want to be parenthesized. -- Of course, this will be a mess if you later want to switch to a citation style that doesn't use parentheses...
  • There's always biblatex :)
  • We're certainly working on it. It's worth pointing out that it's streets harder to do this in a dynamic word processing environment than it is in a run-once text processor like BibTeX or pandoc. But it's possible to make it happen, and it will. Just takes time.
  • I know, I was just joshing :)
  • Didn't mean that as a response to yours! Just a general thought after scanning over the thread.
  • edited April 19, 2019
    I think there is an easy solution for this problem for at least Windows users. If you are not afraid of creating macros, you can actually use the code that I have written below to create a macro, then assign a hotkey to the macro. What this does is very simple. Just select the parenthetical citation, and then run your macro using the newly set hotkey, and it will turn the citation into Author (xxxx) format. Of course, this works for the APA format, and I have not tested it with other citation formats. Here is the code:

    Dim pos As Long
    pos = InStr(Selection.Fields(1).Code.Text, "formattedCitation")
    Dim mytext As String
    mytext = Selection.Fields(1).Code.Text
    mytext = Mid(mytext, 1, InStrRev(mytext, "}"))
    Dim mytext2 As String
    mytext2 = Selection.Text
    mytext2 = Mid(mytext2, 1, InStrRev(mytext2, ")"))
    mytext2 = Replace(mytext2, "(", "")
    Dim pos2 As Integer
    pos2 = InStrRev(mytext2, ",")
    mytext3 = Mid(mytext2, 1, pos2 - 1) & " (" & Mid(mytext2, pos2 + 2, Len(mytext2))
    mytext3 = Replace(mytext3, "&", "and")
    mytext = Mid(mytext, 1, pos - 2) & Chr(34) & "custom" & Chr(34) & ":" & Chr(34) & mytext3 & Chr(34) & "," & Mid(mytext, pos - 1)
    Selection.Fields(1).Code.Text = mytext
    Application.Run "Zotero.ZoteroRefresh"
  • @reza_n: Brilliant, thanks!
  • edited August 19, 2019
    @reza_n: that's not going to update properly when you refresh Zotero or edit the field. You can convert the text like that, but it is much better to have some way to associate it with the cite rather than just clicking it every time you want to convert it. In other words, you might as well just change the text manually, unless I'm missing something in your code that helps with this. (Note that unless you can get it to maintain the new form after refresh, it's actually better to get to Zotero error so you know something is wrong.)

    I've automated that by flagging a cite with "0" as the page number here:
    https://forums.zotero.org/discussion/73159/announcing-zoterzero-for-author-only-cites

    Of course my code there is for a different style, so you would want to replace the text manipulation with your code including the replacement of "&" with "and" (a quirk of APA).
  • @djross3 thank you for your feedback. In this macro, I am not changing just the text. I make the changes to the citation field which leaves the formatted citation and all the associated information intact. I agree that users must select the citation and use their assigned hotkey to convert the citation, but they use both parenthetical and textual citation formats interchangeably. Even if Zotero added a button to do this, the process would be similar, i.e. choose a citation and then select if you want it to be parenthetical or not. So, why not just do it after inserting the citation?

    I agree that this does not interact with Zotero, as you have also mentioned in your own code. Still, if this did happen, Zotero would convert all the citations into textual, but the users need to have their choice, so I am not sure if communicating with Zotero is really necessary.

    By the way, I liked your code! Especially that you are using JSON to handle the MS Word field code modification.
  • Maybe I am still not understanding, but the problem is that if you do this after Zotero generates the citation, then refreshing Zotero will erase all of those changes. There's no way for it to "remember" which fields you switched to the other format. That's the reason for using the "0" to flag it. Or does your code do something more than that?
  • I really hope there is a method for adding non parenthetical in text citations. Just starting my dissertation and the amount of extra editing the citations seems a little daunting.
  • @bphillips79 what style are you using?
  • Is there any update on this issue?
    Or a clear instruction HOW to remove the parenthesis from a citation style?
    These unwanted parentheses drive me crazy.
  • Like with the person before you, we'd need to know which style you are using and can then help with the adaption.
  • ah great if you can help! I am using the APA 6th edition
  • Remove the prefix and suffix from line 1406.


    General instructions here. Make sure to change ID etc. as mentioned, otherwise it'll get overwritten: https://www.zotero.org/support/dev/citation_styles/style_editing_step-by-step
  • edited October 6, 2019
    On my line 1406 it says: " text variable="page"/"
    I think you mean another line? What does it say?
  • edited October 7, 2019
    I used APA 6th straight from the repository.
    See this:
    https://www.imageupload.net/upload-image/2019/10/07/imagen.png


    Anyway, look for the section called "citation". That's the section that renders the in-text citation part. Now the 3rd line of that section will start with layout and will have prefix="(" and the corresponding suffix=")". You can delete those.
  • Hi, I've just been getting to grips with zotero and playing around with citations/bibliography capabilities ahead of thesis beginnings. Noticed this issue straight away, in that I manually edited a citation to site without parentheses around authors. And then, I had the choice to keep modifications and prevent future updates. Ideally I want keep modifications and allow future updates! Without getting into macros (that from my understanding of what's already in this thread would stop future updates?) has there been any updates on a user-friendly solution please? Thanks
  • @LWTaylor: There's no way Zotero could keep your modifications and also update the citation — that's self-contradictory. But if you're just trying to do "Smith (2020)" or similar, you don't need to modify the citation at all. You just need to customize the citation using "Suppress Author". This thread is mostly about more complex use cases where there are no parentheses at all.

    Progress has been made towards a more elegant solution that won't require typing the author manually.
  • Thanks for the reply @dstillman .... the suppress author is great to know about - in the sense that it allows me to have just the date in parentheses, and zotero still creates a correct reference section or bibliography.

    It would still be great to have a clickable option for zotero to insert the whole of either:
    Smith (2020) ...or... (Smith, 2020)

    Currently the only two options I seem able to achieve is
    (Smith, 2020) ...or... (2020)
    So if, for example, I then updated an author's name in zotero, and refreshed the links in my word document, the author's name would only be updated in the first option. Where I had manually typed the author's name, i.e. the second option, it obviously wouldn't update automatically.

    Does anyone know if choosing whether author is before or within parentheses is possible yet please?
  • Not possible. Requested many times. See the link I posted above.
  • Nothing new since August, no.
  • Hello,

    Any update on this?

    Like the others who have posted above, I also need to use both (Author, Year) and Author (Year) in my thesis (I'm using APA style). Since this is possible in Citavi, I'm currently using the Citavi Word plug-in. But Zotero is my main reference manager and I'd prefer to be able to use that for the writing part too...

    Thank you!
Sign In or Register to comment.