/build/static/layout/Breadcrumb_cap_w.png

TeamViewer 7 ID in Custom Inventory Field?

Does anyone know how to get the TeamViewer 7 ID into a Custom Inventory Field so that you can find it and search for it in the Kace system inventory?  I thought I had the solution by creating a custom inventory field by using the following syntax, but nothing seems to work and I get garbage or nothing in the custom inventory field on machines that match the label I'm testing on.  I also tried the "NUMBER" type instead of "TEXT" with no luck.

for 64-bit
RegistryValueReturn(HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\TeamViewer\Version7,ClientID,TEXT)
for 32-bit
RegistryValueReturn(HKEY_LOCAL_MACHINE\SOFTWARE\TeamViewer\Version7,ClientID,TEXT)

I followed this as a guide:

http://www.kace.com/support/resources/kb/article/What-are-the-steps-to-create-a-custom-data-field-Inventory?action=artikel&cat=3&id=522&artlang=en

I may be totally barking up the wrong tree here, but I'm hoping someone can point me in the right direction.  Thank you.


0 Comments   [ + ] Show comments

Answers (3)

Answer Summary:
Posted by: Dubnium 12 years ago
Orange Belt
1

What agent version are you running?

 

I had several custom inventory rules for TeamViewer IDs that stopped working when we updated the KACE Agent to 5.3.47173 All of the returned data turned garbled. I went back and forth with KACE trying to find a solution for about two weeks before they said it was a bug. I was told it was submitted to engineering.

It would be interesting to try your custom rule on an older version of the agent. Mine were working great using 5.1.33668


Comments:
  • Dubnium,

    Thanks for the info, at least I'm not going crazy. Unfortunately, I don't have any older clients installed to test with.

    Were you using the same custom inventory field entries that I posted (with the different path for v5, of course)? - badamson 12 years ago
  • We are running Teamviewer v7.0.12979 and Kbox Agent v5.3.47657. - badamson 12 years ago
  • I never got around to setting this up for 64bit, but the 32bit matches. I also tried changing the value type to NUMBER, and the service rep for KACE tried lots of variations.

    If you get a solution, please post it! - Dubnium 12 years ago
Posted by: badamson 10 years ago
Senior Yellow Belt
1

Thanks to all that gave great information.  As mentioned in the comments, with Kace v5.4+ this is easy to do:

http://www.kace.com/support/resources/kb/solutiondetail?sol=SOL111924

Posted by: Dubnium 12 years ago
Orange Belt
1

This has been bothering me... but I think I have a workaround.

Create TVID.bat with the following contents.

 

@Echo off
for /f "skip=2 tokens=3" %%A in ('reg query hklm\software\teamviewer\version7 /v clientid') do set /a var=%%A
echo %var%

 

Save this bat file to a network share.

Now create a cutom inventory rule and point it at the share.

ShellCommandTextReturn ("\\Server\Share\TVID.bat")

 

Make sure to specify that this is for a 32bit Windows OS. So far this has worked on XP and 7. If TeamViewer is not installed the field will display an error message instead of the ID.


Comments:
  • Typo, missed a space.

    @Echo off
    for /f "skip=2 tokens=3" %%A in ('reg query hklm\software\teamviewer\version7 /v clientid') do set /a var=%%A

    echo %var% - Dubnium 12 years ago
  • 64bit script.

    @Echo off
    for /f "skip=2 tokens=3" %%A in ('reg query hklm\software\wow6432node\teamviewer\version7 /v clientid') do set /a var=%%A
    echo %var% - Dubnium 12 years ago
    • I was able to combine these scripts to handle both x64 and x86 architectures and return the TV ID using just 1 custom inventory field:
      -----------------------------
      @Echo off

      IF "%PROCESSOR_ARCHITECTURE%"=="AMD64" goto 64BIT

      for /f "skip=2 tokens=3" %%A in ('reg query hklm\software\teamviewer\version7 /v clientid') do set /a var=%%A

      echo %var%

      goto END

      :64BIT

      for /f "skip=2 tokens=3" %%A in ('reg query hklm\software\wow6432node\teamviewer\version7 /v clientid') do set /a var=%%A

      echo %var%

      goto END

      :END
      exit
      -----------------------------
      However, we do have several clients that still have TeamViewer 5 installed. I'm having trouble determining the best way to modify the above script to also check the 'version5' registry key if 'version7' doesn't exist. Any help is greatly appreciated! - kyle82185 12 years ago
  • Thank you for your suggestion! I did exactly this, and it works great.

    Now I'm trying to incorporate the TeamViewer ID returned by the custom inventory rule into a machine action. I know I can launch a TeamViewer session with the machine action "C:\\Program Files (x86)\\TeamViewer\\Version7\\teamviewer.exe" -i --Password . Does anyone know if I can replace the field with the string from the custom inventory rule (similar to how I can do mstsc.exe /v:KACE_HOST_IP)? - kyle82185 12 years ago
  • Kyle, You will be able to do that with the 5.4 release coming soon. You will be able to use any custom inventory field as a variable in machine actions. Machine actions will also be unlimited instead of just 2. - awenzel@kace.com 12 years ago

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ