A few time TeamViewer has changed ID’s on me. (Not exactly sure why) But if you can get a command prompt on the machine you can get the ID out using the following query.

UPDATE: Get the latest version here that pulls back the ID for even the latest TeamViewer 13.

Version 9:
reg query HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\TeamViewer\Version9 /v ClientID

Version 10:
reg query HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\TeamViewer\Version10 /v ClientID

Version 11:
reg query HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\TeamViewer /v ClientID

Copy the Hex Value and use a Hex to Decimal converter

There you have your TeamViewer ID.
(You are still have to know the password though, cant help you there)



*** Update 11/05/2017 ***
As pointed out by peter, looks like version 11 just uses the TeamViewer Key.