En iyi yanıtlayıcılar
datacontext

Soru
-
Yanıtlar
-
Hata mesajı o textBox1'de ineteger'a benzeyen bir şey yok diyor. Linq ile ilgisi yok yani.
How to create a Minimal, Reproducible Example
The way to Go.
World's most advanced open source (object-) relational Database.
Flutter (for mobile, for web & desktop.- Yanıt Olarak İşaretleyen Yasin AKAR 21 Eylül 2019 Cumartesi 21:53
-
"Orada da c.ID int==parse(textbox1.text) " ne demek hiç anlamadım.
Sağlayabilirsin, o zaman kodunda StartsWith kullanmazsın.
Evet normal, çünkü StartsWith kullanılıyor.
How to create a Minimal, Reproducible Example
The way to Go.
World's most advanced open source (object-) relational Database.
Flutter (for mobile, for web & desktop.- Yanıt Olarak İşaretleyen Yasin AKAR 22 Eylül 2019 Pazar 10:27
Tüm Yanıtlar
-
Ortada kod yokken ne demek istedigni anlamak mumkun olmuyor (hata mesajlarını anlayabilmek icin once Ingilizce'ye çevirmek lazim da, her zaman kolay olmuyor. Acaba DataContext {...} gibi mi kullandın).
Normal calisan bir DataContext ornegi:
void Main() { DataContext db = new DataContext(@"server=.\SQLexpress;trusted_connection=yes;database=Northwind"); Table<Customer> Customers = db.GetTable<Customer>(); var header = "CustomerID,CompanyName,ContactName,ContactTitle,Phone,Fax,Address,City,PostalCode,Region,Country\n"; var data = from c in Customers select string.Format("\"{0}\",\"{1}\",\"{2}\",\"{3}\",\"{4}\",\"{5}\",\"{6}\",\"{7}\",\"{8}\",\"{9}\",\"{10}\"", c.CustomerID, c.CompanyName, c.ContactName, c.ContactTitle, c.Phone, c.Fax, c.Address, c.City, c.PostalCode, c.Region, c.Country ); File.WriteAllText(@"d:\Temp\CustomerData.csv", header,Encoding.Default); File.AppendAllLines(@"d:\Temp\CustomerData.csv", data,Encoding.Default); } [Table(Name = "Customers")] public class Customer { [Column] public string CustomerID { get; set; } [Column] public string ContactName { get; set; } [Column] public string CompanyName { get; set; } [Column] public string ContactTitle { get; set; } [Column] public string Phone { get; set; } [Column] public string Fax { get; set; } [Column] public string Address { get; set; } [Column] public string City { get; set; } [Column] public string PostalCode { get; set; } [Column] public string Region { get; set; } [Column] public string Country { get; set; } }
How to create a Minimal, Reproducible Example
The way to Go.
World's most advanced open source (object-) relational Database.
Flutter (for mobile, for web & desktop.- Yanıt Olarak Öneren Mehmet Emin Kaymaz 21 Eylül 2019 Cumartesi 21:55
-
-
-
Oluyor zaten. Kisa bir video cektim senin icin:
Not: Videoyu orada ne kadar tutarım emin degilim. En az bir gun tutarım ama fazlasına soz veremem.
How to create a Minimal, Reproducible Example
The way to Go.
World's most advanced open source (object-) relational Database.
Flutter (for mobile, for web & desktop.- Yanıt Olarak Öneren Mehmet Emin Kaymaz 21 Eylül 2019 Cumartesi 21:55
-
-
-
-
Hata mesajı o textBox1'de ineteger'a benzeyen bir şey yok diyor. Linq ile ilgisi yok yani.
How to create a Minimal, Reproducible Example
The way to Go.
World's most advanced open source (object-) relational Database.
Flutter (for mobile, for web & desktop.- Yanıt Olarak İşaretleyen Yasin AKAR 21 Eylül 2019 Cumartesi 21:53
-
Soruları ayrı ayrı sorar mısın.
How to create a Minimal, Reproducible Example
The way to Go.
World's most advanced open source (object-) relational Database.
Flutter (for mobile, for web & desktop. -
"Orada da c.ID int==parse(textbox1.text) " ne demek hiç anlamadım.
Sağlayabilirsin, o zaman kodunda StartsWith kullanmazsın.
Evet normal, çünkü StartsWith kullanılıyor.
How to create a Minimal, Reproducible Example
The way to Go.
World's most advanced open source (object-) relational Database.
Flutter (for mobile, for web & desktop.- Yanıt Olarak İşaretleyen Yasin AKAR 22 Eylül 2019 Pazar 10:27
-
-
Int nerede? c.ID int ise o tarafta bir şey yapmyacaksin zaten. textBox1.Text'i int'e çevirmek icin ise TryParse kullan:
if (int.TryParse(textBox1.Text, out int Id) { var data = akar.deneme .FirstOrDefault(c => c.ID == id); if(data != null) { // ... } }
How to create a Minimal, Reproducible Example
The way to Go.
World's most advanced open source (object-) relational Database.
Flutter (for mobile, for web & desktop. -