Button Text Not Changed Problem

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Arif Çimen

    Button Text Not Changed Problem

    Hi to everybody,

    I have chnged a button text in design mode. But After compiling and
    executing the program
    the text of the button do not change to new value.

    Any Ideas?

    Thaks for helps.

    Arif Çimen


  • Josema

    #2
    RE: Button Text Not Changed Problem

    Hi Arif, Could you post some code?...

    Josema.

    "Arif Çimen" wrote:
    [color=blue]
    > Hi to everybody,
    >
    > I have chnged a button text in design mode. But After compiling and
    > executing the program
    > the text of the button do not change to new value.
    >
    > Any Ideas?
    >
    > Thaks for helps.
    >
    > Arif Çimen
    >
    >
    >[/color]

    Comment

    • Arif Çimen

      #3
      Re: Button Text Not Changed Problem

      Here My Codes:







      using System;

      using System.Drawing;

      using System.Collecti ons;

      using System.Componen tModel;

      using System.Windows. Forms;

      using System.Data;

      namespace Cosmo

      {

      /// <summary>

      /// Summary description for Form1.

      /// </summary>

      public class Form1 : System.Windows. Forms.Form

      {

      public TicketPartSelec tionForm tpsF;

      public TicketsDatabase Form tdF;

      public TicketPrintingF orm tpF;

      public AboutBoxForm abF;

      public CustomerInfoSel ectionForm cisF;

      public CustomerTravelP rocesses ctP;

      public Biletler bltler;

      private System.Windows. Forms.Label label1;

      private System.Windows. Forms.Button button1;

      private System.Windows. Forms.Button button4;

      private System.Windows. Forms.Button button5;

      private System.Windows. Forms.Button button6;

      private System.Windows. Forms.Label label2;

      private System.Windows. Forms.Button button7;

      private System.Windows. Forms.Button button2;

      private System.Windows. Forms.Button button3;

      /// <summary>

      /// Required designer variable.

      /// </summary>

      private System.Componen tModel.Containe r components = null;

      public Form1()

      {

      //

      // Required for Windows Form Designer support

      //

      InitializeCompo nent();

      //

      // TODO: Add any constructor code after InitializeCompo nent call

      //

      button2.Text="R ezervasyon";

      button5.Visible =false;

      button4.Visible =false;

      }

      /// <summary>

      /// Clean up any resources being used.

      /// </summary>

      protected override void Dispose( bool disposing )

      {

      if( disposing )

      {

      if (components != null)

      {

      components.Disp ose();

      }

      }

      base.Dispose( disposing );

      }

      #region Windows Form Designer generated code

      /// <summary>

      /// Required method for Designer support - do not modify

      /// the contents of this method with the code editor.

      /// </summary>

      private void InitializeCompo nent()

      {

      System.Resource s.ResourceManag er resources = new
      System.Resource s.ResourceManag er(typeof(Form1 ));

      this.label1 = new System.Windows. Forms.Label();

      this.button1 = new System.Windows. Forms.Button();

      this.button4 = new System.Windows. Forms.Button();

      this.button5 = new System.Windows. Forms.Button();

      this.button6 = new System.Windows. Forms.Button();

      this.label2 = new System.Windows. Forms.Label();

      this.button7 = new System.Windows. Forms.Button();

      this.button2 = new System.Windows. Forms.Button();

      this.button3 = new System.Windows. Forms.Button();

      this.SuspendLay out();

      //

      // label1

      //

      this.label1.Acc essibleDescript ion =
      resources.GetSt ring("label1.Ac cessibleDescrip tion");

      this.label1.Acc essibleName = resources.GetSt ring("label1.Ac cessibleName");

      this.label1.Anc hor =
      ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("la bel1.Anchor"))) ;

      this.label1.Aut oSize = ((bool)(resourc es.GetObject("l abel1.AutoSize" )));

      this.label1.Bac kColor = System.Drawing. Color.RosyBrown ;

      this.label1.Doc k =
      ((System.Window s.Forms.DockSty le)(resources.G etObject("label 1.Dock")));

      this.label1.Ena bled = ((bool)(resourc es.GetObject("l abel1.Enabled") ));

      this.label1.Fon t =
      ((System.Drawin g.Font)(resourc es.GetObject("l abel1.Font")));

      this.label1.For eColor = System.Drawing. Color.Yellow;

      this.label1.Ima ge =
      ((System.Drawin g.Image)(resour ces.GetObject(" label1.Image")) );

      this.label1.Ima geAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("labe l1.ImageAlign") ));

      this.label1.Ima geIndex = ((int)(resource s.GetObject("la bel1.ImageIndex ")));

      this.label1.Ime Mode =
      ((System.Window s.Forms.ImeMode )(resources.Get Object("label1. ImeMode")));

      this.label1.Loc ation =
      ((System.Drawin g.Point)(resour ces.GetObject(" label1.Location ")));

      this.label1.Nam e = "label1";

      this.label1.Rig htToLeft =
      ((System.Window s.Forms.RightTo Left)(resources .GetObject("lab el1.RightToLeft ")));

      this.label1.Siz e =
      ((System.Drawin g.Size)(resourc es.GetObject("l abel1.Size")));

      this.label1.Tab Index = ((int)(resource s.GetObject("la bel1.TabIndex") ));

      this.label1.Tex t = resources.GetSt ring("label1.Te xt");

      this.label1.Tex tAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("labe l1.TextAlign")) );

      this.label1.Vis ible = ((bool)(resourc es.GetObject("l abel1.Visible") ));

      //

      // button1

      //

      this.button1.Ac cessibleDescrip tion =
      resources.GetSt ring("button1.A ccessibleDescri ption");

      this.button1.Ac cessibleName = resources.GetSt ring("button1.A ccessibleName") ;

      this.button1.An chor =
      ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("bu tton1.Anchor")) );

      this.button1.Ba ckgroundImage =
      ((System.Drawin g.Image)(resour ces.GetObject(" button1.Backgro undImage")));

      this.button1.Do ck =
      ((System.Window s.Forms.DockSty le)(resources.G etObject("butto n1.Dock")));

      this.button1.En abled = ((bool)(resourc es.GetObject("b utton1.Enabled" )));

      this.button1.Fl atStyle =
      ((System.Window s.Forms.FlatSty le)(resources.G etObject("butto n1.FlatStyle")) );

      this.button1.Fo nt =
      ((System.Drawin g.Font)(resourc es.GetObject("b utton1.Font"))) ;

      this.button1.Im age =
      ((System.Drawin g.Image)(resour ces.GetObject(" button1.Image") ));

      this.button1.Im ageAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on1.ImageAlign" )));

      this.button1.Im ageIndex =
      ((int)(resource s.GetObject("bu tton1.ImageInde x")));

      this.button1.Im eMode =
      ((System.Window s.Forms.ImeMode )(resources.Get Object("button1 .ImeMode")));

      this.button1.Lo cation =
      ((System.Drawin g.Point)(resour ces.GetObject(" button1.Locatio n")));

      this.button1.Na me = "button1";

      this.button1.Ri ghtToLeft =
      ((System.Window s.Forms.RightTo Left)(resources .GetObject("but ton1.RightToLef t")));

      this.button1.Si ze =
      ((System.Drawin g.Size)(resourc es.GetObject("b utton1.Size"))) ;

      this.button1.Ta bIndex = ((int)(resource s.GetObject("bu tton1.TabIndex" )));

      this.button1.Te xt = resources.GetSt ring("button1.T ext");

      this.button1.Te xtAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on1.TextAlign") ));

      this.button1.Vi sible = ((bool)(resourc es.GetObject("b utton1.Visible" )));

      this.button1.Cl ick += new System.EventHan dler(this.butto n1_Click);

      //

      // button4

      //

      this.button4.Ac cessibleDescrip tion =
      resources.GetSt ring("button4.A ccessibleDescri ption");

      this.button4.Ac cessibleName = resources.GetSt ring("button4.A ccessibleName") ;

      this.button4.An chor =
      ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("bu tton4.Anchor")) );

      this.button4.Ba ckgroundImage =
      ((System.Drawin g.Image)(resour ces.GetObject(" button4.Backgro undImage")));

      this.button4.Do ck =
      ((System.Window s.Forms.DockSty le)(resources.G etObject("butto n4.Dock")));

      this.button4.En abled = ((bool)(resourc es.GetObject("b utton4.Enabled" )));

      this.button4.Fl atStyle =
      ((System.Window s.Forms.FlatSty le)(resources.G etObject("butto n4.FlatStyle")) );

      this.button4.Fo nt =
      ((System.Drawin g.Font)(resourc es.GetObject("b utton4.Font"))) ;

      this.button4.Im age =
      ((System.Drawin g.Image)(resour ces.GetObject(" button4.Image") ));

      this.button4.Im ageAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on4.ImageAlign" )));

      this.button4.Im ageIndex =
      ((int)(resource s.GetObject("bu tton4.ImageInde x")));

      this.button4.Im eMode =
      ((System.Window s.Forms.ImeMode )(resources.Get Object("button4 .ImeMode")));

      this.button4.Lo cation =
      ((System.Drawin g.Point)(resour ces.GetObject(" button4.Locatio n")));

      this.button4.Na me = "button4";

      this.button4.Ri ghtToLeft =
      ((System.Window s.Forms.RightTo Left)(resources .GetObject("but ton4.RightToLef t")));

      this.button4.Si ze =
      ((System.Drawin g.Size)(resourc es.GetObject("b utton4.Size"))) ;

      this.button4.Ta bIndex = ((int)(resource s.GetObject("bu tton4.TabIndex" )));

      this.button4.Te xt = resources.GetSt ring("button4.T ext");

      this.button4.Te xtAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on4.TextAlign") ));

      this.button4.Vi sible = ((bool)(resourc es.GetObject("b utton4.Visible" )));

      this.button4.Cl ick += new System.EventHan dler(this.butto n4_Click);

      //

      // button5

      //

      this.button5.Ac cessibleDescrip tion =
      resources.GetSt ring("button5.A ccessibleDescri ption");

      this.button5.Ac cessibleName = resources.GetSt ring("button5.A ccessibleName") ;

      this.button5.An chor =
      ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("bu tton5.Anchor")) );

      this.button5.Ba ckgroundImage =
      ((System.Drawin g.Image)(resour ces.GetObject(" button5.Backgro undImage")));

      this.button5.Do ck =
      ((System.Window s.Forms.DockSty le)(resources.G etObject("butto n5.Dock")));

      this.button5.En abled = ((bool)(resourc es.GetObject("b utton5.Enabled" )));

      this.button5.Fl atStyle =
      ((System.Window s.Forms.FlatSty le)(resources.G etObject("butto n5.FlatStyle")) );

      this.button5.Fo nt =
      ((System.Drawin g.Font)(resourc es.GetObject("b utton5.Font"))) ;

      this.button5.Im age =
      ((System.Drawin g.Image)(resour ces.GetObject(" button5.Image") ));

      this.button5.Im ageAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on5.ImageAlign" )));

      this.button5.Im ageIndex =
      ((int)(resource s.GetObject("bu tton5.ImageInde x")));

      this.button5.Im eMode =
      ((System.Window s.Forms.ImeMode )(resources.Get Object("button5 .ImeMode")));

      this.button5.Lo cation =
      ((System.Drawin g.Point)(resour ces.GetObject(" button5.Locatio n")));

      this.button5.Na me = "button5";

      this.button5.Ri ghtToLeft =
      ((System.Window s.Forms.RightTo Left)(resources .GetObject("but ton5.RightToLef t")));

      this.button5.Si ze =
      ((System.Drawin g.Size)(resourc es.GetObject("b utton5.Size"))) ;

      this.button5.Ta bIndex = ((int)(resource s.GetObject("bu tton5.TabIndex" )));

      this.button5.Te xt = resources.GetSt ring("button5.T ext");

      this.button5.Te xtAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on5.TextAlign") ));

      this.button5.Vi sible = ((bool)(resourc es.GetObject("b utton5.Visible" )));

      //

      // button6

      //

      this.button6.Ac cessibleDescrip tion =
      resources.GetSt ring("button6.A ccessibleDescri ption");

      this.button6.Ac cessibleName = resources.GetSt ring("button6.A ccessibleName") ;

      this.button6.An chor =
      ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("bu tton6.Anchor")) );

      this.button6.Ba ckgroundImage =
      ((System.Drawin g.Image)(resour ces.GetObject(" button6.Backgro undImage")));

      this.button6.Do ck =
      ((System.Window s.Forms.DockSty le)(resources.G etObject("butto n6.Dock")));

      this.button6.En abled = ((bool)(resourc es.GetObject("b utton6.Enabled" )));

      this.button6.Fl atStyle =
      ((System.Window s.Forms.FlatSty le)(resources.G etObject("butto n6.FlatStyle")) );

      this.button6.Fo nt =
      ((System.Drawin g.Font)(resourc es.GetObject("b utton6.Font"))) ;

      this.button6.Im age =
      ((System.Drawin g.Image)(resour ces.GetObject(" button6.Image") ));

      this.button6.Im ageAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on6.ImageAlign" )));

      this.button6.Im ageIndex =
      ((int)(resource s.GetObject("bu tton6.ImageInde x")));

      this.button6.Im eMode =
      ((System.Window s.Forms.ImeMode )(resources.Get Object("button6 .ImeMode")));

      this.button6.Lo cation =
      ((System.Drawin g.Point)(resour ces.GetObject(" button6.Locatio n")));

      this.button6.Na me = "button6";

      this.button6.Ri ghtToLeft =
      ((System.Window s.Forms.RightTo Left)(resources .GetObject("but ton6.RightToLef t")));

      this.button6.Si ze =
      ((System.Drawin g.Size)(resourc es.GetObject("b utton6.Size"))) ;

      this.button6.Ta bIndex = ((int)(resource s.GetObject("bu tton6.TabIndex" )));

      this.button6.Te xt = resources.GetSt ring("button6.T ext");

      this.button6.Te xtAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on6.TextAlign") ));

      this.button6.Vi sible = ((bool)(resourc es.GetObject("b utton6.Visible" )));

      //

      // label2

      //

      this.label2.Acc essibleDescript ion =
      resources.GetSt ring("label2.Ac cessibleDescrip tion");

      this.label2.Acc essibleName = resources.GetSt ring("label2.Ac cessibleName");

      this.label2.Anc hor =
      ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("la bel2.Anchor"))) ;

      this.label2.Aut oSize = ((bool)(resourc es.GetObject("l abel2.AutoSize" )));

      this.label2.Bac kColor = System.Drawing. Color.RosyBrown ;

      this.label2.Doc k =
      ((System.Window s.Forms.DockSty le)(resources.G etObject("label 2.Dock")));

      this.label2.Ena bled = ((bool)(resourc es.GetObject("l abel2.Enabled") ));

      this.label2.Fon t =
      ((System.Drawin g.Font)(resourc es.GetObject("l abel2.Font")));

      this.label2.For eColor = System.Drawing. Color.Yellow;

      this.label2.Ima ge =
      ((System.Drawin g.Image)(resour ces.GetObject(" label2.Image")) );

      this.label2.Ima geAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("labe l2.ImageAlign") ));

      this.label2.Ima geIndex = ((int)(resource s.GetObject("la bel2.ImageIndex ")));

      this.label2.Ime Mode =
      ((System.Window s.Forms.ImeMode )(resources.Get Object("label2. ImeMode")));

      this.label2.Loc ation =
      ((System.Drawin g.Point)(resour ces.GetObject(" label2.Location ")));

      this.label2.Nam e = "label2";

      this.label2.Rig htToLeft =
      ((System.Window s.Forms.RightTo Left)(resources .GetObject("lab el2.RightToLeft ")));

      this.label2.Siz e =
      ((System.Drawin g.Size)(resourc es.GetObject("l abel2.Size")));

      this.label2.Tab Index = ((int)(resource s.GetObject("la bel2.TabIndex") ));

      this.label2.Tex t = resources.GetSt ring("label2.Te xt");

      this.label2.Tex tAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("labe l2.TextAlign")) );

      this.label2.Vis ible = ((bool)(resourc es.GetObject("l abel2.Visible") ));

      //

      // button7

      //

      this.button7.Ac cessibleDescrip tion =
      resources.GetSt ring("button7.A ccessibleDescri ption");

      this.button7.Ac cessibleName = resources.GetSt ring("button7.A ccessibleName") ;

      this.button7.An chor =
      ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("bu tton7.Anchor")) );

      this.button7.Ba ckgroundImage =
      ((System.Drawin g.Image)(resour ces.GetObject(" button7.Backgro undImage")));

      this.button7.Do ck =
      ((System.Window s.Forms.DockSty le)(resources.G etObject("butto n7.Dock")));

      this.button7.En abled = ((bool)(resourc es.GetObject("b utton7.Enabled" )));

      this.button7.Fl atStyle =
      ((System.Window s.Forms.FlatSty le)(resources.G etObject("butto n7.FlatStyle")) );

      this.button7.Fo nt =
      ((System.Drawin g.Font)(resourc es.GetObject("b utton7.Font"))) ;

      this.button7.Im age =
      ((System.Drawin g.Image)(resour ces.GetObject(" button7.Image") ));

      this.button7.Im ageAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on7.ImageAlign" )));

      this.button7.Im ageIndex =
      ((int)(resource s.GetObject("bu tton7.ImageInde x")));

      this.button7.Im eMode =
      ((System.Window s.Forms.ImeMode )(resources.Get Object("button7 .ImeMode")));

      this.button7.Lo cation =
      ((System.Drawin g.Point)(resour ces.GetObject(" button7.Locatio n")));

      this.button7.Na me = "button7";

      this.button7.Ri ghtToLeft =
      ((System.Window s.Forms.RightTo Left)(resources .GetObject("but ton7.RightToLef t")));

      this.button7.Si ze =
      ((System.Drawin g.Size)(resourc es.GetObject("b utton7.Size"))) ;

      this.button7.Ta bIndex = ((int)(resource s.GetObject("bu tton7.TabIndex" )));

      this.button7.Te xt = resources.GetSt ring("button7.T ext");

      this.button7.Te xtAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on7.TextAlign") ));

      this.button7.Vi sible = ((bool)(resourc es.GetObject("b utton7.Visible" )));

      //

      // button2

      //

      this.button2.Ac cessibleDescrip tion =
      resources.GetSt ring("button2.A ccessibleDescri ption");

      this.button2.Ac cessibleName = resources.GetSt ring("button2.A ccessibleName") ;

      this.button2.An chor =
      ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("bu tton2.Anchor")) );

      this.button2.Ba ckgroundImage =
      ((System.Drawin g.Image)(resour ces.GetObject(" button2.Backgro undImage")));

      this.button2.Do ck =
      ((System.Window s.Forms.DockSty le)(resources.G etObject("butto n2.Dock")));

      this.button2.En abled = ((bool)(resourc es.GetObject("b utton2.Enabled" )));

      this.button2.Fl atStyle =
      ((System.Window s.Forms.FlatSty le)(resources.G etObject("butto n2.FlatStyle")) );

      this.button2.Fo nt =
      ((System.Drawin g.Font)(resourc es.GetObject("b utton2.Font"))) ;

      this.button2.Im age =
      ((System.Drawin g.Image)(resour ces.GetObject(" button2.Image") ));

      this.button2.Im ageAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on2.ImageAlign" )));

      this.button2.Im ageIndex =
      ((int)(resource s.GetObject("bu tton2.ImageInde x")));

      this.button2.Im eMode =
      ((System.Window s.Forms.ImeMode )(resources.Get Object("button2 .ImeMode")));

      this.button2.Lo cation =
      ((System.Drawin g.Point)(resour ces.GetObject(" button2.Locatio n")));

      this.button2.Na me = "button2";

      this.button2.Ri ghtToLeft =
      ((System.Window s.Forms.RightTo Left)(resources .GetObject("but ton2.RightToLef t")));

      this.button2.Si ze =
      ((System.Drawin g.Size)(resourc es.GetObject("b utton2.Size"))) ;

      this.button2.Ta bIndex = ((int)(resource s.GetObject("bu tton2.TabIndex" )));

      this.button2.Te xt = resources.GetSt ring("button2.T ext");

      this.button2.Te xtAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on2.TextAlign") ));

      this.button2.Vi sible = ((bool)(resourc es.GetObject("b utton2.Visible" )));

      this.button2.Cl ick += new System.EventHan dler(this.butto n2_Click_1);

      //

      // button3

      //

      this.button3.Ac cessibleDescrip tion =
      resources.GetSt ring("button3.A ccessibleDescri ption");

      this.button3.Ac cessibleName = resources.GetSt ring("button3.A ccessibleName") ;

      this.button3.An chor =
      ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("bu tton3.Anchor")) );

      this.button3.Ba ckgroundImage =
      ((System.Drawin g.Image)(resour ces.GetObject(" button3.Backgro undImage")));

      this.button3.Do ck =
      ((System.Window s.Forms.DockSty le)(resources.G etObject("butto n3.Dock")));

      this.button3.En abled = ((bool)(resourc es.GetObject("b utton3.Enabled" )));

      this.button3.Fl atStyle =
      ((System.Window s.Forms.FlatSty le)(resources.G etObject("butto n3.FlatStyle")) );

      this.button3.Fo nt =
      ((System.Drawin g.Font)(resourc es.GetObject("b utton3.Font"))) ;

      this.button3.Im age =
      ((System.Drawin g.Image)(resour ces.GetObject(" button3.Image") ));

      this.button3.Im ageAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on3.ImageAlign" )));

      this.button3.Im ageIndex =
      ((int)(resource s.GetObject("bu tton3.ImageInde x")));

      this.button3.Im eMode =
      ((System.Window s.Forms.ImeMode )(resources.Get Object("button3 .ImeMode")));

      this.button3.Lo cation =
      ((System.Drawin g.Point)(resour ces.GetObject(" button3.Locatio n")));

      this.button3.Na me = "button3";

      this.button3.Ri ghtToLeft =
      ((System.Window s.Forms.RightTo Left)(resources .GetObject("but ton3.RightToLef t")));

      this.button3.Si ze =
      ((System.Drawin g.Size)(resourc es.GetObject("b utton3.Size"))) ;

      this.button3.Ta bIndex = ((int)(resource s.GetObject("bu tton3.TabIndex" )));

      this.button3.Te xt = resources.GetSt ring("button3.T ext");

      this.button3.Te xtAlign =
      ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on3.TextAlign") ));

      this.button3.Vi sible = ((bool)(resourc es.GetObject("b utton3.Visible" )));

      //

      // Form1

      //

      this.Accessible Description =
      resources.GetSt ring("$this.Acc essibleDescript ion");

      this.Accessible Name = resources.GetSt ring("$this.Acc essibleName");

      this.AutoScaleB aseSize =
      ((System.Drawin g.Size)(resourc es.GetObject("$ this.AutoScaleB aseSize")));

      this.AutoScroll = ((bool)(resourc es.GetObject("$ this.AutoScroll ")));

      this.AutoScroll Margin =
      ((System.Drawin g.Size)(resourc es.GetObject("$ this.AutoScroll Margin")));

      this.AutoScroll MinSize =
      ((System.Drawin g.Size)(resourc es.GetObject("$ this.AutoScroll MinSize")));

      this.Background Image =
      ((System.Drawin g.Image)(resour ces.GetObject(" $this.Backgroun dImage")));

      this.ClientSize =
      ((System.Drawin g.Size)(resourc es.GetObject("$ this.ClientSize ")));

      this.Controls.A dd(this.button3 );

      this.Controls.A dd(this.button2 );

      this.Controls.A dd(this.button6 );

      this.Controls.A dd(this.button5 );

      this.Controls.A dd(this.button4 );

      this.Controls.A dd(this.button1 );

      this.Controls.A dd(this.label1) ;

      this.Controls.A dd(this.label2) ;

      this.Controls.A dd(this.button7 );

      this.Enabled = ((bool)(resourc es.GetObject("$ this.Enabled")) );

      this.Font = ((System.Drawin g.Font)(resourc es.GetObject("$ this.Font")));

      this.Icon = ((System.Drawin g.Icon)(resourc es.GetObject("$ this.Icon")));

      this.ImeMode =
      ((System.Window s.Forms.ImeMode )(resources.Get Object("$this.I meMode")));

      this.Location =
      ((System.Drawin g.Point)(resour ces.GetObject(" $this.Location" )));

      this.MaximumSiz e =
      ((System.Drawin g.Size)(resourc es.GetObject("$ this.MaximumSiz e")));

      this.MinimumSiz e =
      ((System.Drawin g.Size)(resourc es.GetObject("$ this.MinimumSiz e")));

      this.Name = "Form1";

      this.RightToLef t =
      ((System.Window s.Forms.RightTo Left)(resources .GetObject("$th is.RightToLeft" )));

      this.StartPosit ion =
      ((System.Window s.Forms.FormSta rtPosition)(res ources.GetObjec t("$this.StartP osition")));

      this.Text = resources.GetSt ring("$this.Tex t");

      this.ResumeLayo ut(false);

      }

      #endregion

      /// <summary>

      /// The main entry point for the application.

      /// </summary>

      [STAThread]

      static void Main()

      {

      Form1 form1=new Form1();

      //Application.Run (new Form1());

      Application.Run (form1);

      }

      private void menuItem2_Click (object sender, System.EventArg s e)

      {


      }

      private void button1_Click(o bject sender, System.EventArg s e)

      {

      tpsF=new TicketPartSelec tionForm();

      tpsF.Show();

      //bltler=new Biletler();

      //bltler.Show();

      }

      private void button4_Click(o bject sender, System.EventArg s e)

      {

      //ctP=new CustomerTravelP rocesses();

      //ctP.Show();

      }

      private void button2_Click(o bject sender, System.EventArg s e)

      {

      //cisF=new CustomerInfoSel ectionForm();

      //cisF.Show();

      }

      private void button8_Click(o bject sender, System.EventArg s e)

      {


      }

      public void OpenTicketDesig n()

      {

      tpF=new TicketPrintingF orm();

      tdF=new TicketsDatabase Form();

      tpF.label1.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["Airline
      Data"].ColumnName;

      tpF.label2.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["AllowA"].ColumnName;

      tpF.label3.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["AllowB"].ColumnName;

      tpF.label4.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["Baggage
      Chk/UnChkA1"].ColumnName;

      tpF.label5.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["Baggage
      Chk/UnChkA2"].ColumnName;

      tpF.label6.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["Baggage
      Chk/UnChkB1"].ColumnName;

      tpF.label7.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["Baggage
      Chk/UnChkB2"].ColumnName;

      tpF.label8.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["CarierA"].ColumnName;

      tpF.label9.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["Carrier1"].ColumnName;

      tpF.label10.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Carrier2"].ColumnName;

      tpF.label11.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Carrier3"].ColumnName;

      tpF.label12.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Carrier4"].ColumnName;

      tpF.label13.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["CarrierB"].ColumnName;

      tpF.label14.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["ClassA"].ColumnName;

      tpF.label15.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["ClassB"].ColumnName;

      tpF.label16.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Date
      And Place Of Issue"].ColumnName;

      tpF.label17.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["DateA"].ColumnName;

      tpF.label18.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["DateB"].ColumnName;

      tpF.label19.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Destinatio n"].ColumnName;

      tpF.label20.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Fare"].ColumnName;

      tpF.label21.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Fare
      BasisA"].ColumnName;

      tpF.label22.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Fare
      BasisB"].ColumnName;

      tpF.label23.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Form Of
      Payment"].ColumnName;

      tpF.label24.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["From"].ColumnName;

      tpF.label25.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Location1"].ColumnName;

      tpF.label26.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Location2"].ColumnName;

      tpF.label27.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Location3"].ColumnName;

      tpF.label28.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Location4"].ColumnName;

      tpF.label29.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Mr/Mrs"].ColumnName;

      tpF.label30.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Name"].ColumnName;

      tpF.label31.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Not
      Valid AfterA"].ColumnName;

      tpF.label32.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Not
      Valid AfterB"].ColumnName;

      tpF.label33.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Not
      Valid BeforeA"].ColumnName;

      tpF.label34.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Not
      Valid BeforeB"].ColumnName;

      tpF.label35.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Passport
      Number"].ColumnName;

      tpF.label36.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["StatusA"].ColumnName;

      tpF.label37.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["StatusB"].ColumnName;

      tpF.label38.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Surname"].ColumnName;

      tpF.label39.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["TimeA"].ColumnName;

      tpF.label40.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["TimeB"].ColumnName;

      tpF.label41.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["To"].ColumnName;

      tpF.label42.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["To1"].ColumnName;

      tpF.label43.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Total"].ColumnName;





      //tpF.label44.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns[43].ColumnName;

      //tpF.label45.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns[44].ColumnName;

      //tpF.label46.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns[45].ColumnName;

      //tpF.label1.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns[46].ColumnName;



      tpF.Show();

      }

      private void button9_Click(o bject sender, System.EventArg s e)

      {

      //OpenTicketDesig n();

      }

      private void button10_Click( object sender, System.EventArg s e)

      {


      }

      private void button2_Click_1 (object sender, System.EventArg s e)

      {

      RezervationForm rF=new RezervationForm ();

      rF.Show();

      }

      private void button3_Click(o bject sender, System.EventArg s e)

      {


      }

      }

      }


      Comment

      • Josema

        #4
        Re: Button Text Not Changed Problem

        Try dont change in design mode the text property, and put in the codebehind
        when you Initialize the component:

        this.Button.Tex t="Hello World";



        "Arif Çimen" wrote:
        [color=blue]
        > Here My Codes:
        >
        >
        >
        >
        >
        >
        >
        > using System;
        >
        > using System.Drawing;
        >
        > using System.Collecti ons;
        >
        > using System.Componen tModel;
        >
        > using System.Windows. Forms;
        >
        > using System.Data;
        >
        > namespace Cosmo
        >
        > {
        >
        > /// <summary>
        >
        > /// Summary description for Form1.
        >
        > /// </summary>
        >
        > public class Form1 : System.Windows. Forms.Form
        >
        > {
        >
        > public TicketPartSelec tionForm tpsF;
        >
        > public TicketsDatabase Form tdF;
        >
        > public TicketPrintingF orm tpF;
        >
        > public AboutBoxForm abF;
        >
        > public CustomerInfoSel ectionForm cisF;
        >
        > public CustomerTravelP rocesses ctP;
        >
        > public Biletler bltler;
        >
        > private System.Windows. Forms.Label label1;
        >
        > private System.Windows. Forms.Button button1;
        >
        > private System.Windows. Forms.Button button4;
        >
        > private System.Windows. Forms.Button button5;
        >
        > private System.Windows. Forms.Button button6;
        >
        > private System.Windows. Forms.Label label2;
        >
        > private System.Windows. Forms.Button button7;
        >
        > private System.Windows. Forms.Button button2;
        >
        > private System.Windows. Forms.Button button3;
        >
        > /// <summary>
        >
        > /// Required designer variable.
        >
        > /// </summary>
        >
        > private System.Componen tModel.Containe r components = null;
        >
        > public Form1()
        >
        > {
        >
        > //
        >
        > // Required for Windows Form Designer support
        >
        > //
        >
        > InitializeCompo nent();
        >
        > //
        >
        > // TODO: Add any constructor code after InitializeCompo nent call
        >
        > //
        >
        > button2.Text="R ezervasyon";
        >
        > button5.Visible =false;
        >
        > button4.Visible =false;
        >
        > }
        >
        > /// <summary>
        >
        > /// Clean up any resources being used.
        >
        > /// </summary>
        >
        > protected override void Dispose( bool disposing )
        >
        > {
        >
        > if( disposing )
        >
        > {
        >
        > if (components != null)
        >
        > {
        >
        > components.Disp ose();
        >
        > }
        >
        > }
        >
        > base.Dispose( disposing );
        >
        > }
        >
        > #region Windows Form Designer generated code
        >
        > /// <summary>
        >
        > /// Required method for Designer support - do not modify
        >
        > /// the contents of this method with the code editor.
        >
        > /// </summary>
        >
        > private void InitializeCompo nent()
        >
        > {
        >
        > System.Resource s.ResourceManag er resources = new
        > System.Resource s.ResourceManag er(typeof(Form1 ));
        >
        > this.label1 = new System.Windows. Forms.Label();
        >
        > this.button1 = new System.Windows. Forms.Button();
        >
        > this.button4 = new System.Windows. Forms.Button();
        >
        > this.button5 = new System.Windows. Forms.Button();
        >
        > this.button6 = new System.Windows. Forms.Button();
        >
        > this.label2 = new System.Windows. Forms.Label();
        >
        > this.button7 = new System.Windows. Forms.Button();
        >
        > this.button2 = new System.Windows. Forms.Button();
        >
        > this.button3 = new System.Windows. Forms.Button();
        >
        > this.SuspendLay out();
        >
        > //
        >
        > // label1
        >
        > //
        >
        > this.label1.Acc essibleDescript ion =
        > resources.GetSt ring("label1.Ac cessibleDescrip tion");
        >
        > this.label1.Acc essibleName = resources.GetSt ring("label1.Ac cessibleName");
        >
        > this.label1.Anc hor =
        > ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("la bel1.Anchor"))) ;
        >
        > this.label1.Aut oSize = ((bool)(resourc es.GetObject("l abel1.AutoSize" )));
        >
        > this.label1.Bac kColor = System.Drawing. Color.RosyBrown ;
        >
        > this.label1.Doc k =
        > ((System.Window s.Forms.DockSty le)(resources.G etObject("label 1.Dock")));
        >
        > this.label1.Ena bled = ((bool)(resourc es.GetObject("l abel1.Enabled") ));
        >
        > this.label1.Fon t =
        > ((System.Drawin g.Font)(resourc es.GetObject("l abel1.Font")));
        >
        > this.label1.For eColor = System.Drawing. Color.Yellow;
        >
        > this.label1.Ima ge =
        > ((System.Drawin g.Image)(resour ces.GetObject(" label1.Image")) );
        >
        > this.label1.Ima geAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("labe l1.ImageAlign") ));
        >
        > this.label1.Ima geIndex = ((int)(resource s.GetObject("la bel1.ImageIndex ")));
        >
        > this.label1.Ime Mode =
        > ((System.Window s.Forms.ImeMode )(resources.Get Object("label1. ImeMode")));
        >
        > this.label1.Loc ation =
        > ((System.Drawin g.Point)(resour ces.GetObject(" label1.Location ")));
        >
        > this.label1.Nam e = "label1";
        >
        > this.label1.Rig htToLeft =
        > ((System.Window s.Forms.RightTo Left)(resources .GetObject("lab el1.RightToLeft ")));
        >
        > this.label1.Siz e =
        > ((System.Drawin g.Size)(resourc es.GetObject("l abel1.Size")));
        >
        > this.label1.Tab Index = ((int)(resource s.GetObject("la bel1.TabIndex") ));
        >
        > this.label1.Tex t = resources.GetSt ring("label1.Te xt");
        >
        > this.label1.Tex tAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("labe l1.TextAlign")) );
        >
        > this.label1.Vis ible = ((bool)(resourc es.GetObject("l abel1.Visible") ));
        >
        > //
        >
        > // button1
        >
        > //
        >
        > this.button1.Ac cessibleDescrip tion =
        > resources.GetSt ring("button1.A ccessibleDescri ption");
        >
        > this.button1.Ac cessibleName = resources.GetSt ring("button1.A ccessibleName") ;
        >
        > this.button1.An chor =
        > ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("bu tton1.Anchor")) );
        >
        > this.button1.Ba ckgroundImage =
        > ((System.Drawin g.Image)(resour ces.GetObject(" button1.Backgro undImage")));
        >
        > this.button1.Do ck =
        > ((System.Window s.Forms.DockSty le)(resources.G etObject("butto n1.Dock")));
        >
        > this.button1.En abled = ((bool)(resourc es.GetObject("b utton1.Enabled" )));
        >
        > this.button1.Fl atStyle =
        > ((System.Window s.Forms.FlatSty le)(resources.G etObject("butto n1.FlatStyle")) );
        >
        > this.button1.Fo nt =
        > ((System.Drawin g.Font)(resourc es.GetObject("b utton1.Font"))) ;
        >
        > this.button1.Im age =
        > ((System.Drawin g.Image)(resour ces.GetObject(" button1.Image") ));
        >
        > this.button1.Im ageAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on1.ImageAlign" )));
        >
        > this.button1.Im ageIndex =
        > ((int)(resource s.GetObject("bu tton1.ImageInde x")));
        >
        > this.button1.Im eMode =
        > ((System.Window s.Forms.ImeMode )(resources.Get Object("button1 .ImeMode")));
        >
        > this.button1.Lo cation =
        > ((System.Drawin g.Point)(resour ces.GetObject(" button1.Locatio n")));
        >
        > this.button1.Na me = "button1";
        >
        > this.button1.Ri ghtToLeft =
        > ((System.Window s.Forms.RightTo Left)(resources .GetObject("but ton1.RightToLef t")));
        >
        > this.button1.Si ze =
        > ((System.Drawin g.Size)(resourc es.GetObject("b utton1.Size"))) ;
        >
        > this.button1.Ta bIndex = ((int)(resource s.GetObject("bu tton1.TabIndex" )));
        >
        > this.button1.Te xt = resources.GetSt ring("button1.T ext");
        >
        > this.button1.Te xtAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on1.TextAlign") ));
        >
        > this.button1.Vi sible = ((bool)(resourc es.GetObject("b utton1.Visible" )));
        >
        > this.button1.Cl ick += new System.EventHan dler(this.butto n1_Click);
        >
        > //
        >
        > // button4
        >
        > //
        >
        > this.button4.Ac cessibleDescrip tion =
        > resources.GetSt ring("button4.A ccessibleDescri ption");
        >
        > this.button4.Ac cessibleName = resources.GetSt ring("button4.A ccessibleName") ;
        >
        > this.button4.An chor =
        > ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("bu tton4.Anchor")) );
        >
        > this.button4.Ba ckgroundImage =
        > ((System.Drawin g.Image)(resour ces.GetObject(" button4.Backgro undImage")));
        >
        > this.button4.Do ck =
        > ((System.Window s.Forms.DockSty le)(resources.G etObject("butto n4.Dock")));
        >
        > this.button4.En abled = ((bool)(resourc es.GetObject("b utton4.Enabled" )));
        >
        > this.button4.Fl atStyle =
        > ((System.Window s.Forms.FlatSty le)(resources.G etObject("butto n4.FlatStyle")) );
        >
        > this.button4.Fo nt =
        > ((System.Drawin g.Font)(resourc es.GetObject("b utton4.Font"))) ;
        >
        > this.button4.Im age =
        > ((System.Drawin g.Image)(resour ces.GetObject(" button4.Image") ));
        >
        > this.button4.Im ageAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on4.ImageAlign" )));
        >
        > this.button4.Im ageIndex =
        > ((int)(resource s.GetObject("bu tton4.ImageInde x")));
        >
        > this.button4.Im eMode =
        > ((System.Window s.Forms.ImeMode )(resources.Get Object("button4 .ImeMode")));
        >
        > this.button4.Lo cation =
        > ((System.Drawin g.Point)(resour ces.GetObject(" button4.Locatio n")));
        >
        > this.button4.Na me = "button4";
        >
        > this.button4.Ri ghtToLeft =
        > ((System.Window s.Forms.RightTo Left)(resources .GetObject("but ton4.RightToLef t")));
        >
        > this.button4.Si ze =
        > ((System.Drawin g.Size)(resourc es.GetObject("b utton4.Size"))) ;
        >
        > this.button4.Ta bIndex = ((int)(resource s.GetObject("bu tton4.TabIndex" )));
        >
        > this.button4.Te xt = resources.GetSt ring("button4.T ext");
        >
        > this.button4.Te xtAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on4.TextAlign") ));
        >
        > this.button4.Vi sible = ((bool)(resourc es.GetObject("b utton4.Visible" )));
        >
        > this.button4.Cl ick += new System.EventHan dler(this.butto n4_Click);
        >
        > //
        >
        > // button5
        >
        > //
        >
        > this.button5.Ac cessibleDescrip tion =
        > resources.GetSt ring("button5.A ccessibleDescri ption");
        >
        > this.button5.Ac cessibleName = resources.GetSt ring("button5.A ccessibleName") ;
        >
        > this.button5.An chor =
        > ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("bu tton5.Anchor")) );
        >
        > this.button5.Ba ckgroundImage =
        > ((System.Drawin g.Image)(resour ces.GetObject(" button5.Backgro undImage")));
        >
        > this.button5.Do ck =
        > ((System.Window s.Forms.DockSty le)(resources.G etObject("butto n5.Dock")));
        >
        > this.button5.En abled = ((bool)(resourc es.GetObject("b utton5.Enabled" )));
        >
        > this.button5.Fl atStyle =
        > ((System.Window s.Forms.FlatSty le)(resources.G etObject("butto n5.FlatStyle")) );
        >
        > this.button5.Fo nt =
        > ((System.Drawin g.Font)(resourc es.GetObject("b utton5.Font"))) ;
        >
        > this.button5.Im age =
        > ((System.Drawin g.Image)(resour ces.GetObject(" button5.Image") ));
        >
        > this.button5.Im ageAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on5.ImageAlign" )));
        >
        > this.button5.Im ageIndex =
        > ((int)(resource s.GetObject("bu tton5.ImageInde x")));
        >
        > this.button5.Im eMode =
        > ((System.Window s.Forms.ImeMode )(resources.Get Object("button5 .ImeMode")));
        >
        > this.button5.Lo cation =
        > ((System.Drawin g.Point)(resour ces.GetObject(" button5.Locatio n")));
        >
        > this.button5.Na me = "button5";
        >
        > this.button5.Ri ghtToLeft =
        > ((System.Window s.Forms.RightTo Left)(resources .GetObject("but ton5.RightToLef t")));
        >
        > this.button5.Si ze =
        > ((System.Drawin g.Size)(resourc es.GetObject("b utton5.Size"))) ;
        >
        > this.button5.Ta bIndex = ((int)(resource s.GetObject("bu tton5.TabIndex" )));
        >
        > this.button5.Te xt = resources.GetSt ring("button5.T ext");
        >
        > this.button5.Te xtAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on5.TextAlign") ));
        >
        > this.button5.Vi sible = ((bool)(resourc es.GetObject("b utton5.Visible" )));
        >
        > //
        >
        > // button6
        >
        > //
        >
        > this.button6.Ac cessibleDescrip tion =
        > resources.GetSt ring("button6.A ccessibleDescri ption");
        >
        > this.button6.Ac cessibleName = resources.GetSt ring("button6.A ccessibleName") ;
        >
        > this.button6.An chor =
        > ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("bu tton6.Anchor")) );
        >
        > this.button6.Ba ckgroundImage =
        > ((System.Drawin g.Image)(resour ces.GetObject(" button6.Backgro undImage")));
        >
        > this.button6.Do ck =
        > ((System.Window s.Forms.DockSty le)(resources.G etObject("butto n6.Dock")));
        >
        > this.button6.En abled = ((bool)(resourc es.GetObject("b utton6.Enabled" )));
        >
        > this.button6.Fl atStyle =
        > ((System.Window s.Forms.FlatSty le)(resources.G etObject("butto n6.FlatStyle")) );
        >
        > this.button6.Fo nt =
        > ((System.Drawin g.Font)(resourc es.GetObject("b utton6.Font"))) ;
        >
        > this.button6.Im age =
        > ((System.Drawin g.Image)(resour ces.GetObject(" button6.Image") ));
        >
        > this.button6.Im ageAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on6.ImageAlign" )));
        >
        > this.button6.Im ageIndex =
        > ((int)(resource s.GetObject("bu tton6.ImageInde x")));
        >
        > this.button6.Im eMode =
        > ((System.Window s.Forms.ImeMode )(resources.Get Object("button6 .ImeMode")));
        >
        > this.button6.Lo cation =
        > ((System.Drawin g.Point)(resour ces.GetObject(" button6.Locatio n")));
        >
        > this.button6.Na me = "button6";
        >
        > this.button6.Ri ghtToLeft =
        > ((System.Window s.Forms.RightTo Left)(resources .GetObject("but ton6.RightToLef t")));
        >
        > this.button6.Si ze =
        > ((System.Drawin g.Size)(resourc es.GetObject("b utton6.Size"))) ;
        >
        > this.button6.Ta bIndex = ((int)(resource s.GetObject("bu tton6.TabIndex" )));
        >
        > this.button6.Te xt = resources.GetSt ring("button6.T ext");
        >
        > this.button6.Te xtAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on6.TextAlign") ));
        >
        > this.button6.Vi sible = ((bool)(resourc es.GetObject("b utton6.Visible" )));
        >
        > //
        >
        > // label2
        >
        > //
        >
        > this.label2.Acc essibleDescript ion =
        > resources.GetSt ring("label2.Ac cessibleDescrip tion");
        >
        > this.label2.Acc essibleName = resources.GetSt ring("label2.Ac cessibleName");
        >
        > this.label2.Anc hor =
        > ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("la bel2.Anchor"))) ;
        >
        > this.label2.Aut oSize = ((bool)(resourc es.GetObject("l abel2.AutoSize" )));
        >
        > this.label2.Bac kColor = System.Drawing. Color.RosyBrown ;
        >
        > this.label2.Doc k =
        > ((System.Window s.Forms.DockSty le)(resources.G etObject("label 2.Dock")));
        >
        > this.label2.Ena bled = ((bool)(resourc es.GetObject("l abel2.Enabled") ));
        >
        > this.label2.Fon t =
        > ((System.Drawin g.Font)(resourc es.GetObject("l abel2.Font")));
        >
        > this.label2.For eColor = System.Drawing. Color.Yellow;
        >
        > this.label2.Ima ge =
        > ((System.Drawin g.Image)(resour ces.GetObject(" label2.Image")) );
        >
        > this.label2.Ima geAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("labe l2.ImageAlign") ));
        >
        > this.label2.Ima geIndex = ((int)(resource s.GetObject("la bel2.ImageIndex ")));
        >
        > this.label2.Ime Mode =
        > ((System.Window s.Forms.ImeMode )(resources.Get Object("label2. ImeMode")));
        >
        > this.label2.Loc ation =
        > ((System.Drawin g.Point)(resour ces.GetObject(" label2.Location ")));
        >
        > this.label2.Nam e = "label2";
        >
        > this.label2.Rig htToLeft =
        > ((System.Window s.Forms.RightTo Left)(resources .GetObject("lab el2.RightToLeft ")));
        >
        > this.label2.Siz e =
        > ((System.Drawin g.Size)(resourc es.GetObject("l abel2.Size")));
        >
        > this.label2.Tab Index = ((int)(resource s.GetObject("la bel2.TabIndex") ));
        >
        > this.label2.Tex t = resources.GetSt ring("label2.Te xt");
        >
        > this.label2.Tex tAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("labe l2.TextAlign")) );
        >
        > this.label2.Vis ible = ((bool)(resourc es.GetObject("l abel2.Visible") ));
        >
        > //
        >
        > // button7
        >
        > //
        >
        > this.button7.Ac cessibleDescrip tion =
        > resources.GetSt ring("button7.A ccessibleDescri ption");
        >
        > this.button7.Ac cessibleName = resources.GetSt ring("button7.A ccessibleName") ;
        >
        > this.button7.An chor =
        > ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("bu tton7.Anchor")) );
        >
        > this.button7.Ba ckgroundImage =
        > ((System.Drawin g.Image)(resour ces.GetObject(" button7.Backgro undImage")));
        >
        > this.button7.Do ck =
        > ((System.Window s.Forms.DockSty le)(resources.G etObject("butto n7.Dock")));
        >
        > this.button7.En abled = ((bool)(resourc es.GetObject("b utton7.Enabled" )));
        >
        > this.button7.Fl atStyle =
        > ((System.Window s.Forms.FlatSty le)(resources.G etObject("butto n7.FlatStyle")) );
        >
        > this.button7.Fo nt =
        > ((System.Drawin g.Font)(resourc es.GetObject("b utton7.Font"))) ;
        >
        > this.button7.Im age =
        > ((System.Drawin g.Image)(resour ces.GetObject(" button7.Image") ));
        >
        > this.button7.Im ageAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on7.ImageAlign" )));
        >
        > this.button7.Im ageIndex =
        > ((int)(resource s.GetObject("bu tton7.ImageInde x")));
        >
        > this.button7.Im eMode =
        > ((System.Window s.Forms.ImeMode )(resources.Get Object("button7 .ImeMode")));
        >
        > this.button7.Lo cation =
        > ((System.Drawin g.Point)(resour ces.GetObject(" button7.Locatio n")));
        >
        > this.button7.Na me = "button7";
        >
        > this.button7.Ri ghtToLeft =
        > ((System.Window s.Forms.RightTo Left)(resources .GetObject("but ton7.RightToLef t")));
        >
        > this.button7.Si ze =
        > ((System.Drawin g.Size)(resourc es.GetObject("b utton7.Size"))) ;
        >
        > this.button7.Ta bIndex = ((int)(resource s.GetObject("bu tton7.TabIndex" )));
        >
        > this.button7.Te xt = resources.GetSt ring("button7.T ext");
        >
        > this.button7.Te xtAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on7.TextAlign") ));
        >
        > this.button7.Vi sible = ((bool)(resourc es.GetObject("b utton7.Visible" )));
        >
        > //
        >
        > // button2
        >
        > //
        >
        > this.button2.Ac cessibleDescrip tion =
        > resources.GetSt ring("button2.A ccessibleDescri ption");
        >
        > this.button2.Ac cessibleName = resources.GetSt ring("button2.A ccessibleName") ;
        >
        > this.button2.An chor =
        > ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("bu tton2.Anchor")) );
        >
        > this.button2.Ba ckgroundImage =
        > ((System.Drawin g.Image)(resour ces.GetObject(" button2.Backgro undImage")));
        >
        > this.button2.Do ck =
        > ((System.Window s.Forms.DockSty le)(resources.G etObject("butto n2.Dock")));
        >
        > this.button2.En abled = ((bool)(resourc es.GetObject("b utton2.Enabled" )));
        >
        > this.button2.Fl atStyle =
        > ((System.Window s.Forms.FlatSty le)(resources.G etObject("butto n2.FlatStyle")) );
        >
        > this.button2.Fo nt =
        > ((System.Drawin g.Font)(resourc es.GetObject("b utton2.Font"))) ;
        >
        > this.button2.Im age =
        > ((System.Drawin g.Image)(resour ces.GetObject(" button2.Image") ));
        >
        > this.button2.Im ageAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on2.ImageAlign" )));
        >
        > this.button2.Im ageIndex =
        > ((int)(resource s.GetObject("bu tton2.ImageInde x")));
        >
        > this.button2.Im eMode =
        > ((System.Window s.Forms.ImeMode )(resources.Get Object("button2 .ImeMode")));
        >
        > this.button2.Lo cation =
        > ((System.Drawin g.Point)(resour ces.GetObject(" button2.Locatio n")));
        >
        > this.button2.Na me = "button2";
        >
        > this.button2.Ri ghtToLeft =
        > ((System.Window s.Forms.RightTo Left)(resources .GetObject("but ton2.RightToLef t")));
        >
        > this.button2.Si ze =
        > ((System.Drawin g.Size)(resourc es.GetObject("b utton2.Size"))) ;
        >
        > this.button2.Ta bIndex = ((int)(resource s.GetObject("bu tton2.TabIndex" )));
        >
        > this.button2.Te xt = resources.GetSt ring("button2.T ext");
        >
        > this.button2.Te xtAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on2.TextAlign") ));
        >
        > this.button2.Vi sible = ((bool)(resourc es.GetObject("b utton2.Visible" )));
        >
        > this.button2.Cl ick += new System.EventHan dler(this.butto n2_Click_1);
        >
        > //
        >
        > // button3
        >
        > //
        >
        > this.button3.Ac cessibleDescrip tion =
        > resources.GetSt ring("button3.A ccessibleDescri ption");
        >
        > this.button3.Ac cessibleName = resources.GetSt ring("button3.A ccessibleName") ;
        >
        > this.button3.An chor =
        > ((System.Window s.Forms.AnchorS tyles)(resource s.GetObject("bu tton3.Anchor")) );
        >
        > this.button3.Ba ckgroundImage =
        > ((System.Drawin g.Image)(resour ces.GetObject(" button3.Backgro undImage")));
        >
        > this.button3.Do ck =
        > ((System.Window s.Forms.DockSty le)(resources.G etObject("butto n3.Dock")));
        >
        > this.button3.En abled = ((bool)(resourc es.GetObject("b utton3.Enabled" )));
        >
        > this.button3.Fl atStyle =
        > ((System.Window s.Forms.FlatSty le)(resources.G etObject("butto n3.FlatStyle")) );
        >
        > this.button3.Fo nt =
        > ((System.Drawin g.Font)(resourc es.GetObject("b utton3.Font"))) ;
        >
        > this.button3.Im age =
        > ((System.Drawin g.Image)(resour ces.GetObject(" button3.Image") ));
        >
        > this.button3.Im ageAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on3.ImageAlign" )));
        >
        > this.button3.Im ageIndex =
        > ((int)(resource s.GetObject("bu tton3.ImageInde x")));
        >
        > this.button3.Im eMode =
        > ((System.Window s.Forms.ImeMode )(resources.Get Object("button3 .ImeMode")));
        >
        > this.button3.Lo cation =
        > ((System.Drawin g.Point)(resour ces.GetObject(" button3.Locatio n")));
        >
        > this.button3.Na me = "button3";
        >
        > this.button3.Ri ghtToLeft =
        > ((System.Window s.Forms.RightTo Left)(resources .GetObject("but ton3.RightToLef t")));
        >
        > this.button3.Si ze =
        > ((System.Drawin g.Size)(resourc es.GetObject("b utton3.Size"))) ;
        >
        > this.button3.Ta bIndex = ((int)(resource s.GetObject("bu tton3.TabIndex" )));
        >
        > this.button3.Te xt = resources.GetSt ring("button3.T ext");
        >
        > this.button3.Te xtAlign =
        > ((System.Drawin g.ContentAlignm ent)(resources. GetObject("butt on3.TextAlign") ));
        >
        > this.button3.Vi sible = ((bool)(resourc es.GetObject("b utton3.Visible" )));
        >
        > //
        >
        > // Form1
        >
        > //
        >
        > this.Accessible Description =
        > resources.GetSt ring("$this.Acc essibleDescript ion");
        >
        > this.Accessible Name = resources.GetSt ring("$this.Acc essibleName");
        >
        > this.AutoScaleB aseSize =
        > ((System.Drawin g.Size)(resourc es.GetObject("$ this.AutoScaleB aseSize")));
        >
        > this.AutoScroll = ((bool)(resourc es.GetObject("$ this.AutoScroll ")));
        >
        > this.AutoScroll Margin =
        > ((System.Drawin g.Size)(resourc es.GetObject("$ this.AutoScroll Margin")));
        >
        > this.AutoScroll MinSize =
        > ((System.Drawin g.Size)(resourc es.GetObject("$ this.AutoScroll MinSize")));
        >
        > this.Background Image =
        > ((System.Drawin g.Image)(resour ces.GetObject(" $this.Backgroun dImage")));
        >
        > this.ClientSize =
        > ((System.Drawin g.Size)(resourc es.GetObject("$ this.ClientSize ")));
        >
        > this.Controls.A dd(this.button3 );
        >
        > this.Controls.A dd(this.button2 );
        >
        > this.Controls.A dd(this.button6 );
        >
        > this.Controls.A dd(this.button5 );
        >
        > this.Controls.A dd(this.button4 );
        >
        > this.Controls.A dd(this.button1 );
        >
        > this.Controls.A dd(this.label1) ;
        >
        > this.Controls.A dd(this.label2) ;
        >
        > this.Controls.A dd(this.button7 );
        >
        > this.Enabled = ((bool)(resourc es.GetObject("$ this.Enabled")) );
        >
        > this.Font = ((System.Drawin g.Font)(resourc es.GetObject("$ this.Font")));
        >
        > this.Icon = ((System.Drawin g.Icon)(resourc es.GetObject("$ this.Icon")));
        >
        > this.ImeMode =
        > ((System.Window s.Forms.ImeMode )(resources.Get Object("$this.I meMode")));
        >
        > this.Location =
        > ((System.Drawin g.Point)(resour ces.GetObject(" $this.Location" )));
        >
        > this.MaximumSiz e =
        > ((System.Drawin g.Size)(resourc es.GetObject("$ this.MaximumSiz e")));
        >
        > this.MinimumSiz e =
        > ((System.Drawin g.Size)(resourc es.GetObject("$ this.MinimumSiz e")));
        >
        > this.Name = "Form1";
        >
        > this.RightToLef t =
        > ((System.Window s.Forms.RightTo Left)(resources .GetObject("$th is.RightToLeft" )));
        >
        > this.StartPosit ion =
        > ((System.Window s.Forms.FormSta rtPosition)(res ources.GetObjec t("$this.StartP osition")));
        >
        > this.Text = resources.GetSt ring("$this.Tex t");
        >
        > this.ResumeLayo ut(false);
        >
        > }
        >
        > #endregion
        >
        > /// <summary>
        >
        > /// The main entry point for the application.
        >
        > /// </summary>
        >
        > [STAThread]
        >
        > static void Main()
        >
        > {
        >
        > Form1 form1=new Form1();
        >
        > //Application.Run (new Form1());
        >
        > Application.Run (form1);
        >
        > }
        >
        > private void menuItem2_Click (object sender, System.EventArg s e)
        >
        > {
        >
        >
        > }
        >
        > private void button1_Click(o bject sender, System.EventArg s e)
        >
        > {
        >
        > tpsF=new TicketPartSelec tionForm();
        >
        > tpsF.Show();
        >
        > //bltler=new Biletler();
        >
        > //bltler.Show();
        >
        > }
        >
        > private void button4_Click(o bject sender, System.EventArg s e)
        >
        > {
        >
        > //ctP=new CustomerTravelP rocesses();
        >
        > //ctP.Show();
        >
        > }
        >
        > private void button2_Click(o bject sender, System.EventArg s e)
        >
        > {
        >
        > //cisF=new CustomerInfoSel ectionForm();
        >
        > //cisF.Show();
        >
        > }
        >
        > private void button8_Click(o bject sender, System.EventArg s e)
        >
        > {
        >
        >
        > }
        >
        > public void OpenTicketDesig n()
        >
        > {
        >
        > tpF=new TicketPrintingF orm();
        >
        > tdF=new TicketsDatabase Form();
        >
        > tpF.label1.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["Airline
        > Data"].ColumnName;
        >
        > tpF.label2.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["AllowA"].ColumnName;
        >
        > tpF.label3.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["AllowB"].ColumnName;
        >
        > tpF.label4.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["Baggage
        > Chk/UnChkA1"].ColumnName;
        >
        > tpF.label5.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["Baggage
        > Chk/UnChkA2"].ColumnName;
        >
        > tpF.label6.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["Baggage
        > Chk/UnChkB1"].ColumnName;
        >
        > tpF.label7.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["Baggage
        > Chk/UnChkB2"].ColumnName;
        >
        > tpF.label8.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["CarierA"].ColumnName;
        >
        > tpF.label9.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns["Carrier1"].ColumnName;
        >
        > tpF.label10.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Carrier2"].ColumnName;
        >
        > tpF.label11.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Carrier3"].ColumnName;
        >
        > tpF.label12.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Carrier4"].ColumnName;
        >
        > tpF.label13.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["CarrierB"].ColumnName;
        >
        > tpF.label14.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["ClassA"].ColumnName;
        >
        > tpF.label15.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["ClassB"].ColumnName;
        >
        > tpF.label16.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Date
        > And Place Of Issue"].ColumnName;
        >
        > tpF.label17.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["DateA"].ColumnName;
        >
        > tpF.label18.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["DateB"].ColumnName;
        >
        > tpF.label19.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Destinatio n"].ColumnName;
        >
        > tpF.label20.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Fare"].ColumnName;
        >
        > tpF.label21.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Fare
        > BasisA"].ColumnName;
        >
        > tpF.label22.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Fare
        > BasisB"].ColumnName;
        >
        > tpF.label23.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Form Of
        > Payment"].ColumnName;
        >
        > tpF.label24.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["From"].ColumnName;
        >
        > tpF.label25.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Location1"].ColumnName;
        >
        > tpF.label26.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Location2"].ColumnName;
        >
        > tpF.label27.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Location3"].ColumnName;
        >
        > tpF.label28.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Location4"].ColumnName;
        >
        > tpF.label29.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Mr/Mrs"].ColumnName;
        >
        > tpF.label30.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Name"].ColumnName;
        >
        > tpF.label31.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Not
        > Valid AfterA"].ColumnName;
        >
        > tpF.label32.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Not
        > Valid AfterB"].ColumnName;
        >
        > tpF.label33.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Not
        > Valid BeforeA"].ColumnName;
        >
        > tpF.label34.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Not
        > Valid BeforeB"].ColumnName;
        >
        > tpF.label35.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Passport
        > Number"].ColumnName;
        >
        > tpF.label36.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["StatusA"].ColumnName;
        >
        > tpF.label37.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["StatusB"].ColumnName;
        >
        > tpF.label38.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Surname"].ColumnName;
        >
        > tpF.label39.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["TimeA"].ColumnName;
        >
        > tpF.label40.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["TimeB"].ColumnName;
        >
        > tpF.label41.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["To"].ColumnName;
        >
        > tpF.label42.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["To1"].ColumnName;
        >
        > tpF.label43.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns["Total"].ColumnName;
        >
        >
        >
        >
        >
        > //tpF.label44.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns[43].ColumnName;
        >
        > //tpF.label45.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns[44].ColumnName;
        >
        > //tpF.label46.Tex t=tdF.ticketToP rintRecordsData Set1.Tables[0].Columns[45].ColumnName;
        >
        > //tpF.label1.Text =tdF.ticketToPr intRecordsDataS et1.Tables[0].Columns[46].ColumnName;
        >
        >
        >
        > tpF.Show();
        >
        > }
        >
        > private void button9_Click(o bject sender, System.EventArg s e)
        >
        > {
        >
        > //OpenTicketDesig n();
        >
        > }
        >
        > private void button10_Click( object sender, System.EventArg s e)
        >
        > {
        >
        >
        > }
        >
        > private void button2_Click_1 (object sender, System.EventArg s e)
        >
        > {
        >
        > RezervationForm rF=new RezervationForm ();
        >
        > rF.Show();
        >
        > }
        >
        > private void button3_Click(o bject sender, System.EventArg s e)
        >
        > {
        >
        >
        > }
        >
        > }
        >
        > }
        >
        >
        >[/color]

        Comment

        • Morten Wennevik

          #5
          Re: Button Text Not Changed Problem

          Hi Arif,

          If that button is button2, notice that you set button2.Text after InitializeCompo nent in your constructor.

          --
          Happy coding!
          Morten Wennevik [C# MVP]

          Comment

          Working...