AutoCAD Map 3D Developer
Welcome to Autodesk’s AutoCAD Map 3D Developer Forums. Share your knowledge, ask questions, and explore popular AutoCAD Map 3D Developer topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

MSSQL+Oracle Spatial: Problem with AcMapLayer.ForceRefresh(pFeatureIds)

8 REPLIES 8
Reply
Message 1 of 9
Anonymous
549 Views, 8 Replies

MSSQL+Oracle Spatial: Problem with AcMapLayer.ForceRefresh(pFeatureIds)

Hello,

 

"data connect" to MSSQL/Oracle spatial in Map 3D (using database views, I had to puzzle around a little bit to get it working: http://forums.autodesk.com/t5/AutoCAD-Map-3D-Developer/MSSQL-Oracle-Spatial-Refresh-cache-partially-...).

 

When I call AcMapLayer.ForceRefresh(pFeatureIds) for some of the layers, I get an exception:
"Can not update objects" (in German), AcMapVectorLayer.ForceRefresh line 1616 file AcMapVectorLayer.cpp.

 

The same code is working for most layers, but for some layers I get this exception. I don't see what's wrong with these layers.

All problematic layers have in common, that I use them to display "text only":

- All features are POINT features (no Z values)

- SimpleSymbolDefinition.Graphics = new[] { new Text { ... } }

- But that should be no problem, because refreshing the feature cache should have nothing to to with "text rendering", I think!?

 

The bevavior for MSSQL and Oracle is exactly the same (the structure of the database views and layers is the same -> same exception for the same layers).

 

Btw: AcMapLayer.ForceRefresh() (without explicitly specified IDs) works fine.

 

Any suggestions?


Markus

8 REPLIES 8
Message 2 of 9
Daniel.Du
in reply to: Anonymous

AcMapLayer.ForceRefresh(pFeatureIds) is an undocumented method, it is not recommanded to use undocumented methods, as it may change and we cannot provide support for that. Sorry about that!



Daniel Du
Developer Technical Services
Autodesk Developer Network

Message 3 of 9
maherich
in reply to: Daniel.Du

Can you suggest any other method how can we refresh these layers? As this is really important functionality.
Martin
Message 4 of 9
Anonymous
in reply to: Anonymous

Hi,

 

Is there any specific reason you want to use this internal / undocumented API AcMapLayer.ForceRefresh(pFeatureIds) ?

 

Thanks,

Partha

Message 5 of 9
Anonymous
in reply to: Anonymous

Hello,

I have to use this method for performance reasons: There are > 100000 rows per layer/feature class, and I want to refresh inserted/updated/deleted rows only (a complete refresh takes too much time).

Markus

Message 6 of 9
Anonymous
in reply to: Anonymous

Hi Markus,

 

I understand your requirement and I can log an API wish list for our Map 3D team to expose this internal API as public. However, using an undocumented / internal API is not encouraged as this would have been designed for a very specific case.

 

Thanks,

Partha

Message 7 of 9
Anonymous
in reply to: Anonymous

Hello,

ok, then please put it on the API wish list.
Will I get automatic feedback about it?

Thanks,
Markus
Message 8 of 9
Anonymous
in reply to: Anonymous

Ok. Once I log an API wish list I will share the wish list ID using the Case you have submitted to Autodesk support team.

 

Thanks,

Partha

Message 9 of 9
Anonymous
in reply to: Anonymous

Hi

 

I have now logged an API wish list for the same and forwarded it to our Map 3D engineering team for their consideration.

 

Thanks,

Partha

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost