All information for connecting to an Oracle database may be stored in a tnsnames.ora file, with each database instance defined by a TNS alias. If you want to create a connection in DbVisualizer that uses the information from this file, you must first tell DbVisualizer where it is stored by setting either the TNS_ADMIN environment variable to the path of the folder holding the file, or making sure it is located in the ORACLE_HOME/network/admin folder and that the ORACLE_HOME environment variable is set.

How to set an environment variable differs greatly between operating systems and between shells (on Unix-based platforms). This article provides tips for various Windows versions: For other platforms, please search the net for ideas if you don't know how to do it.

Note! On macOS, environment variables set in .bash_profile or similar are not available to applications started via Spotlight or by double-clicking an app icon. The launchctl command can be used to set these environment variables instead, for instance from the .bash_profile script. This thread discusses an alternative solutions for Yosemite and El Capitan:

When this configuration is done, you can select TNS from the Connection Type list for the Oracle connection and then pick the TNS alias from a list of all aliases found in the file.