LaTeX forum ⇒ GeneralMultibib and Natbib issue workaround with renewcommand?

LaTeX specific issues not fitting into one of the other forums of this category.
Posts: 1
Joined: Mon Sep 21, 2015 2:05 pm

Multibib and Natbib issue workaround with renewcommand?

Postby FredFM » Mon Sep 21, 2015 2:11 pm

down vote
I divided my bibliography into 2 parts: Literature and online sources in this manner:

  1. \usepackage[table,xcdraw]{xcolor}
  2. \usepackage[square, numbers, comma, sort&compress]{natbib}
  3. % Use the natbib reference package - read up on this to edit the reference style; if you want text (e.g. Smith et al., 2012) for the in-text references (instead of numbers), remove 'numbers'
  4. \usepackage [labeled,resetlabels]{multibib}
  5. \newcites{O}{Online Sources}


  1. \bibliographystyle{plainnat}
  2. % Use the "unsrtnat" BibTeX style for formatting the Bibliography
  4. \bibliography{Bibliography,Master}
  5. %For online sources
  6. \bibliographystyleO{plainnat}
  7. \bibliographyO{WWW}

This code has a good result for the bibliography part so the items are Showen as O1 author,title year O2 author,title year

but in the text i have still [1] instead of [O1]

I read a lot of posts considering this issue but nothing solved my issue.

So I tried to make a work around \citeO [O][]{refexample} would result in [O 1] whereas O is not a link!

So i tried to renewcommand but i don't know the syntax. i want to do something like this:

  1. \renewcommand*{\citeO}[1]{"O"+\citeO{#1}}

Is this possible somehow in Latex? Or can you please help me out with that?

I use Overleaf there it results as [1] in the text, compiled with Texstudio v. 10 I get [?]. I use \cite and \citeO for referencing in the text.
How can I fix this?


User avatar
Site Moderator
Posts: 4183
Joined: Thu Nov 01, 2012 4:08 pm

Postby Johannes_B » Mon Sep 28, 2015 6:32 pm

This is a crosspost to TeX.SE.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.

User avatar
Stefan Kottwitz
Site Admin
Posts: 9601
Joined: Mon Mar 10, 2008 9:44 pm

Postby Stefan Kottwitz » Mon Sep 28, 2015 6:48 pm

Hi FredFM,

welcome to the forum!

It's a bit hard to follow the topic without having compilable code at hand, to verify the problem. If you would be able to provide a Infominimal working example, with .bib file(s), it would be much easier to help.

Stefan admin

Return to “General”

Who is online

Users browsing this forum: No registered users and 9 guests