Conditional formatting

A place for users to ask each other questions, make suggestions, and discuss Bookends.
Post Reply
mzumaeta
Posts: 13
Joined: Thu Feb 01, 2018 2:48 pm

Conditional formatting

Post by mzumaeta »

Hello,

I was wondering if there is someone out there who could help me with a conditional format. When I cite journal articles sometimes I am required to cite the basic information of the article (No DOI, no URL). However, when there is a DOI number I should included this number, and when there is a URL I should also include it. The problem I am having is that sometimes I have the URL but not the DOI and my conditional formatting is not working well.

Below is the format I have which works for articles without DOI nor URL, and with DOR or URL. However the below conditional formatting does not work well when I have both DOI or URL. I never includes the URL.

Format:
a. “t.” f v$.$i` `(d) p–{,` `$DOI: $u17^, z}`.`

correct result: Bates, William H. “Kingdom—Church: A Biblical Study.” Bibliotheca Sacra 073.292 (1916) 594–608.

correct result with URL only: Combs, William W. “The Preservation of Scripture.” Detroit Baptist Seminary Journal 5 (2000) 3–44, http://www.truth.sg/resources/preservation of bible comb.pdf.

correct result with DOI only: Denham, Sharon. “Relationships Between Family Rituals, Family Routines, and Health.” Journal of Family Nursing 9 (2003) 305–330, DOI: 10.1177/1074840703255447.

incorrect result with both DOI and URL: France, Richard T. “Herod and the Children of Bethlehem.” Novum Testamentum 21.2 (1979) 98–120, DOI: 10.2307/1560717.

it should be: France, Richard T. “Herod and the Children of Bethlehem.” Novum Testamentum 21.2 (1979) 98–120, DOI: 10.2307/1560717, http://www.jstor.org/stable/1560717.

I would really appreciate if someone could help me perfect the conditional formatting.

Thanks,
Moises
Jon
Site Admin
Posts: 10291
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Conditional formatting

Post by Jon »

It's because you didn't allow for the situation where both are present, only the one where the DOI was absent. Something like

a. “t.” f v$.$i` `(d) p–{,` `$DOI: $u17, z^, $DOI: $u17^, z}`.`

(off the top of my head, not tested).

Jon
Sonny Software
mzumaeta
Posts: 13
Joined: Thu Feb 01, 2018 2:48 pm

Re: Conditional formatting

Post by mzumaeta »

Jon,

Tank you very much! It worked great!

Moises
Post Reply