Skip to content

Class CSharpLib.Bible

Samuel edited this page May 16, 2021 · 1 revision

NOTE: As of CSharpLib version 2.5.8, this class is in package CSBible.

CSharpLib.Bible is a class for Bible actions. To use it, first create an instance:

using CSharpLib;

Bible b = new Bible();

Now you can use the verse functions. For example, using GetVerse():

string verse = b.GetVerse(Book.Genesis, 1, 1);

The method GetChapter() returns a string array of verses that make up the specified chapter:

string[] chapter = b.GetChapter(Book.Genesis, 1);

NOTE: The array that this method returns is not zero-based (i.e. index 1 is verse 1, index 2 is verse 2, etc.).

When you are finished and BEFORE another instance is created, you must call Close():

b.Close();

The current methods and their functions are listed below:

  • GetVerse(Book book, int chapter, int verse)
  • GetChapter(Book book, int chapter)
Added in version 2.4.5:
  • GetChapter(Book book, int chapter, bool zeroBased)
  • GetChapterAsList(Book book, int chapter)
  • GetChapterAsList(Book book, int chapter, bool zeroBased)