Verses can be formatted using a custom format string:

Reference myRef;
Reference.TryParse("gn 4:6", "esv", out myRef); // parse reference
myVerse = myRef.FirstOfDefault(); // get first verse
string texta = string.Format("{0:BBB c:v}", myVerse); // returns "Genesis 4:6"
string textb = string.Format("{0:b c.v (t)}", myVerse); // returns "gn 4.6 (esv)"


The following custom format string elements can be used:
  • BBB - Capitalized name of book (eg. Genesis)
  • BB - Capitalized long abbreviation of book (eg. Gen)
  • B - Capitalized short abbreviation of book (eg. Gn)
  • bbb - Lower case name of book (eg. genesis)
  • bb - Lower case long abbreviation of book (eg. gen)
  • b - Lower case short abbreviation of book (eg. gn)
  • c - Chapter number
  • v - Verse number
  • n - Name of scripture (eg. Holy Bible)
  • tt - Name of scripture translation (eg. English Standard Version)
  • T - Uppercase translation of scripture translation (eg. ESV)
  • t - Lowercase translation of scripture translation (eg. esv)

Last edited Mar 2, 2013 at 2:56 AM by skonves, version 2

Comments

No comments yet.