Hello!
It strongly depends on general meaning of the sentence as particles 'не' and 'ни' have different function.
1) In an affirmative sentence, 'ни' emphasizes that the fact happened or didn't happen despite circumstances (time, place and etc) expressed in the subordinate clause. For example,
"Где бы он ни находился, гора всегда была видна" = 'Wherever he went, the mountain always could be seen'
"Кого бы она ни спросила, никто о нём не слышал" = 'Whoever she asked, no one knew him.'
2) As you noted, 'не' particle is used for negation, but in case of 'whenever', 'wherever' and etc. it can replace 'ни' and go with them if a sentence itself is negative. In that case I'd say it's an affirmance expressed through double negation. For example,
"Нет таких мест, где бы мы не побывали". = 'There's no such a place, where I haven't been (=I've been everywhere)'.
"Нет никого, кто бы не слышал о Пушкине". = 'There's no one who hasn't heard about Pushkin (=Everybody knows Pushkin)'.
I hope, it helped you to get a little better understanding of 'не' и 'ни'!