Disclosed are compounds of formula I, II and III, and pharmaceutically acceptable derivatives thereof, which are suitable for treating or preventing a condition such as pain, urinary incontinence (UI), an ulcer, inflammatory bowel disease (IBD), and irritable bowel syndrome (IBS). Also disclosed is the use of compound of formula I, II, and III in in the production of a medicament for inhibiting TRPV1 function in a cell. An example of a compound of formula I has the systematic name, (S)-3 -chloro-5-(1,2-dihydroxy-ethyl)-3',6'-dihydro-2'H-[2,4']bipyridinyl-1'-carboxylic acid (4-tert-butyl-phenyl)amide.