POST
|
I am in the midst of converting 10.2.1 code to run against our new 10.6.1 software and I have run into this exact same issue. Did you find the culprit?
... View more
07-16-2020
11:47 AM
|
0
|
2
|
1043
|
POST
|
We have the same request but for a slightly different reason. We are moving to a VDI structure of Virtual Machines for users, so when a user logs off it quite literally destroys the C: drive for the image the user was on, and the Survey 123 data with it. Please allow saving to a network location.
... View more
01-18-2019
11:48 AM
|
6
|
0
|
1619
|
POST
|
Thank you Wayne. That missing \ was the ticket. I just could not see it, no matter how long I stared at the code.
... View more
04-07-2014
06:09 AM
|
0
|
0
|
3947
|
POST
|
I'm having a similar problem, but I cannot see what I am doing wrong. import arcpy
from arcpy import env
env.workspace = r"F:Replicated Data\Auto_Extract_Connection.sde"
datasetList = arcpy.ListDatasets()
print datasetList
env.workspace = r"F:\Replicated Data\Gatekeeper_Extract.gdb"
datasetList = arcpy.ListDatasets()
print datasetList This returns [] [u'ElectricDataset', u'CPUDataset', u'TransmissionDataset'] It's clearly connecting to the file GDB but won't connect to the SDE one. I know the connection file is working, I can connect with it through Catalog.
... View more
04-04-2014
10:49 AM
|
0
|
0
|
3947
|
POST
|
Alright. Perhaps I'm missing something, but I don't see an assignment of the new version to the current map prior to updating. pVersionedWorkspace = pOldWorkspace as IVersionedWorkspace; <-- convert your current workspace to a versioned workspace pVersion = pVersionedWorkspace.FindVersion(versionName); <-- get a hold of a specific version called versionName ??assign the current map to use pVersion?? Run Update Contents Updating the contents without the missing link above only refreshes the current version, not the map with the new version. How do you assign the pVersion to the current document?
... View more
01-15-2014
06:55 AM
|
0
|
0
|
664
|
POST
|
Try following code :
public void ChangeVersion(IMxDocument MxDoc, IFeatureWorkspace OldWorkspace, string versionName)
{
try
{
//validation
if ((pMxDoc == null) || (pOldWorkspace == null) || (String.IsNullOrEmpty(versionName) == true))
{
return;
}
if (!(pOldWorkspace is IVersionedWorkspace))
{
return;
}
IVersionedWorkspace pVersionedWorkspace;
IVersion pVersion;
pVersionedWorkspace = pOldWorkspace as IVersionedWorkspace;
pVersion = pVersionedWorkspace.FindVersion(versionName);
if (pVersion == null)
{
return;
}
//update the layers in the mxdoc
}
catch (Exception ex)
{
}
}
Thanks for the suggestions Sanajy and Leo. I have no trouble getting the version I am trying to switch to (using IVersionedWorkspace), the problem I have is trying to get arcmap to reflect that version instead of the current one. I see no setters in any of the interfaces I have looked at for telling the currently viewed map to change the version it is looking at. So I guess what I'm saying is, in Sanajy's code I'm having trouble with the line //update layers in the mxdoc Any further suggestions would be welcome.
... View more
01-07-2014
09:26 AM
|
0
|
0
|
664
|
POST
|
Sorry for the confusion. I am looking for a way to change the version of our SDE Geodatabase that the map is currently pointed at, e.g. from SDE.Default to editor.Editversion. Just like can be done manually by right clicking the version in Source tab of the TOC and selecting change version.
... View more
12-23-2013
10:23 AM
|
0
|
0
|
664
|
POST
|
I'm trying to automatically change the version the user is connected to in ArcMap when a button is pushed but I'm having trouble finding the correct code interface. This is the first time I have had trouble finding the correct code and I am wondering if it is just not possible. _thisMap = _mHookHelper.FocusMap; IEnumLayer selLayers = _thisMap.get_Layers(pUID, true); ILayer aLayer = selLayers.Next(); if (aLayer == null) { throw new Exception("No Layers Present"); } IFeatureLayer a_FLayer = (IFeatureLayer) aLayer; IFeatureClass a_FClass = a_FLayer.FeatureClass; ITable aTable = (ITable) a_FClass; IDataset aDS = (IDataset) aTable; _aWS = aDS.Workspace; IPropertySet pSet = _aWS.ConnectionProperties; object pProp = pSet.GetProperty("Version"); string verName = pProp.ToString(); if (!verName.Contains(editVersion)) { CHANGE VERSION IN TOC HERE AUTOMATICALLY }
... View more
12-23-2013
07:29 AM
|
0
|
10
|
1901
|
POST
|
Does anyone have an answer to the resizing question? I'm in the same boat, and brand new to Flex. The generic InfoSymbol that runs on my Identify Widget is not wide enough to accomodate addresses without cutting them off or scrolling and I want to make it wide enough to show the whole thing.
... View more
03-15-2012
12:06 PM
|
0
|
0
|
220
|
POST
|
I'm recieving the The breakpoint will not currently be hit. The source code is different then the original version message on all breakpoints after following the Migrating ArcGIS 9.3 Desktop and Engine custom components to ArcGIS 10 steps. This occurs on all migrated code as well as a simple 'Hello World' button I created in 10 as a test. Disabling the "Require the source version to exactly match the origional version" option in VS Tools>Options>Debugging fixes this issue, but that doesnt sit right with me. Is anyone else having this issue with their (NON ADD-IN) projects, and what was done to correct this issue?
... View more
11-07-2011
07:39 AM
|
0
|
0
|
775
|
Title | Kudos | Posted |
---|---|---|
6 | 01-18-2019 11:48 AM |
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:24 AM
|