<?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 Re: Using &amp;quot;CreateObjectByLogicalName&amp;quot; to connect to a remote SAS Workspace in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172608#M13201</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The best practice to run SAS programs in batch is to run the program directly on the server.&lt;/P&gt;&lt;P&gt;You can start a new SAS session and execute a program with some simple batch files (.bat in Windows, .sh in Linux/Unix). These batch files are usually called by a scheduler like LSF or UC4.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you want to keep the control of the execution at the client side you might want to take a look at the examples #1 and #4 here: &lt;A href="http://sourceforge.net/p/cmdlets4sas/wiki/Connect-SasWorkspaceServer/" title="http://sourceforge.net/p/cmdlets4sas/wiki/Connect-SasWorkspaceServer/"&gt;Cmdlets4Sas / Wiki / Connect-SasWorkspaceServer&lt;/A&gt;&lt;/P&gt;&lt;P&gt;#1 shows how to use the integrated windows authentication&lt;/P&gt;&lt;P&gt;#4 shows how to prompt the user for login credentials&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Good luck!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 09 Jul 2014 13:15:04 GMT</pubDate>
    <dc:creator>AndreasMenrath</dc:creator>
    <dc:date>2014-07-09T13:15:04Z</dc:date>
    <item>
      <title>Using "CreateObjectByLogicalName" to connect to a remote SAS Workspace</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172604#M13197</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I've been experimenting with Chris Hemedinger's scripts for using powershell to connect to a SAS workspace and run SAS jobs (&lt;A href="http://blogs.sas.com/content/sasdummy/2013/03/13/using-powershell-with-sas-workspace/" title="http://blogs.sas.com/content/sasdummy/2013/03/13/using-powershell-with-sas-workspace/"&gt; Using Windows PowerShell to connect to a SAS Workspace server - The SAS Dummy&lt;/A&gt;). That works but requires your loginname and password to be included in the script, which I'd like to avoid if possible.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It should also be possible to connect using the "CreateObjectByLogicalName" method. There's an example here (using Python):&lt;/P&gt;&lt;P&gt;&lt;A href="https://gist.github.com/FriedEgg/9086328" title="https://gist.github.com/FriedEgg/9086328"&gt;Example of how to use SAS Workspace APIs to upload a file to a remote SAS session. Uses SAS LanguageService, FileService and BinarySteam APIs, part of IOM.&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;The main section:&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="line" id="file-sasworkspaceuploadfile-py-LC18"&gt;&lt;SPAN class="c" style="font-family: courier new,courier;"&gt;# create the Integration Technologies objects&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="line" id="file-sasworkspaceuploadfile-py-LC19"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;SPAN class="n"&gt;objFactory&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;win32com&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;client&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;Dispatch&lt;/SPAN&gt;&lt;SPAN class="p"&gt;(&lt;/SPAN&gt;&lt;SPAN class="s"&gt;"SASObjectManager.ObjectFactoryMulti2"&lt;/SPAN&gt;&lt;SPAN class="p"&gt;)&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="line" id="file-sasworkspaceuploadfile-py-LC20"&gt;&lt;/P&gt;&lt;P class="line" id="file-sasworkspaceuploadfile-py-LC21"&gt;&lt;SPAN class="c" style="font-family: courier new,courier;"&gt;# these xml files can be created using the SAS Integration Technologies Configutation Utility&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="line" id="file-sasworkspaceuploadfile-py-LC22"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;SPAN class="n"&gt;objFactory&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;SetMetadataFile&lt;/SPAN&gt;&lt;SPAN class="p"&gt;(&lt;/SPAN&gt; &lt;SPAN class="s"&gt;"C:/path/to/serverinfo.xml"&lt;/SPAN&gt; &lt;SPAN class="p"&gt;,&lt;/SPAN&gt; &lt;SPAN class="s"&gt;"C:/path/to/userinfo.xml"&lt;/SPAN&gt; &lt;SPAN class="p"&gt;,&lt;/SPAN&gt; &lt;SPAN class="bp"&gt;False&lt;/SPAN&gt; &lt;SPAN class="p"&gt;)&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="line" id="file-sasworkspaceuploadfile-py-LC23"&gt;&lt;/P&gt;&lt;P class="line" id="file-sasworkspaceuploadfile-py-LC24"&gt;&lt;SPAN class="c" style="font-family: courier new,courier;"&gt;# create a connection to the SAS Workspace Server&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="line" id="file-sasworkspaceuploadfile-py-LC25"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;SPAN class="n"&gt;objSAS&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;objFactory&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;CreateObjectByLogicalName&lt;/SPAN&gt;&lt;SPAN class="p"&gt;(&lt;/SPAN&gt; &lt;SPAN class="s"&gt;"SASApp - Logical Workspace Server"&lt;/SPAN&gt; &lt;SPAN class="p"&gt;,&lt;/SPAN&gt; &lt;SPAN class="s"&gt;""&lt;/SPAN&gt; &lt;SPAN class="p"&gt;)&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="line"&gt;&lt;SPAN class="p"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="line"&gt;&lt;SPAN class="p"&gt;I've used ITConfig to create a default connection to the metadataserver. That creates "oms_serverinfo2.xml" and "oms_userinfo2.xml" in "%USERPROFILE%\AppData\Roaming"\SAS\MetadataServer", the latter contains my password in encrypted form.&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="line"&gt;&lt;SPAN class="p"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="line"&gt;&lt;SPAN class="p"&gt;In Powershell, I create objFactory using the syntax from Chris's examples:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;$objFactory = New-Object -ComObject SASObjectManager.ObjectFactoryMulti2&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P class="line"&gt;&lt;SPAN class="p"&gt;If I understand the documentation, I should be able to connect without pointing to my metadata but I've defined that just to be sure&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="line"&gt;&lt;SPAN class="p" style="font-family: courier new,courier;"&gt;$objFactory.SetMetadataFile( "&amp;lt;path&amp;gt;\oms_serverinfo2.xml" , "&amp;lt;path&amp;gt;r\oms_userinfo2.xml" , $FALSE )&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="line"&gt;&lt;SPAN class="p"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="line"&gt;&lt;SPAN class="p"&gt;Now, I should be able to create a workspace object using:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;$objSAS = $objFactory.CreateObjectByLogicalName("SASApp - Logical Workspace Server" , "" )&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This doesn't work though, I get an error:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;Exception calling "CreateObjectByLogicalName" with "2" argument(s): "&amp;lt;connectionAttempts&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;connectionAttempt&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;description&amp;gt;Cannot locate an identity in metadata for the specified identity id ().&amp;lt;/description&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;status&amp;gt;0x80042102&amp;lt;/status&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;saslogin&amp;gt;&amp;lt;/saslogin&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;sasmachinednsname&amp;gt;&amp;lt;/sasmachinednsname&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;sasport&amp;gt;8591&amp;lt;/sasport&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;sassecuritypackage&amp;gt;Negotiate&amp;lt;/sassecuritypackage&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;sassecuritypackagelist&amp;gt;Kerberos,NTLM&amp;lt;/sassecuritypackagelist&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;sasclassid&amp;gt;&amp;lt;/sasclassid&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;sasprogid&amp;gt;SAS.Workspace.1.0&amp;lt;/sasprogid&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;sasserver&amp;gt;SASApp - Workspace Server&amp;lt;/sasserver&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;sasdomain&amp;gt;DefaultAuth&amp;lt;/sasdomain&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;threadid&amp;gt;2280&amp;lt;/threadid&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;sasauthenticationservice&amp;gt;Host&amp;lt;/sasauthenticationservice&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/connectionAttempt&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;lt;/connectionAttempts&amp;gt;"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;At line:1 char:48&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;+ $objSAS = $objFactory.CreateObjectByLogicalName &amp;lt;&amp;lt;&amp;lt;&amp;lt; ("SASApp - Logical Workspace Server" , "" )&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; + CategoryInfo&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : NotSpecified: (:) [], MethodInvocationException&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier; font-size: 8pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; + FullyQualifiedErrorId : ComMethodTargetInvocation&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The server doesn't seem to be able to find who I am. Does anyone know what I might be doing wrong here?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The few examples I've been able to find using "CreateObjectByLogicalName" use two arguments, the server's logical name and an empty string. The SAS documentation though, specifies 4 arguments:&lt;/P&gt;&lt;P&gt;&lt;A href="http://support.sas.com/documentation/cdl/en/itechwcdg/64888/HTML/default/viewer.htm#p05uy6cy21o83vn15ev4mxlhkkox.htm" title="http://support.sas.com/documentation/cdl/en/itechwcdg/64888/HTML/default/viewer.htm#p05uy6cy21o83vn15ev4mxlhkkox.htm"&gt;SAS(R) 9.4 Integration Technologies: Windows Client Developer's Guide&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So I've also tried:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;$objSAS = $objFactory.CreateObjectByLogicalName("SASApp", $TRUE, "SASApp - Logical Workspace Server" , "")&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In that case, I get an error&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Cannot find an overload for "CreateObjectByLogicalName" and the argument count: "4".&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;At line:1 char:48_te&lt;/P&gt;&lt;P&gt;+ $objSAS = $objFactory.CreateObjectByLogicalName &amp;lt;&amp;lt;&amp;lt;&amp;lt; ("SASApp", $TRUE, "SASApp - Logical Workspace Server" , "" )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; + CategoryInfo&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : NotSpecified: (:) [], MethodException&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; + FullyQualifiedErrorId : MethodCountCouldNotFindBest&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That sounds like I just shouldn't be using 4 arguments.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope someone can help with this. The SAS server runs SAS 9.4, the server itself is Windows 2008 R2.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Jul 2014 09:41:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172604#M13197</guid>
      <dc:creator>jhckx</dc:creator>
      <dc:date>2014-07-09T09:41:49Z</dc:date>
    </item>
    <item>
      <title>Re: Using "CreateObjectByLogicalName" to connect to a remote SAS Workspace</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172605#M13198</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The good news is that i can recreate your problem in my environment (SAS 9.3, Windows 7 x64) too.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So i guess this is a general bug in the SAS IT Client.&lt;/P&gt;&lt;P&gt;The documentation file sasoman.chm in the IT Client folder !SASHOME\x86\Integration Technologies only knows the 2 argument version of the method CreateObjectByLogicalName. There is a CreateObjectByLogicalNameAndLogins method with 5 arguments which has a similar signature to the web documentation (&lt;A href="http://support.sas.com/documentation/cdl/en/itechwcdg/64888/HTML/default/viewer.htm#p05uy6cy21o83vn15ev4mxlhkkox.htm" title="http://support.sas.com/documentation/cdl/en/itechwcdg/64888/HTML/default/viewer.htm#p05uy6cy21o83vn15ev4mxlhkkox.htm"&gt;http://support.sas.com/documentation/cdl/en/itechwcdg/64888/HTML/default/viewer.htm#p05uy6cy21o83vn15ev4mxlhkkox.htm&lt;/A&gt;). IMHO the web documentation is totally wrong in this case.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As a side note: welcome to the SAS IOM hell!&lt;/P&gt;&lt;P&gt;It is poorly documented, many documented features do not work as expected and many important features are not documented. The only solution for these problems is a lot of trial and error coding.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Back to your problem:&lt;/P&gt;&lt;P&gt;accourding to the error message&lt;/P&gt;&lt;PRE __jive_macro_name="quote" class="jive_text_macro jive_macro_quote"&gt;
&lt;P&gt;&amp;lt;sassecuritypackage&amp;gt;Negotiate&amp;lt;/sassecuritypackage&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;lt;sassecuritypackagelist&amp;gt;Kerberos,NTLM&amp;lt;/sassecuritypackagelist&amp;gt;&lt;/P&gt;

&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the IT client tries to connect to the server using the integrated windows authentication method and not the user/password combination. Maybe the Workspaceserver needs to be reconfigured with the SAS Management Console to use Security package "Username/Password":&lt;/P&gt;&lt;P&gt;&lt;IMG alt="" class="jiveImage" src="https://communities.sas.com/legacyfs/online/6794_pastedImage_0.png" style="width: 745px; height: 663px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you describe what you want to achieve after you have connected to the server?&lt;/P&gt;&lt;P&gt;Maybe my PowerShell commandlets (&lt;A href="http://sourceforge.net/projects/cmdlets4sas/" title="http://sourceforge.net/projects/cmdlets4sas/"&gt;http://sourceforge.net/projects/cmdlets4sas/&lt;/A&gt;) already cover your needs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Greetings,&lt;/P&gt;&lt;P&gt;Andreas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Jul 2014 11:58:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172605#M13198</guid>
      <dc:creator>AndreasMenrath</dc:creator>
      <dc:date>2014-07-09T11:58:41Z</dc:date>
    </item>
    <item>
      <title>Re: Using "CreateObjectByLogicalName" to connect to a remote SAS Workspace</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172606#M13199</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You might have better luck by looking at my C# example for .NET.&amp;nbsp; It's described here:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://blogs.sas.com/content/sasdummy/2013/06/09/sas-client-with-microsoft-dot-net/" title="http://blogs.sas.com/content/sasdummy/2013/06/09/sas-client-with-microsoft-dot-net/"&gt;&amp;nbsp; Build your own SAS client app with Microsoft .NET - The SAS Dummy&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The code&lt;A href="https://github.com/cjdinger/SasHarness"&gt; is on GitHub&lt;/A&gt;, and the specific connection logic is &lt;A href="https://github.com/cjdinger/SasHarness/blob/master/SasServer.cs"&gt;in the SasServer class in this C# file&lt;/A&gt;. In that example, you can see how we can leave the user/pw out by specifying "Negotiate" for the BridgeSecurityProtocol -- but this assumes that you've configured your environment for single-signon/integrated Windows authentication.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Chris&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Jul 2014 12:52:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172606#M13199</guid>
      <dc:creator>ChrisHemedinger</dc:creator>
      <dc:date>2014-07-09T12:52:44Z</dc:date>
    </item>
    <item>
      <title>Re: Using "CreateObjectByLogicalName" to connect to a remote SAS Workspace</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172607#M13200</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Andreas,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;At the least, "sasoman.chm" cleared up the "4 vs 2 arguments" issue. If you look in the index, there are two entries for "CreateObjectByLogicalName" (and most other "create" methods), with 4 arguments for "ObjectFactory" and with 2 arguments for "ObjectFactory2".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What I want to do is to run SAS programs in batch. I can do that now using VBScripts that create an "Enterprise Guide" object (also from posts by Chris Hemedinger) but I'd prefer to bypass EG and create a workspace object directly. I've modified the VBScript to do that but it requires that userid and password are included in the script and that's not a good idea from a security point of view. "CreateObjectByLogicalName" seemed like what I was looking for but I suspect you're right and that the server is configured for integrated windows authentication.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Does anyone know how to create a Workspace object without including the user password?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your help Andreas!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Jul 2014 13:03:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172607#M13200</guid>
      <dc:creator>jhckx</dc:creator>
      <dc:date>2014-07-09T13:03:46Z</dc:date>
    </item>
    <item>
      <title>Re: Using "CreateObjectByLogicalName" to connect to a remote SAS Workspace</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172608#M13201</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The best practice to run SAS programs in batch is to run the program directly on the server.&lt;/P&gt;&lt;P&gt;You can start a new SAS session and execute a program with some simple batch files (.bat in Windows, .sh in Linux/Unix). These batch files are usually called by a scheduler like LSF or UC4.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you want to keep the control of the execution at the client side you might want to take a look at the examples #1 and #4 here: &lt;A href="http://sourceforge.net/p/cmdlets4sas/wiki/Connect-SasWorkspaceServer/" title="http://sourceforge.net/p/cmdlets4sas/wiki/Connect-SasWorkspaceServer/"&gt;Cmdlets4Sas / Wiki / Connect-SasWorkspaceServer&lt;/A&gt;&lt;/P&gt;&lt;P&gt;#1 shows how to use the integrated windows authentication&lt;/P&gt;&lt;P&gt;#4 shows how to prompt the user for login credentials&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Good luck!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Jul 2014 13:15:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172608#M13201</guid>
      <dc:creator>AndreasMenrath</dc:creator>
      <dc:date>2014-07-09T13:15:04Z</dc:date>
    </item>
    <item>
      <title>Re: Using "CreateObjectByLogicalName" to connect to a remote SAS Workspace</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172609#M13202</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Chris, "negotiate" did the trick!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For anyone else sweating in IOM Hell, here's what works for me:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;' force declaration of variables in VB Script&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Option Explicit&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Dim objFactory, objServerDef, objSAS, program, log&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Set objFactory = WScript.CreateObject("SASObjectManager.ObjectFactoryMulti2")&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Set objServerDef = WScript.CreateObject("SASObjectManager.ServerDef")&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;objServerDef.MachineDNSName = "SASServer" ' SAS Workspace node&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;objServerDef.Port = 8591 ' workspace server port&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;objServerDef.Protocol = 2 ' 2 = IOM protocol&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;'This assumes that you've configured your environment for single-signon/integrated Windows authentication.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;objServerDef.BridgeSecurityPackage = "Negotiate"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;' Class Identifier for SAS Workspace&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;objServerDef.ClassIdentifier = "440196d4-90f0-11d0-9f41-00a024bb830c"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;' create and connect to the SAS session&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Set objSAS = objFactory.CreateObjectByServer("SASApp",True,objServerDef,"","")&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;program = "ods listing; proc means data=sashelp.cars mean mode min max; run;"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;' run the program&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;objSAS.LanguageService.Submit(program)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Dim loglines&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;loglines=""&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;do&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; loglines=objSAS.LanguageService.FlushLog(1000)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; wscript.echo loglines&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;loop while Len(loglines) &amp;gt; 0&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;objSAS.Close()&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Jul 2014 13:43:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172609#M13202</guid>
      <dc:creator>jhckx</dc:creator>
      <dc:date>2014-07-09T13:43:56Z</dc:date>
    </item>
    <item>
      <title>Re: Using "CreateObjectByLogicalName" to connect to a remote SAS Workspace</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172610#M13203</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I spoke too soon &lt;img id="smileysad" class="emoticon emoticon-smileysad" src="https://communities.sas.com/i/smilies/16x16_smiley-sad.png" alt="Smiley Sad" title="Smiley Sad" /&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The negotiate method does work to the extent that I can connect to the SAS server and e.g. create data from scratch or use builtin datasets. But I'm not recognized as my userid so I can't include files or define libnames to data I have access too. Complicated.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Jul 2014 15:20:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172610#M13203</guid>
      <dc:creator>jhckx</dc:creator>
      <dc:date>2014-07-09T15:20:14Z</dc:date>
    </item>
    <item>
      <title>Re: Using "CreateObjectByLogicalName" to connect to a remote SAS Workspace</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172611#M13204</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;For IWA to work, your identity still needs to exist in SAS Metadata.&amp;nbsp; You need your IWA "login" to be associated with your User object in SAS Metadata, and thus have access to your permitted resources.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If your SAS environment is not truly administered for IWA, then you might be stuck having to provide credentials in a script.&amp;nbsp; You might be able to create a more sophisticated script that pulls cached credentials from your SAS metadata profile files in the %APPDATA% area, but you'll still have to transmit them somehow.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Chris&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Jul 2014 15:31:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172611#M13204</guid>
      <dc:creator>ChrisHemedinger</dc:creator>
      <dc:date>2014-07-09T15:31:14Z</dc:date>
    </item>
    <item>
      <title>Re: Using "CreateObjectByLogicalName" to connect to a remote SAS Workspace</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172612#M13205</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well, the real disappointment was that a batch run over VPN was just as slow with a script based on a Workspace object as with a script based on an EG object. I'd hoped that using a Workspace object would avoid some of the overhead involved with EG but that doesn't look like it's the case.A fairly simple job took over a minute using the Workspace script over a VPN connection versus 5 seconds on the office network using the EG script.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now I know how the Dutch team feels after losing from Argentine :smileycry:.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 Jul 2014 06:50:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172612#M13205</guid>
      <dc:creator>jhckx</dc:creator>
      <dc:date>2014-07-10T06:50:20Z</dc:date>
    </item>
    <item>
      <title>Re: Using "CreateObjectByLogicalName" to connect to a remote SAS Workspace</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172613#M13206</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;A number of discussions are on the forums about using EG over remote / VPN connections. You might look them up, and see if anybody has a resolution to your issue.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm working over a remote Citrix connection, and I can literally count Mississippis while I wait for the characters to appear when I start touch typing...I feel your pain!!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tom&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;P.S. There's always 2018!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 Jul 2014 12:10:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172613#M13206</guid>
      <dc:creator>TomKari</dc:creator>
      <dc:date>2014-07-10T12:10:15Z</dc:date>
    </item>
    <item>
      <title>Re: Using "CreateObjectByLogicalName" to connect to a remote SAS Workspace</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172614#M13207</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Since you've got your own script now, you could add some timings to see exactly where the bottleneck is.&amp;nbsp; Is slow to make the connection? Run the code? Or retrieve the results?&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It might be simply academic, since perhaps there isn't anything you can do to help with it.&amp;nbsp; But it might provide you some news you can use....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Chris&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 Jul 2014 12:44:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172614#M13207</guid>
      <dc:creator>ChrisHemedinger</dc:creator>
      <dc:date>2014-07-10T12:44:15Z</dc:date>
    </item>
    <item>
      <title>Re: Using "CreateObjectByLogicalName" to connect to a remote SAS Workspace</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172615#M13208</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;We used to have the problem of the screen not keeping up with our typing but IT upgraded our VMWare system and it works great now. I can get good performance with my EG batch script if I run it from an editor located on the company intranet. Performance is bad though if run the editor from the hard drive on my laptop. I use PSPad as editor, it doesn't need an install program so I can put it on my local network share and run it from there when I'm using VMWare.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 Jul 2014 15:10:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Using-quot-CreateObjectByLogicalName-quot-to-connect-to-a-remote/m-p/172615#M13208</guid>
      <dc:creator>jhckx</dc:creator>
      <dc:date>2014-07-10T15:10:46Z</dc:date>
    </item>
  </channel>
</rss>

