<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Getting current logged in user in Vault Customization Forum</title>
    <link>https://forums.autodesk.com/t5/vault-customization-forum/getting-current-logged-in-user/m-p/12447659#M1227</link>
    <description>&lt;P&gt;I made a few custom tools in Vault that i want to hide for people who are not admin or lead engineer.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The problem is that&amp;nbsp;VDF.Vault.Library.ConnectionManager.LogIn() requires a password and a name. Right now i hardcoded the admin credentials to call this function and it will return a Connection object with the admin credentials inside (ofcourse).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What i want is to call&amp;nbsp;VDF.Vault.Library.ConnectionManager.LogIn() with the credentials of the user that is logged in:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="jaapflonk_1-1702890187604.png" style="width: 600px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1305812i1A4FCEDA333449D1/image-size/medium?v=v2&amp;amp;px=400" role="button" title="jaapflonk_1-1702890187604.png" alt="jaapflonk_1-1702890187604.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Or another solution would be to still login as admin in my code,&amp;nbsp; but somehow get the current logged in user in Vault:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="jaapflonk_2-1702890471735.png" style="width: 600px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1305814i1E9648048CEE671D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="jaapflonk_2-1702890471735.png" alt="jaapflonk_2-1702890471735.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Some help or example code would be greatly appreciated!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 18 Dec 2023 09:09:51 GMT</pubDate>
    <dc:creator>jaapflonk</dc:creator>
    <dc:date>2023-12-18T09:09:51Z</dc:date>
    <item>
      <title>Getting current logged in user</title>
      <link>https://forums.autodesk.com/t5/vault-customization-forum/getting-current-logged-in-user/m-p/12447659#M1227</link>
      <description>&lt;P&gt;I made a few custom tools in Vault that i want to hide for people who are not admin or lead engineer.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The problem is that&amp;nbsp;VDF.Vault.Library.ConnectionManager.LogIn() requires a password and a name. Right now i hardcoded the admin credentials to call this function and it will return a Connection object with the admin credentials inside (ofcourse).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What i want is to call&amp;nbsp;VDF.Vault.Library.ConnectionManager.LogIn() with the credentials of the user that is logged in:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="jaapflonk_1-1702890187604.png" style="width: 600px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1305812i1A4FCEDA333449D1/image-size/medium?v=v2&amp;amp;px=400" role="button" title="jaapflonk_1-1702890187604.png" alt="jaapflonk_1-1702890187604.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Or another solution would be to still login as admin in my code,&amp;nbsp; but somehow get the current logged in user in Vault:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="jaapflonk_2-1702890471735.png" style="width: 600px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1305814i1E9648048CEE671D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="jaapflonk_2-1702890471735.png" alt="jaapflonk_2-1702890471735.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Some help or example code would be greatly appreciated!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 18 Dec 2023 09:09:51 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vault-customization-forum/getting-current-logged-in-user/m-p/12447659#M1227</guid>
      <dc:creator>jaapflonk</dc:creator>
      <dc:date>2023-12-18T09:09:51Z</dc:date>
    </item>
    <item>
      <title>Re: Getting current logged in user</title>
      <link>https://forums.autodesk.com/t5/vault-customization-forum/getting-current-logged-in-user/m-p/12447667#M1228</link>
      <description>A standalone application requires a dedicated login, like Inventor and Vault Explorer login explicitly. So, Vault extensions can re-use the VE connection, or other Inventor Add-Ins can re-use the Inventor-Vault connection.</description>
      <pubDate>Mon, 18 Dec 2023 09:17:16 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vault-customization-forum/getting-current-logged-in-user/m-p/12447667#M1228</guid>
      <dc:creator>Markus.Koechl</dc:creator>
      <dc:date>2023-12-18T09:17:16Z</dc:date>
    </item>
    <item>
      <title>Re: Getting current logged in user</title>
      <link>https://forums.autodesk.com/t5/vault-customization-forum/getting-current-logged-in-user/m-p/12447694#M1229</link>
      <description>&lt;P&gt;Thanks for the reply&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/33301"&gt;@Markus.Koechl&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I got it to work.&lt;/P&gt;</description>
      <pubDate>Mon, 18 Dec 2023 10:30:12 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/vault-customization-forum/getting-current-logged-in-user/m-p/12447694#M1229</guid>
      <dc:creator>jaapflonk</dc:creator>
      <dc:date>2023-12-18T10:30:12Z</dc:date>
    </item>
  </channel>
</rss>

