I got this. I don't know why.
Help me please (About Insert Feature to Tabfile)
Hi Sumeth,
I try to addFeature and deleteFeature from a tabfile, but haven’t reproduced your problem.
Could you review some points? Close any other program which maybe open the tab file, check whether the file is set readonly.
And you can try to put a tab file under other folder and edit it for make sure whether that caused by the folder security.
Coud you please check these items and let me know the result.
Regards,
Don
Now,I can insert but I can't update feature.
here code.
public string UpdateFeature(string wkt, string colValues, string fid)
{
featureSource.Open();
featureSource.ReadWriteMode = TabFileReadWriteMode.ReadWrite;
featureSource.BeginTransaction();
try
{
if (featureSource.IsEditable)
{
BaseShape bs = new Feature(wkt).GetShape();
Dictionary<string, string> colVal = JsonConvert.DeserializeObject<Dictionary<string, string>>(colValues);
Feature ft = new Feature(wkt, fid, colVal);
featureSource.UpdateFeature(ft);
}
}
catch (Exception ex)
{
featureSource.RollbackTransaction();
return ex.ToString();
}
featureSource.CommitTransaction();
featureSource.Close();
return "success";
}
It succeed but in tabfile isn't change.
And I can delete feature now.
I uses Map1.Refresh(); when feature deleted but feature is show.(in tabfile was deleted)
How do I ?
Help me again. thank you very much
Hi Sumeth,
If you add or remove column, the UpdateFeature function won’t work.
You can only modify the column value by the API but you cannot add or remove existing column in the shape file.
If you want to implement that, you need to get all information from current layer first, then build a new tab file, delete original one and then rename the new one. I think that would be work.
Regards,
Don
I think I found cause of cannot update shape. Because I forget save new WellKnowText on event VertexAddedEditInteractiveOverlay
Now I can Update Shape.
And below picture
Is this bug? AffectedVertextGFeature is null. I think it should be have shape after edit vector.
And please answer this:
I delete feature.
when feature deleted but feature(shape) is show.(in tabfile was deleted)
It look like save in image map to cache memory.
When I zoom in or zoom out , feature switch to visible and invisible.
(Update feature is same problem old feature can see if not refresh page or pan to other location)
When I pan to another location and pan back feature is invisible (It should be invisible when feature deleted)
I uses Map1.Refresh(); <--- this not effect
and Map1.Overlays["NativeServer"].Refresh(); <-- this error
see this link up-thai.com/upload/picture/7/10805.gif
How do I ?
thanks Don.
Hi Sumeth,
I think we cannot simply refresh it after you change the datasource.
Could you build a simple sample for this? So that our developer can help you implement that quickly.
Regards,
Don
and Map1.Overlays[“NativeServer”].Refresh(); <-- this error
see this link up-thai.com/upload/picture/7/10805.gif
How do I ?
I know cause of this now. I’m forget set layer ID with constructor method.I set name of overlay layer only that I got error
Could you build a simple sample for this?
Where is I can send for you?
Now, this is my sleep time. See you tomorrow.
Regards
Sumeth
Hi Sumeth,
Does that refresh works after you set the layer ID?
If you want to sent us anything, you can sent to support@thinkgeo.com or contact your rep to get the FTP account and password.
Regards,
Don
Now, I sent requirement to you.but I’m not send code to you because silverlight edition can’t not support overview map that is my customer requirement.
I will be learn after make WebEdition demo complete.
Hi Sumeth,
I have recieved your email.
Sorry some of them I cannot give you a exactly reply, I have provide that to our developer, I think they will reply you next Monday because they already not in office now. And we will update the status in your other post.
gis.thinkgeo.com/Support/DiscussionForums/tabid/143/aff/28/aft/9791/afv/topic/Default.aspx
Regards,
Don
Hi Sumeth,
I have recieved your email.
Sorry some of them I cannot give you a exactly reply, I have provide that to our developer, I think they will reply you next Monday because they already not in office now. And we will update the status in your other post.
gis.thinkgeo.com/Support/DiscussionForums/tabid/143/aff/28/aft/9791/afv/topic/Default.aspx
Regards,
Don