Q: What bass string to use?
A: Use the string that has the note you want to play as the lowest note. If you want to play the chord's root note as the lowest note, then use the string that has the root note. If you want to play some other note as the bass note, then use whatever string has that note.
The bass note and the root note of the chord are not necessarily the same thing. The bass note is the lowest played note, and if it's not the root, then the chord can be said to be an "inversion" - or it can be an alternating bass line, which doesn't really sound like an inversion, when the non-root note is played on a weaker beat.
If you learn to play alternating bass, then you'll have to learn which of the notes in a chord fingering is the root note. In a common alternating bass pattern, you first play the root as the bass note, then the 5th as the bass note, and repeat. Root, 5th, root, 5th, ...
Here is Dm and A7 played with open position chords:
Here are the same chords with barre grips:
And here's what it sounds like:
If you want to play "fingerstyle" guitar, then the alternating root - 5th bass pattern is a basic thing you need to know. After you get that going fluently, you can start using more advanced bass lines.