New Post has been published on kerkur Yazılımcılık ve internet Hizmetleri
New Post has been published on http://www.kerkurcom.tk/vb-c-da-programin-kapatildigi-yerden-kordinattan-acilmasi/
vb c# 'da Programin KapatıldıÄı yerden kordinattan aƧılması
* vb c# āda Programin KapatıldıÄı yerden kordinattan aƧılması - My Project kısmından Settings kısmına My.Settings ƶÄeleri olarak text1 text2 mylocx mylocy 4 String ekliyoruz. form1 e 2 textbox ekliyoruz Kodu: Public Class Form1 Dim MYX As Integer Dim MYY As Integer āsave settings Private Sub Form1_FormClosing(ByVal sender As Object, ByVal e As FormClosingEventArgs) Handles Me.FormClosing āƧıkıÅta hatırla ekranın yerini MYX = Me.Location.X MYY = Me.Location.Y ā My.Settings.text1 = TextBox1.Text My.Settings.text2 = TextBox2.Text My.Settings.mylocx = MYX My.Settings.mylocy = MYY End Sub āload settings Private Sub Form1_Load(ByVal sender As Object, ByVal e As EventArgs) Handles MyBase.Load TextBox1.Text = My.Settings.text1 TextBox2.Text = My.Settings.text2 ā Alt satır ƶnemli herzaman hatırladıÄından ilk mylocx ve mylocy ā boÅ geleceÄinden program ƧalıÅmaz kesin yazılmalı If My.Settings.mylocx = āā Or My.Settings.mylocx = āā Then My.Settings.mylocx = ā0ā³ My.Settings.mylocx = ā0ā³ Else Me.Location = New Point(My.Settings.mylocx, My.Settings.mylocy) End If End Sub End Class >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> //load settings private void Form1_Load(object sender, EventArgs e) textBox1.Text = Properties.Settings.Default.mylocx; textBox2.Text = Properties.Settings.Default.mylocy; // Alt satır ƶnemli herzaman hatırladıÄından ilk mylocx ve mylocy // boÅ geleceÄinden program ƧalıÅmaz kesin yazılmalı MessageBox.Show(Properties.Settings.Default.text1); if (string.IsNullOrEmpty(Properties.Settings.Default.mylocx) //save settings private void Form1_FormClosing(object sender, FormClosingEventArgs e) int MYX; int MYY; //ƧıkıÅta hatırla ekranın yerini MYX = this.Location.X; MYY = this.Location.Y; // Properties.Settings.Default.text1 = textBox1.Text; Properties.Settings.Default.text2 = textBox2.Text; Properties.Settings.Default.mylocx = Convert.ToString(MYX); Properties.Settings.Default.mylocy = Convert.ToString(MYY); Properties.Settings.Default.Save(); // Important for saving āāāāāāāāāāāāāāāāāā āāāāāāāāāāāāāāāāāā














