merhabalar,
mustafa bey öncelikle ilginiz ve cevabýnýz için teþekkür ederim. fakat malesef
ayný sorun devam ediyor.
--- In MapinfoTurkiye@yahoogroups.com, Mustafa �Z�ETIN
<mustafaozcetin76@...> wrote:
>
> Ben silme isleminde asagidaki gibi bir kod kullandim ve boyle bir problem
yasamadim:
>
>
> public static void deleteFeature(string table, string miKey) {
> Â Â Â try {
> Â Â Â Â Â Â using (MIConnection miconn = new MIConnection()) {
> Â Â Â Â Â Â Â Â Â using (MICommand micomm = miconn.CreateCommand()) {
> Â Â Â Â Â Â Â Â Â Â Â Â micomm.CommandText = "DELETE " + table + " WHERE
MI_KEY = '" + miKey + "'";
> Â Â Â Â Â Â Â Â Â Â Â Â miconn.Open();
> Â Â Â Â Â Â Â Â Â Â Â Â micomm.ExecuteNonQuery();
> Â Â Â Â Â Â Â Â Â }
> Â Â Â Â Â Â }
> Â Â Â Â Â Â activeMapControl.Refresh();
> Â Â Â }
> Â Â Â catch {
>       MessageBox.Show("Hata olu�tu�u için nesne
silinemedi.", "Hata", MessageBoxButtons.OK, MessageBoxIcon.Error);
> Â Â Â }
> }
>
>
> Kolay gelsin.
>
> Mustafa Ozcetin
>
> Arastirmaci / Yazilim Uzmani
> TUBITAK UEKAE / G222 Birimi
> Ataturk Bulvari No:211/20 Kavaklidere / ANKARA
>
>
>
> --- On Thu, 7/9/09, mutlu1711 <mutlu1711@...> wrote:
>
> From: mutlu1711 <mutlu1711@...>
> Subject: [MapinfoTurkiye] Mapxtreme Desktop Uygulamas�±nda Nesne
Silme
> To: MapinfoTurkiye@yahoogroups.com
> Date: Thursday, July 9, 2009, 9:54 AM
>
> merhaba,
>
> MapXtreme ile Visual Studio 2008 ortam�±nda geli�tirmekte
oldu�um bir desktop uygulamas�±nda;
>
> Select Tool ile se�§ti�im nesneyi silmek i�§in
kulland�±��±m buttona t�±klay�±nca
se�§ti�im nesne o katmanda olu�turulan ilk nesne
de�il ise silme i�lemi ba�ar�± ile eksiksiz
ger�§ekle�iyor. se�§ti�im nesnenin
katman�±nda o anda ka�§ tane nesne olursa olsun,
se�§ilen nesne o katman i�§in �¼retilen ilk nesne ise
silme i�lemini sadece feature i�§in yap�±yor.
�¶znitelik bilgileri silinemiyor. silme i�lemi i�§in
yazd�±��±m sat�±rlar
a�a��±dad�±r. katman i�§in
olu�turulan ilk nesnenin �¶znitelik bilgisinin neden
silinemedi�i konusunda yard�±mc�± olursan�±z
sevinirim.
>
> kolay gelsin...
>
> //p_mainlayer=se�§ili nesnenin hangi katmana ait oldu�u
bilgisi
> int rc=mapTableRowCount(p_mainLayer.ToString()); // se�§ili
nesnenin katman�±nda mevcut ka�§ tane row oldu�u
tespit ediliyor.
> MIConnection conn = new MIConnection(); conn.Open();
> MICommand comm1 = new MICommand(); comm1.Connection = conn;
> if (rc>1)
> {
> if (p_keyColumn.ToString() == "id") //baz�± tablolarda ilk kolonun
ad�± id olmad�±��± i�§in bunun
kontrol�¼ yap�±l�±yor.
> {
> comm1.CommandText = "Delete from " + p_mainLayer.ToString() +
> Â Â " where " + p_keyColumn.ToString() + "=" + p_keyColumnValue.ToString();
> }
> else
> {
> comm1.CommandText = "Delete from " + p_mainLayer.ToString() +
> Â Â " where " + p_keyColumn.ToString() + "='" + p_keyColumnValue.ToString()
+ "'";
> }
> }
> else if (rc == 1)
> {
> comm1.CommandText = "Delete From " + p_mainLayer.ToString();
> }
> MIDataReader midr=comm1.ExecuteReader();
> MapInfo.Data.Table table =
MapInfo.Engine.Session.Current.Catalog.GetTable(p_mainLayer.ToString());
> table.Pack(MapInfo.Data.PackType.All);
> comm1.Dispose();
> conn.Close();
> conn.Dispose();
>
>
>
>
> ------------------------------------
>
> ---------------------------------------------
> MapInfoTurkiye
>
> Listeden çikmak için / To unsubscribe:
> MapinfoTurkiye-unsubscribe@yahoogroups.com
> �ye olmak için / To subscribe:
> MapinfoTurkiye-subscribe@yahoogroups.com
> Web Sayfasi: http://groups.yahoo.com/group/MapinfoTurkiye
> Dosyalar: http://www.yahoogroups.com/group/MapinfoTurkiye/files/
>
> NOT:Gruba gönderilen yazilardan sadece gönderen kisi sorumludur.
> Yahoo! Groups Links
>
>
>
>
>
>
>
>
> [Non-text portions of this message have been removed]
>