Feeds:
Posts
Comments

Archive for the ‘Windows form’ Category

use follwing Code change image path at load event method for downloading Code

Imports System
Imports System.Drawing
Imports System.Drawing.Imaging
Imports System.Drawing.Drawing2D
Public Class Form1
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim WorkingDirectory As String = “c:\AliPicture”
‘create a image object containing a verticel photograph
Dim imgPhotoVert As Image = Image.FromFile(WorkingDirectory + “\pravs-j-the-first-step.jpg”)
Dim imgPhoto As Image = Nothing
imgPhoto = [...]

Read Full Post »

A common requirement for a form is to remember its last location. Usually, this information
is stored in the registry. The code that follows shows a helper class that automatically stores
information about a form’s size and position using a key based on the name of a form.
public class FormPositionHelper
{
public static string RegPath = [...]

Read Full Post »

Some time developer/coder have to choose appropriate location of windows form on the screen, But limitation comes with the size and resolution of monitor. The solution is used Screen Class which gives right gives you working area of screen of monitor. Then Form load Event will look like this
private void dynamicSizeForm_Load(System.Object sender, System.EventArgse)
{
Screen scr = Screen.PrimaryScreen;
this.Left [...]

Read Full Post »