Remove ArcSDE Connection details from a layer file?

636
2
01-19-2012 05:53 AM
ChrisBuckmaster1
Occasional Contributor
Hi


I am not sure if this is the correct sub forum but I will give it a go!

I found an ArcScript a while ago for version 9.1 that allowed you to remove the ArcSDE connection details for layer files which meant that any user could drag this into ArcMap, be prompted for their user name and password, enter it and view the layer with their privileges.

Unfortunately in upgrading to version 10 I have lost this function and am wondering if there is something available for v.10 that will allow me to do this? I believe the original script was created by Sue Jones.


Thanks
0 Kudos
2 Replies
MHawkins
New Contributor
Have you found any information on this? I'm trying to perform a similar task, setting the user id and password to values previously set by the user. I seem to be able to get and set the user id and view all the connection properties in the connection string but when I try to get or set the password I get an error.

              
 If Not GxLayer Is Nothing Then
                    DataLayer = GxLayer.Layer
                    WrkSpcName = New WorkspaceName
                    DSN = DataLayer.DataSourceName
                    WrkSpcName = DSN.WorkspaceName
                    ConnProperties = WrkSpcName.ConnectionProperties
                    ConnProperties.SetProperty("USER", "user id here")
                    ConnProperties.SetProperty("PASSWORD", "password here")
                    ...
                 


The original tool that performed this task was written in VBA and I believe it was last used with ArcGIS 9.2. I'm trying to upgrade it to work with ArcGIS 10, Win 7. Any information you have would help.

Thanks,

Mark
0 Kudos
ChrisBuckmaster1
Occasional Contributor
Just bumping this thread up again, can anyone help with this request please?
0 Kudos