Wednesday, April 8, 2009
.NET Windows Form Activated event - C#
Form2.cs
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace WindowsApplication1
{
public partial class Form2 : Form
{
Form1 oForm1;
public Form2()
{
InitializeComponent();
oForm1 = new Form1();
}
private void button1_Click(object sender, EventArgs e)
{
oForm1.Show();
oForm1.Activate();
}
}
}
Form1.cs
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace WindowsApplication1
{
public partial class Form1 : Form
{
static int noOfActivation;
public Form1()
{
InitializeComponent();
}
private void Form1_Activated(object sender, System.EventArgs e)
{
noOfActivation = noOfActivation +1;
label1.Text = "Activated: " + noOfActivation;
}
private void Form1_Load(object sender, EventArgs e)
{
}
}
}
Output
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace WindowsApplication1
{
public partial class Form2 : Form
{
Form1 oForm1;
public Form2()
{
InitializeComponent();
oForm1 = new Form1();
}
private void button1_Click(object sender, EventArgs e)
{
oForm1.Show();
oForm1.Activate();
}
}
}
Form1.cs
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace WindowsApplication1
{
public partial class Form1 : Form
{
static int noOfActivation;
public Form1()
{
InitializeComponent();
}
private void Form1_Activated(object sender, System.EventArgs e)
{
noOfActivation = noOfActivation +1;
label1.Text = "Activated: " + noOfActivation;
}
private void Form1_Load(object sender, EventArgs e)
{
}
}
}
Output
Saturday, January 31, 2009
Developer & .NET framework 3.0 / 3.5
With launch of framework 3.0 and 3.5 Microsoft equipped developer with tools / technology to address current business software needs. The VS 2008 has feature which targets multiple .net frameworks. It helps developer to embrace latest .net version quickly at the same time provide backward support. Improved debugging where a developer can also debug JavaScript code putting various breakpoints in JavaScript code. Some of the improvements in VS 2008 like IntelliSense for JavaScript and CSS Style. The inclusion of AJAX library with .NET 3.5 will help developer not to download separately. The Windows Presentation Foundation (WPF) is a clear separation between user interface and business logic. It enables developer and designer to collaborate and work together. Designers can use Microsoft Expression Blend to design the pages. Expression Blend is a tool help for designing XAML based interfaces for WPF. Silverlight is just awesome! Launch of WCF (Windows Communication Foundation) enables communication among different software entities without knowing multiple languages. Lastly WWF (Windows Work flow Foundation) for defining, executing and managing work flows really is a well thought answer to common business challenges. In nutshell these features will definitely make life easy for software developers, architects and designers.
Tuesday, January 20, 2009
Silverlight 2 & Product Development
Present UI Challenges
In a typical product development scenario a Product Manager often get frustrated by seeing the quality of delivered product. UI turns out to be bad, it has issues with fonts, images, alignment and so forth. It doesn't have the user experience customer is looking for. Designers claimed they had provided a good UI to developers and the integrated UI ended up with issues. Developer says it was time consuming to integrate UI design changes. Nobody knows where was the problem. Project gets delayed and you also have cross browser issues. On top of everything "Customers want more", content should be compelling.
Silverlight
This time is of interactive web sites, videos and social networking. User Experience is key to software success. At this moment Microsoft's Silverlight turns out to be really a good friend. You not only create enhanced graphical applications, it also offers developers and designers a tool to collaborate and deliver. Is it really a "friend indeed a friend in need"? You have Visual Studio for developers, Expression Studio for designers. Microsoft's Expression Blend supporting XAML interfaces for Silverlight application can be used by the designers for enhance and effective User Interface . With Expression Blend you can create complex graphics application where you have customizable controls. Silverlight also supports multiple platforms, you do not have the cross browser issues. The Silverlight 2 architecture includes BCL (Business Class Library) which provides classes for strings, data access and regular expressions. This means building a Silverlight application has the same experience as building a WPF (Windows Presentation Foundation) application. Another important component is DLR engine (Dynamic Language Run time) supporting multiple scripting language (Python, Ruby, VBScript, JavaScript). DLR comes with web server containing dependencies of dynamic languages. It helps developer to share the code regardless of the language it is implemented.
Two Product Development Scenarios
In a typical product development scenario a Product Manager often get frustrated by seeing the quality of delivered product. UI turns out to be bad, it has issues with fonts, images, alignment and so forth. It doesn't have the user experience customer is looking for. Designers claimed they had provided a good UI to developers and the integrated UI ended up with issues. Developer says it was time consuming to integrate UI design changes. Nobody knows where was the problem. Project gets delayed and you also have cross browser issues. On top of everything "Customers want more", content should be compelling.
Silverlight
This time is of interactive web sites, videos and social networking. User Experience is key to software success. At this moment Microsoft's Silverlight turns out to be really a good friend. You not only create enhanced graphical applications, it also offers developers and designers a tool to collaborate and deliver. Is it really a "friend indeed a friend in need"? You have Visual Studio for developers, Expression Studio for designers. Microsoft's Expression Blend supporting XAML interfaces for Silverlight application can be used by the designers for enhance and effective User Interface . With Expression Blend you can create complex graphics application where you have customizable controls. Silverlight also supports multiple platforms, you do not have the cross browser issues. The Silverlight 2 architecture includes BCL (Business Class Library) which provides classes for strings, data access and regular expressions. This means building a Silverlight application has the same experience as building a WPF (Windows Presentation Foundation) application. Another important component is DLR engine (Dynamic Language Run time) supporting multiple scripting language (Python, Ruby, VBScript, JavaScript). DLR comes with web server containing dependencies of dynamic languages. It helps developer to share the code regardless of the language it is implemented.
Two Product Development Scenarios
I have shown below two typical scenarios:
Product development before Silverlight:
A Product Manager provides requirements to team (Developers and Designers). They work independently, designer provides final UI pages to developer. Developer integrates pages with the system. Output is shown to Product Manager. Once the delivery is finally approved, product is shown to client.
Product development after Silverlight
A Product Manager provides requirements to team (Designers and Developers). They work collaboratively, and delivers the system. Collaboration across team members with high visibility of product. No last minute surprises. No formal approval needed. Team confidence is high. Product shown to client.
Summary
In the later case (with Silverlight) team works collaboratively and efficiently. The delivery shown to client better in quality with less development time. Product provides better User Experience. Now developers can see designers modifications at real time. There is no interdependency and rework needed. In nutshell, with Silverlight product development has become more efficient and productive.
Subscribe to:
Posts (Atom)
Followers
About Me
- Rohit Sinha
- Happily married, live in Dallas with his wife and daughter. Working as a Product Manager.