Introduction

A linked list is a collection where, if the list contains more than one item, every item holds a reference to the item previous or next to it. Serialization is the ability to send the values of an application to a medium. In this application, we will apply our knowldge of linked lists to create records for a fictional real estate company. The records of the application will be saved using JSON serialization.

Practical LearningPractical Learning: Introducing the Application

  1. On your C: drive or any drive of your choice, create a folder (or directory) named Altair Realtors
    If you create that folder in another drive, then make the necessary updates throughout the code of this project
  2. Save the following illustrations in that folder:

    Home

    Home

    Home

  3. Start Microsoft Visual Studio. In the Visual Studio 2022 dialog box, click Create a New Project (if Microsoft Visual Studio was already opened, on the main menu, click File -> New -> Project...)
  4. Make sure the first combo box is displaying either All Languages or C#.
    In the list of projects types, select Windows Forms App
  5. Click Next
  6. Change the Project Name to AltairRealtors
  7. Click Next
  8. Make sure the Framework combo box displays the latest version.
    Click Create

A Class for a Real Estate Property

In real estate, a property is primaily a place where people live, such as a house (a real estate property can be more than that but we are keeping our definition simple). Such a property is the basis of our project. To support it, we will create a simple class.

Practical LearningPractical Learning: Creating a Starting Class

  1. To create a new class, on the main menu, click Project -> Add Class...
  2. Set the Name to Property
  3. Click Add
  4. Change the file as follows:
    namespace AltairRealtors
    {
        public class Property
        {
            public string PropertyNumber { get; set; }
            public string PropertyType   { get; set; }
            public string Address        { get; set; }
            public string City           { get; set; }
            public string State          { get; set; }
            public string ZIPCode        { get; set; }
            public short  Stories        { get; set; }
            public short  Bedrooms       { get; set; }
            public float  Bathrooms      { get; set; }
            public int    YearBuilt      { get; set; }
            public string Condition      { get; set; }
            public double MarketValue    { get; set; }
            public string SaleStatus     { get; set; }
            public string PictureFile    { get; set; }
    
            // To determine that two properties are the same,
            // we will test only the property number.
            // We assume that if two properties have the same number,
            // then it is the same property
            public override bool Equals(object obj)
            {
                Property rep = (Property)obj;
    
                if (rep.PropertyNumber == PropertyNumber)
                    return true;
                else
                    return false;
            }
    
    	// To avoid a compiler warning
            public override int GetHashCode()
            {
                return base.GetHashCode();
            }
        }
    }

A Form to Create a Real Estate Property

We will need a form that can allow a user to create a real estate property. The form will essentially have the controls represented in the class that was just created.

Practical LearningPractical Learning: Creating a Starting Class

  1. To create a new form, on the main menu, click Project -> Add Form (Windows Forms)...
  2. Set the Name to PropertyNew
  3. Click Add
  4. Using the Properties window, change the following characteristics of the form:
    Text: Altair Realtors - New Property
    StartPosition: CenterScreen
    MaximizeBox: False
    MinimizeBox: False
    ShowInTaskBar: False
  5. In the Dialogs section of the Toolbox, click OpenFileDialog
  6. Click the form
  7. Design the form as follows:

    Altair Reators - New Property

    Control (Name) Text Other Properties
    Label Label   Property #:  
    TextBox Text Box txtPropertyNumber    
    Label Label   Property Type:  
    ComboBox ComboBox cbxPropertiesTypes   DropDownStyle: DropDownList
    Items: Unknown
    Townhouse
    Single Family
    Condominium
    Button btnSelectPicture Select Property Picture...  
    Label Label lblPictureFile .  
    Label Label   Address:  
    TextBox Text Box txtAddress    
    PictureBox PictureBox pbxProperty   BorderStyle: Fixed3D
    SizeMode: AutoSize
    Label Label   City:  
    TextBox Text Box txtCity    
    Label Label   State:  
    TextBox ComboBox txtState    
    Label Label   ZIP Code:  
    TextBox Text Box txtZIPCode    
    Label Label   Stories:  
    TextBox Text Box txtStories    
    Label Label   Bedrooms:  
    TextBox Text Box txtBedrooms    
    Label Label   Bathrooms:  
    TextBox Text Box txtBathrooms    
    Label Label   Year Built:  
    TextBox Text Box txtYearBuilt    
    Label Label   Condition:  
    ComboBox ComboBox cbxConditions   DropDownStyle: DropDownList
    Items: Unknown
    Excellent
    Good Shape
    Needs Remodeling
    Under Construction
    Label Label   Market Value:  
    TextBox Text Box txtMarketValue    
    Label Label   Sale Status:  
    ComboBox ComboBox cbxSaleStatus   DropDownStyle: DropDownList
    Items: Sold
    Available
    Unspecified
    Label Label   ___________________________________  
    Button btnSaveProperty Save Property Information  
    Button btnClose Close  
  8. Double-click an unoccupied area of the form
  9. Return to the form and double-click the Select Property Picture button
  10. Return to the form and double-click the Save Property button
  11. Return to the form and double-click the Close Property button
  12. Change the document as follows:
    using System.Text.Json;
    
    namespace AltairRealtors
    {
        public partial class PropertyNew : Form
        {
            public PropertyNew()
            {
                InitializeComponent();
            }
    
            /* This method is used to reset the form. 
             * It can be called when necessary. */
            private void InitializeProperty()
            {
                txtPropertyNumber.Text = string.Empty;
                txtAddress.Text        = string.Empty;
                txtCity.Text           = string.Empty;
                txtState.Text          = string.Empty;
                txtZIPCode.Text        = string.Empty;
                txtStories.Text        = string.Empty;
                txtYearBuilt.Text      = string.Empty;
                txtBedrooms.Text       = string.Empty;
                txtBathrooms.Text      = string.Empty;
                txtMarketValue.Text    = string.Empty;
    
                // We have a default property image
                lblPictureFile.Text = "C:\\Altair Realtors\\Generic1.png";
                pbxProperty.Image = Image.FromFile("C:\\Altair Realtors\\Generic1.png");
    
                /* Whenever the picture of a property displays,
                 * we will resize the form to show the whole picture. */ 
                Width  = pbxProperty.Right  + 40;
                Height = pbxProperty.Bottom + 75;
            }
    
            private void PropertyNew_Load(object sender, EventArgs e)
            {
                InitializeProperty();
            }
    
            private void btnSelectPicture_Click(object sender, EventArgs e)
            {
                // Display the Open File Dialog box to allow the user to select a picture
                if(ofdPropertyImage.ShowDialog() == DialogResult.OK)
                {
                    // If the user successfully selects a picture, display it in the picture box
                    pbxProperty.Image = Image.FromFile(ofdPropertyImage.FileName);
                    lblPictureFile.Text = ofdPropertyImage.FileName;
    
                    Width = pbxProperty.Right + 40;
                    Height = pbxProperty.Bottom + 75;
                }
            }
    
            private void btnSaveProperty_Click(object sender, EventArgs e)
            {
                // This variable will hold the whole list of properties
                string strProperties = string.Empty;
                // This variable is the list of properties. It is used as a linked list
                LinkedList<Property> properties = new LinkedList<Property>();
                /* Normally, we will provide a property number for each property.
                 * So the following two lines are practically useless. */
                Random rndNumber = new Random(DateTime.Now.Millisecond);
                txtPropertyNumber.Text = rndNumber.Next(100000, 999999).ToString();
    
                // Get a reference to the file that holds the list of real estate properties
                string strFileName = "C:\\Altair Realtors\\Properties.json";
    
                // If a file that contains a list of properties was already created...
                if (File.Exists(strFileName) == true)
                {
                    /* ... open it. Read the text of all the properties.
                     * Put that list is the variable we had declared for it. */
                    strProperties = File.ReadAllText(strFileName);
                    /* JSON deserialize the list to convert the document into a JSON format.
                     * Store the list in a linked list variable we had declared. */
                    properties = JsonSerializer.Deserialize<LinkedList<Property>>(strProperties)!;
                }
    
                /* Create a new real estate property based on the values
                 * the user should have provided in the Windows controls of the form. */
                Property residence = new Property();
    
                residence.PropertyNumber = txtPropertyNumber.Text;
                residence.PropertyType = cbxPropertiesTypes.Text;
                residence.Address = txtAddress.Text;
                residence.City = txtCity.Text;
                residence.State = txtState.Text;
                residence.ZIPCode = txtZIPCode.Text;
                residence.Stories = short.Parse(txtStories.Text);
                residence.YearBuilt = int.Parse(txtYearBuilt.Text);
                residence.Bedrooms = short.Parse(txtBedrooms.Text);
                residence.Bathrooms = float.Parse(txtBathrooms.Text);
                residence.Condition = cbxConditions.Text;
                residence.SaleStatus = cbxSaleStatus.Text;
                residence.MarketValue = double.Parse(txtMarketValue.Text);
                residence.PictureFile = lblPictureFile.Text;
                
                // Add the real estate property record in the linked list
                properties.AddFirst(residence);
    
                /* To prepare to serialize the list, make sure 
                 * the values follow the indentation of a JSON-based document. */
                JsonSerializerOptions options = new JsonSerializerOptions();
                options.WriteIndented = true;
                
                // JSON serialize the list
                string jsProperties = JsonSerializer.Serialize(properties, typeof(LinkedList<Property>), options);
                File.WriteAllText(strFileName, jsProperties);
    
                // After creating the record, reset the form in case the user wants to create another record.
                InitializeProperty();
            }
    
            private void btnClose_Click(object sender, EventArgs e)
            {
                Close();
            }
        }
    }

Inserting a Record

One of the interesting operations of a collection class is when it has built-in functionality to insert a new record between two existing record or at the begining of the list. A linked list goes one step further. It allows you to insert an item before or after an existing one. We will allow the user to do this.

Practical LearningPractical Learning: Inserting a Record

  1. To create a new form, on the main menu, click Project -> Add Form (Windows Forms)...
  2. Set the Name to PropertyInsert
  3. Click Add
  4. Using the Properties window, change the following characteristics of the form:
    StartPosition: CenterScreen
    MaximizeBox: False
    MinimizeBox: False
    ShowInTaskBar: False
  5. Resize the form to have approximately the same dimensions as the New Property form (if you want, you can click an unoccupied area of the New Property form; then, in the Properties window, copy the value in the Zize field, and paste that value in the Size field of the Properties window for the Property Editor form)
  6. Copy the controls from the New Property form and paste them in the Property Editor form (you can display the New Property form, press Ctrl + A, then click the Property Editor form, and press Ctrl + V)
  7. Delete the Properties Type combo box
  8. Complete the design of the Property Editor form as follows:

    Altair Realtors - Inserting a Real Estate Property

    Control (Name) Text
    Label Label   Existing Property #:
    TextBox Text Box txtExistingPropertyNumber  
    Label Label   New Property #:
    TextBox Text Box txtNewPropertyNumber  
    TextBox Text Box txtPropertyType  
    Button Button btnInsertProperty Insert Property
  9. Double-click and unoccupied area of the Insert Property form
  10. Return to the Insert Property form and double-click the Select Property Picture button
  11. Change the document as follows:
    namespace AltairRealtors
    {
        public partial class PropertyInsert : Form
        {
            public PropertyInsert()
            {
                InitializeComponent();
            }
    
            private void PropertyInsert_Load(object sender, EventArgs e)
            {
                lblPictureFile.Text = "C:\\Altair Realtors\\Generic1.png";
                pbxProperty.Image   = Image.FromFile("C:\\Altair Realtors\\Generic1.png");
    
                Width               = pbxProperty.Right + 40;
                Height              = pbxProperty.Bottom + 75;
            }
    
            private void btnSelectPicture_Click(object sender, EventArgs e)
            {
                if (ofdPropertyImage.ShowDialog() == DialogResult.OK)
                {
                    pbxProperty.Image   = Image.FromFile(ofdPropertyImage.FileName);
                    lblPictureFile.Text = ofdPropertyImage.FileName;
    
                    Width               = pbxProperty.Right + 40;
                    Height              = pbxProperty.Bottom + 75;
                }
            }
        }
    }

Updating a Record

One of the necessary operations of a database is the ability to update records. We will provide this functionality trough a form.

Practical LearningPractical Learning: Updating a Record

  1. To create a new form, on the main menu, click Project -> Add Form (Windows Forms)...
  2. Set the Name to PropertyEditor
  3. Click Add
  4. Using the Properties window, change the following characteristics of the form:
    FormBorderStyle: FixedDialog
    Text: Altair Realtors - Property Editor
    StartPosition: CenterScreen
    MaximizeBox: False
    MinimizeBox: False
    ShowInTaskBar: False
  5. Resize the form to have approximately the same dimensions as the New Property form (if you want, you can click an unoccupied area of the New Property form; then, in the Properties window, copy the value in the Zize field, and paste that value in the Size field of the Properties window for the Property Editor form)
  6. Copy the controls from the New Property form and paste them in the Property Editor form (you can display the New Property form, press Ctrl + A, then click the Property Editor form, and press Ctrl + V)
  7. Complete the design of the Property Editor form as follows:

    Altair Realtors - Property Editor

    Control (Name) Text Other Properties
    Button btnFind Find  
    Button Button btnUpdateProperty Update Property Information  
  8. Double-click an unoccupied area of the form
  9. Return to the Property Editor form and double-click the Find button
  10. Return to the Property Editor form and double-click the Select Property Picture button
  11. Return to the Property Editor form and double-click the Update Property button
  12. Return to the form and double-click the Close Property button
  13. Change the document as follows:
    using System.Text.Json;
    
    namespace AltairRealtors
    {
        public partial class PropertyEditor : Form
        {
            public PropertyEditor()
            {
                InitializeComponent();
            }
    
            private void ResetProperty()
            {
                txtPropertyNumber.Text = string.Empty;
                txtAddress.Text        = string.Empty;
                txtCity.Text           = string.Empty;
                txtState.Text          = string.Empty;
                txtZIPCode.Text        = string.Empty;
                txtStories.Text        = string.Empty;
                txtYearBuilt.Text      = string.Empty;
                txtBedrooms.Text       = string.Empty;
                txtBathrooms.Text      = string.Empty;
                txtMarketValue.Text    = string.Empty;
    
                lblPictureFile.Text    = "C:\\Altair Realtors\\Generic2.png";
                pbxProperty.Image      = Image.FromFile("C:\\Altair Realtors\\Generic2.png");
    
                Width                  = pbxProperty.Right  + 40;
                Height                 = pbxProperty.Bottom + 75;
            }
    
            public void ShowProperty(string propNbr)
            {
                /* As you will find out later, the argument is provided by 
                 * the Properties Listing form.
                 * Normally, that argument should always be provided.
                 * Just in case it is not, don't do nothing. */
                if (propNbr is null)
                    return;
    
                /* Create a real estate property using
                 * the property number that is passed to this function. */
                Property residence = new();
                residence.PropertyNumber = propNbr;
    
                // Prepare to get a list of real estate properties 
                LinkedList<Property> properties;
                // This is the file that holds the list of real estate properties
                string strFileName = "C:\\Altair Realtors\\Properties.json";
    
                // Find out whether a file for real estate properties was already created.
                if (File.Exists(strFileName) == true)
                {
                    // If the file of real estate properties was already created, open it
                    string strProperties = strProperties = File.ReadAllText(strFileName);
                    /* Deserialize the file and store the list of real estate properties
                     * in the linked list variable that had already been declared. */
                    properties = JsonSerializer.Deserialize<LinkedList<Property>>(strProperties)!;
    
                    // Find the property in the list
                    LinkedListNode<Property> property = properties.Find(residence)!;
    
                    /* If the real estate property was found in the file,
                     * update its record with the values the user provided in the form. */
                    if (residence is not null)
                    {
                        txtPropertyNumber.Text  = propNbr;
                        cbxPropertiesTypes.Text = property.Value.PropertyType;
                        txtAddress.Text         = property.Value.Address;
                        txtCity.Text            = property.Value.City;
                        txtState.Text           = property.Value.State;
                        txtZIPCode.Text         = property.Value.ZIPCode;
                        txtStories.Text         = property.Value.Stories.ToString();
                        txtYearBuilt.Text       = property.Value.YearBuilt.ToString();
                        txtBedrooms.Text        = property.Value.Bedrooms.ToString();
                        txtBathrooms.Text       = property.Value.Bathrooms.ToString("f");
                        cbxConditions.Text      = property.Value.Condition;
                        cbxSaleStatus.Text      = property.Value.SaleStatus;
                        txtMarketValue.Text     = property.Value.MarketValue.ToString("f");
                        lblPictureFile.Text     = property.Value.PictureFile;
                        pbxProperty.Image       = Image.FromFile(property.Value.PictureFile!);
    
                        Width = pbxProperty.Right + 40;
                        Height = pbxProperty.Bottom + 75;
                    }
                }
            }
    
            private void PropertyEditor_Load(object sender, EventArgs e)
            {
                lblPictureFile.Text = "E:\\Altair Realtors\\Generic3.png";
                pbxProperty.Image   = Image.FromFile("E:\\Altair Realtors\\Generic3.png");
    
                Width = pbxProperty.Right + 40;
                Height = pbxProperty.Bottom + 75;
            }
    
            private void btnFind_Click(object sender, EventArgs e)
            {
                if( string.IsNullOrEmpty(txtPropertyNumber.Text))
                {
                    MessageBox.Show("You must enter a property number.",
                                    "Altair Realtors", MessageBoxButtons.OK, MessageBoxIcon.Information);
                    return;
                }
    
                ShowProperty(txtPropertyNumber.Text);
            }
    
            private void btnSelectPicture_Click(object sender, EventArgs e)
            {
                if (ofdPropertyImage.ShowDialog() == DialogResult.OK)
                {
                    pbxProperty.Image = Image.FromFile(ofdPropertyImage.FileName);
                    lblPictureFile.Text = ofdPropertyImage.FileName;
    
                    Width = pbxProperty.Right + 40;
                    Height = pbxProperty.Bottom + 75;
                }
            }
    
            private void btnUpdateProperty_Click(object sender, EventArgs e)
            {
                if (string.IsNullOrEmpty(txtPropertyNumber.Text))
                {
                    MessageBox.Show("You must enter a property number.",
                                    "Altair Realtors", MessageBoxButtons.OK, MessageBoxIcon.Information);
                    return;
                }
    
                LinkedList<Property> properties;
                string strFileName = "C:\\Altair Realtors\\Properties.json";
    
                Property residence = new();
                residence.PropertyNumber = txtPropertyNumber.Text;
    
                if (File.Exists(strFileName) == true)
                {
                    string strProperties = strProperties = File.ReadAllText(strFileName);
                    properties = JsonSerializer.Deserialize<LinkedList<Property>>(strProperties)!;
    
                    LinkedListNode<Property> property = properties.Find(residence)!;
    
                    if (residence is not null)
                    {
                        property.Value.PropertyType   = cbxPropertiesTypes.Text;
                        property.Value.Address        = txtAddress.Text;
                        property.Value.City           = txtCity.Text;
                        property.Value.State          = txtState.Text;
                        property.Value.ZIPCode        = txtZIPCode.Text;
                        property.Value.Stories        = short.Parse(txtStories.Text);
                        property.Value.YearBuilt      = int.Parse(txtYearBuilt.Text);
                        property.Value.Bedrooms       = short.Parse(txtBedrooms.Text);
                        property.Value.Bathrooms      = float.Parse(txtBathrooms.Text);
                        property.Value.Condition      = cbxConditions.Text;
                        property.Value.SaleStatus     = cbxSaleStatus.Text;
                        property.Value.MarketValue    = double.Parse(txtMarketValue.Text);
                        property.Value.PictureFile    = lblPictureFile.Text;
    
                        JsonSerializerOptions options = new JsonSerializerOptions();
                        options.WriteIndented = true;
    
                        string jsProperties = JsonSerializer.Serialize(properties, typeof(LinkedList<Property>), options);
                        File.WriteAllText(strFileName, jsProperties);
                    }
    
                    ResetProperty();
                }
            }
    
            private void btnClose_Click(object sender, EventArgs e)
            {
                Close();
            }
        }
    }

Deleting a Real Estate Property

If you have a record you don't need in your application, you can remove it. We will use a form to assist the user to do that.

Practical LearningPractical Learning: Introducing Linked Lists

  1. To create a new form, on the main menu, click Project -> Add Form (Windows Forms)...
  2. Set the Name to PropertyDelete
  3. Click Add
  4. Using the Properties window, change the following characteristics of the form:
    FormBorderStyle: FixedDialog
    Text: Altair Realtors - Delete Property
    StartPosition: CenterScreen
    MaximizeBox: False
    MinimizeBox: False
    ShowInTaskBar: False
  5. Resize the form to have approximately the same dimensions as the Property Editor form
  6. Copy the controls from the Property Editor form and paste them in the Property Delete form
  7. Delete the three combo boxes on the form. Replace them with text boxes
  8. Below the form, delete the Open File Dialog control
  9. Complete the design of the Property Delete form as follows:

    Altair Realtors - Property Deletion

    Control (Name) Text
    TextBox Text Box txtPropertyType  
    TextBox Text Box txtCondition  
    TextBox Text Box txtSaleStatus  
    Button btnDeleteProperty Delete Property Record
  10. Click each text box on the form
  11. Then, in the Properties window, double-click Enabled to set its value to False
  12. On the form, click the Property Number text box
  13. Then, in the Properties window, double-click Enabled to set its values to True
  14. Double-click an unoccupied area of the form
  15. Return to the Delete Property form and double-click the Find button
  16. Return to the Delete Property form and double-click the Delete Property button
  17. Return to the form and double-click the Close Property button
  18. Change the document as follows:
    using System.Text.Json;
    
    namespace AltairRealtors
    {
        public partial class PropertyDelete : Form
        {
            public PropertyDelete()
            {
                InitializeComponent();
            }
    
            private void ResetProperty()
            {
                txtPropertyNumber.Text = string.Empty;
                txtAddress.Text        = string.Empty;
                txtCity.Text           = string.Empty;
                txtState.Text          = string.Empty;
                txtZIPCode.Text        = string.Empty;
                txtStories.Text        = string.Empty;
                txtYearBuilt.Text      = string.Empty;
                txtBedrooms.Text       = string.Empty;
                txtBathrooms.Text      = string.Empty;
                txtMarketValue.Text    = string.Empty;
    
                lblPictureFile.Text    = "C:\\Altair Realtors\\Generic3.png";
                pbxProperty.Image      = Image.FromFile("C:\\Altair Realtors\\Generic3.png");
    
                Width                  = pbxProperty.Right  + 40;
                Height                 = pbxProperty.Bottom + 75;
            }
    
            public void ShowProperty(string propNbr)
            {
                if (propNbr is null)
                    return;
    
                Property residence = new();
                residence.PropertyNumber = propNbr;
    
                LinkedList<Property> properties;
                string strFileName = "C:\\Altair Realtors\\Properties.json";
    
                if (File.Exists(strFileName) == true)
                {
                    string strProperties = strProperties = File.ReadAllText(strFileName);
                    properties = JsonSerializer.Deserialize<LinkedList<Property>>(strProperties)!;
    
                    LinkedListNode<Property> property = properties.Find(residence)!;
    
                    if (residence is not null)
                    {
                        txtPropertyNumber.Text = propNbr;
                        txtPropertyType.Text   = property.Value.PropertyType;
                        txtAddress.Text        = property.Value.Address;
                        txtCity.Text           = property.Value.City;
                        txtState.Text          = property.Value.State;
                        txtZIPCode.Text        = property.Value.ZIPCode;
                        txtStories.Text        = property.Value.Stories.ToString();
                        txtYearBuilt.Text      = property.Value.YearBuilt.ToString();
                        txtBedrooms.Text       = property.Value.Bedrooms.ToString();
                        txtBathrooms.Text      = property.Value.Bathrooms.ToString("f");
                        txtCondition.Text      = property.Value.Condition;
                        txtSaleStatus.Text     = property.Value.SaleStatus;
                        txtMarketValue.Text    = property.Value.MarketValue.ToString("f");
                        lblPictureFile.Text    = property.Value.PictureFile;
    
                        pbxProperty.Image      = Image.FromFile(property.Value.PictureFile!);
    
                        Width                  = pbxProperty.Right + 40;
                        Height                 = pbxProperty.Bottom + 75;
                    }
                }
            }
    
            private void PropertyDelete_Load(object sender, EventArgs e)
            {
                lblPictureFile.Text = "E:\\Altair Realtors\\Generic3.png";
                pbxProperty.Image = Image.FromFile("E:\\Altair Realtors\\Generic3.png");
    
                Width = pbxProperty.Right + 40;
                Height = pbxProperty.Bottom + 75;
            }
    
            private void btnFind_Click(object sender, EventArgs e)
            {
                if (string.IsNullOrEmpty(txtPropertyNumber.Text))
                {
                    MessageBox.Show("You must enter a property number.",
                                    "Altair Realtors", MessageBoxButtons.OK, MessageBoxIcon.Information);
                    return;
                }
    
                ShowProperty(txtPropertyNumber.Text);
            }
    
            private void btnDeleteProperty_Click(object sender, EventArgs e)
            {
                if (string.IsNullOrEmpty(txtPropertyNumber.Text))
                {
                    MessageBox.Show("You must enter a property number.",
                                    "Altair Realtors", MessageBoxButtons.OK, MessageBoxIcon.Information);
                    return;
                }
    
                LinkedList<Property> properties;
                string strFileName = "C:\\Altair Realtors\\Properties.json";
    
                Property residence = new()
                {
                    PropertyNumber = txtPropertyNumber.Text
                };
    
                if (File.Exists(strFileName) == true)
                {
                    string strProperties = File.ReadAllText(strFileName);
                    properties = JsonSerializer.Deserialize<LinkedList<Property>>(strProperties)!;
    
                    LinkedListNode<Property> property = properties.Find(residence)!;
    
                    if (residence is not null)
                    {
                        properties.Remove(property);
    
                        JsonSerializerOptions options = new JsonSerializerOptions();
                        options.WriteIndented = true;
    
                        string jsProperties = JsonSerializer.Serialize(properties, typeof(LinkedList<Property>), options);
                        File.WriteAllText(strFileName, jsProperties);
                    }
    
                    ResetProperty();
                }
            }
    
            private void btnClose_Click(object sender, EventArgs e)
            {
                Close();
            }
        }
    }

Reviewing the Real Estate Properties

One of the most valuable functionalities of a linked list is that items of the list are linked. This allows you to navigate easily from one record to another. We will provided this functionality in our application.

Practical LearningPractical Learning: Introducing Linked Lists

  1. To create a new form, on the main menu, click Project -> Add Form (Windows Forms...)
  2. Set the Name to PropertiesReview
  3. Click Add
  4. Resize the form to have approximately the same dimensions as the Property Editor form
  5. Copy the controls from the Property Editor form and paste them in the Properties Review form
  6. Delete the three combo boxes on the form. Replace them with text boxes
  7. Complete the design of the Property Delete form as follows:

    New Project

    Control (Name) Text
    TextBox Text Box txtPropertyType  
    TextBox Text Box txtCondition  
    TextBox Text Box txtSaleStatus  
    Button btnFirst First
    Button btnPrevious Previous
    Label Label lblRecordNumber 000 of 000
    Button btnNext Next
    Button btnLast Last
    Button btnClose Close
  8. Double-click an unoccupied area of the form
  9. Return to the Properties Review form and double-click the First button
  10. Return to the Properties Review form and double-click the Previous button
  11. Return to the Properties Review form and double-click the Next button
  12. Return to the Propertied Review form and double-click the Last button
  13. Return to the Properties Review form and double-click the Close button
  14. Change the document as follows:
    using System.Text.Json;
    
    namespace AltairRealtors
    {
        public partial class PropertiesReview : Form
        {
            int index;
            LinkedList<Property> Properties { get; set; } = new LinkedList<Property>();
            LinkedListNode<Property>? Current;
    
            public PropertiesReview()
            {
                InitializeComponent();
            }
    
            private void PropertiesReview_Load(object sender, EventArgs e)
            {
                string strFileName = "C:\\Altair Realtors\\Properties.json";
    
                if (File.Exists(strFileName) == true)
                {
                    string strProperties = File.ReadAllText(strFileName);
                    Properties           = JsonSerializer.Deserialize<LinkedList<Property>>(strProperties)!;
    
                    btnFirst_Click(sender, e);
                }
            }
    
            private void btnFirst_Click(object sender, EventArgs e)
            {
                index                  = 1;
                Current                = Properties.First!;
    
                txtPropertyNumber.Text = Current.Value.PropertyNumber;
                txtPropertyType.Text   = Current.Value.PropertyType;
                txtAddress.Text        = Current.Value.Address;
                txtCity.Text           = Current.Value.City;
                txtState.Text          = Current.Value.State;
                txtZIPCode.Text        = Current.Value.ZIPCode;
                txtStories.Text        = Current.Value.Stories.ToString();
                txtYearBuilt.Text      = Current.Value.YearBuilt.ToString();
                txtBedrooms.Text       = Current.Value.Bedrooms.ToString();
                txtBathrooms.Text      = Current.Value.Bathrooms.ToString("F");
                txtCondition.Text      = Current.Value.Condition;
                txtSaleStatus.Text     = Current.Value.SaleStatus;
                txtMarketValue.Text    = Current.Value.MarketValue.ToString("F");
    
                if (Current.Value.PictureFile is null)
                {
                    lblPictureFile.Text = "C:\\Altair Realtors\\Generic3.png";
                    pbxProperty.Image   = Image.FromFile("C:\\Altair Realtors\\Generic3.png");
                }
                else
                {
                    lblPictureFile.Text = Current.Value.PictureFile;
                    pbxProperty.Image   = Image.FromFile(Current.Value.PictureFile);
                }
    
                Width  = pbxProperty.Right  + 40;
                Height = pbxProperty.Bottom + 75;
            }
    
            private void btnPrevious_Click(object sender, EventArgs e)
            {
                index--;
    
                if (index <= 1)
                    btnFirst_Click(sender, e);
                else
                {
                    Current                = Current?.Previous!;
    
                    txtPropertyNumber.Text = Current?.Value.PropertyNumber;
                    txtPropertyType.Text   = Current?.Value.PropertyType;
                    txtAddress.Text        = Current?.Value.Address;
                    txtCity.Text           = Current?.Value.City;
                    txtState.Text          = Current?.Value.State;
                    txtZIPCode.Text        = Current?.Value.ZIPCode;
                    txtStories.Text        = Current?.Value.Stories.ToString();
                    txtYearBuilt.Text      = Current?.Value.YearBuilt.ToString();
                    txtBedrooms.Text       = Current?.Value.Bedrooms.ToString();
                    txtBathrooms.Text      = Current?.Value.Bathrooms.ToString("F");
                    txtCondition.Text      = Current?.Value.Condition;
                    txtSaleStatus.Text     = Current?.Value.SaleStatus;
                    txtMarketValue.Text    = Current?.Value.MarketValue.ToString("F");
    
                    if (Current?.Value.PictureFile is null)
                    {
                        lblPictureFile.Text = "C:\\Altair Realtors\\Generic3.png";
                        pbxProperty.Image   = Image.FromFile("C:\\Altair Realtors\\Generic3.png");
                    }
                    else
                    {
                        lblPictureFile.Text = Current.Value.PictureFile;
                        pbxProperty.Image   = Image.FromFile(Current.Value.PictureFile);
                    }
    
                    Width  = pbxProperty.Right  + 40;
                    Height = pbxProperty.Bottom + 75;
                }
            }
    
            private void btnNext_Click(object sender, EventArgs e)
            {
                index++;
    
                if (index >= Properties.Count)
                    btnLast_Click(sender, e);
                else
                {
                    Current                = Current?.Next;
    
                    txtPropertyNumber.Text = Current?.Value.PropertyNumber;
                    txtPropertyType.Text   = Current?.Value.PropertyType;
                    txtAddress.Text        = Current?.Value.Address;
                    txtCity.Text           = Current?.Value.City;
                    txtState.Text          = Current?.Value.State;
                    txtZIPCode.Text        = Current?.Value.ZIPCode;
                    txtStories.Text        = Current?.Value.Stories.ToString();
                    txtYearBuilt.Text      = Current?.Value.YearBuilt.ToString();
                    txtBedrooms.Text       = Current?.Value.Bedrooms.ToString();
                    txtBathrooms.Text      = Current?.Value.Bathrooms.ToString("F");
                    txtCondition.Text      = Current?.Value.Condition;
                    txtSaleStatus.Text     = Current?.Value.SaleStatus;
                    txtMarketValue.Text    = Current?.Value.MarketValue.ToString("F");
    
                    if (Current?.Value.PictureFile is null)
                    {
                        lblPictureFile.Text = "C:\\Altair Realtors\\Generic3.png";
                        pbxProperty.Image   = Image.FromFile("C:\\Altair Realtors\\Generic3.png");
                    }
                    else
                    {
                        lblPictureFile.Text = Current.Value.PictureFile;
                        pbxProperty.Image   = Image.FromFile(Current.Value.PictureFile);
                    }
    
                    Width  = pbxProperty.Right  + 40;
                    Height = pbxProperty.Bottom + 75;
                }
            }
    
            private void btnLast_Click(object sender, EventArgs e)
            {
                index                  = Properties.Count;
                Current                = Properties.Last;
    
                txtPropertyNumber.Text = Current?.Value.PropertyNumber;
                txtPropertyType.Text   = Current?.Value.PropertyType;
                txtAddress.Text        = Current?.Value.Address;
                txtCity.Text           = Current?.Value.City;
                txtState.Text          = Current?.Value.State;
                txtZIPCode.Text        = Current?.Value.ZIPCode;
                txtStories.Text        = Current?.Value.Stories.ToString();
                txtYearBuilt.Text      = Current?.Value.YearBuilt.ToString();
                txtBedrooms.Text       = Current?.Value.Bedrooms.ToString();
                txtBathrooms.Text      = Current?.Value.Bathrooms.ToString("F");
                txtCondition.Text      = Current?.Value.Condition;
                txtSaleStatus.Text     = Current?.Value.SaleStatus;
                txtMarketValue.Text    = Current?.Value.MarketValue.ToString("F");
    
                if (Current?.Value.PictureFile is null)
                {
                    lblPictureFile.Text = "C:\\Altair Realtors\\Generic3.png";
                    pbxProperty.Image   = Image.FromFile("C:\\Altair Realtors\\Generic3.png");
                }
                else
                {
                    lblPictureFile.Text = Current.Value.PictureFile;
                    pbxProperty.Image   = Image.FromFile(Current.Value.PictureFile);
                }
    
                Width  = pbxProperty.Right  + 40;
                Height = pbxProperty.Bottom + 75;
            }
    
            private void btnClose_Click(object sender, EventArgs e)
            {
                Close();
            }
        }
    }

Presenting the Application

Of course the most fundamental aspect of an application is to be presented to the user. This is usually done from the main form. In the central form of our application, we will create various links that can lead the user to other forms of the application. The central form is alwo used to display the list of the real estate properties of our application

Practical LearningPractical Learning: Presenting the Application

  1. In the Solution Explorer, right-click Form1.cs and click Rename
  2. Type PropertiesListing (to get PropertiesListing.cs) and press Enter twice
  3. Click the body of the form to make sure it is selected.
    In the Properties window, change the following characteristics of the form:
    Text: Altair Realtors - Properties Listing
    StartPosition: CenterScreen
  4. In the Menus & Toolbars section of the Toolbox, click ContextMenuStrip and click the form
  5. Click the menu items as follows:
     
    (Name) Enabled Text
    mnuAddProperty   Add Real Estate Property...
        -
    mnuInsertBefore False Insert New Property Before...
    mnuInsertAfter False Insert New Property After...
        -
    mnuEditProperty False Edit Real Estate Property...
    mnuDeleteProperty False Delete/Remove Property...
  6. In the Toolbox, click ListView and click the form
  7. On the form, right-click the list view and click Edit Columns...
  8. Create the columns as follows:
     
    (Name) Text TextAlign Width
    colPropertyNumber Property #   100
    colCity City   125
    colStories Stories Right 65
    colBedrooms Beds Right 50
    colBathrooms Baths Right 60
    colYearBuilt Year Right 60
    colCondition Condition   125
    colMarketValue Value Right 125
    colSaleStatus Status   100
  9. Click OK
  10. Right-click the list view on the form and click Edit Groups...
  11. Create the groups as follows:
     
    Header Name
    Condominium lvgCondominium
    Townhouse lvgTownhouse
    Single Family lvgSingleFamily
  12. Click OK
  13. Design the form as follows:
     

    Altair Realtors - Properties Review

    Control (Name) Text Other Properties
    ListView List View lvwProperties   ContextMenuStrip: cmsProperties
    PictureBox Picture Box pbxPicture   BorderStyle: Fixed3D
    SizeMode: AutoSize
    Button btnNewProperty New Real Estate Property...  
    Button btnUpdatePropertyDetails Update Property Details...  
    Button btnDeleteOrRemoveProperty Delete/Remove Property...  
    Button btnPropertiesReview Properties Review...  
    Button btnClose Close   
  14. Double-click an unoccupied area of the Altair Realtors - Properties Listing form to generate its Load event
  15. Return to the Properties Listing form and click the list view
  16. In the Properties window, click the Events button Events
  17. In the Events section of the Properties window, double-click ItemSelectionChanged
  18. Return to the Properties Listing form and make sure the list view is still selected
  19. In the Events section of the Properties window, double-click DoubleClick
  20. Return to the Properties Listing form and, on the form, double-click the New Real Estale Property button
  21. Return to the Properties Listing form and, on the form, double-click the Update Property Details button
  22. Return to the Properties Listing form and, on the form, double-click the Delete/Remove Property button
  23. Return to the Properties Listing form and, below the form, click cmsProperties
  24. On the form, under ContextMenuStrip, double-click Add Real Estate Property...
  25. Return to the Properties Listing form and, under ContextMenuStrip, double-click Insert New Property Before...
  26. Return to the Properties Listing form and, under ContextMenuStrip, double-click Insert New Property After...
  27. Return to the Properties Listing form and, under ContextMenuStrip, double-click Edit Real Estate Property...
  28. Return to the Properties Listing form and, under ContextMenuStrip, double-click Delete/Remove Property...
  29. Return to the Properties Listing form and, on the form, double-click the Properties Review button
  30. Return to the Properties Listing form and double-click the Close button
  31. Change the document as follows:
    using System.Text.Json;
    
    namespace AltairRealtors
    {
        public enum Insertion { Before, After, Unknown }
    
        public partial class PropertiesListing : Form
        {
            public PropertiesListing()
            {
                InitializeComponent();
            }
    
            private void InitializePropertiesListing()
            {
                string strFileName = "C:\\Altair Realtors\\Properties.json";
                LinkedList<Property> properties;
    
                // Make sure the file exists
                if (File.Exists(strFileName) == true)
                {
                    string strProperties = File.ReadAllText(strFileName);
                    properties           = JsonSerializer.Deserialize<LinkedList<Property>>(strProperties)!;
    
                    // First, empty the list view
                    lvwProperties.Items.Clear();
                    ListViewItem lviProperty;
    
                    // Visit each property in the collection and add it to the list view
                    foreach (Property house in properties)
                    {
                        if (house!.PropertyType!.Equals("Condominium"))
                            lviProperty = new ListViewItem(house.PropertyNumber, lvwProperties.Groups[0]);
                        else if (house.PropertyType.Equals("Townhouse"))
                            lviProperty = new ListViewItem(house.PropertyNumber, lvwProperties.Groups[1]);
                        else // if (house.PropertyType.Equals("Single Family"))
                            lviProperty = new ListViewItem(house.PropertyNumber, lvwProperties.Groups[2]);
    
                        lviProperty.SubItems.Add(house.City);
                        lviProperty.SubItems.Add(house.Stories.ToString());
                        lviProperty.SubItems.Add(house.Bedrooms.ToString());
                        lviProperty.SubItems.Add(house.Bathrooms.ToString("F"));
                        lviProperty.SubItems.Add(house.YearBuilt.ToString());
                        lviProperty.SubItems.Add(house.Condition);
                        lviProperty.SubItems.Add(house.SaleStatus);
                        lviProperty.SubItems.Add(house.MarketValue.ToString());
                        lviProperty.SubItems.Add(house.PictureFile);
                        lvwProperties.Items.Add(lviProperty);
                    }
                }
    
                pbxProperty.Image = Image.FromFile("C:\\Altair Realtors\\Generic.png");
    
                Width  = pbxProperty.Right  + 40;
                Height = pbxProperty.Bottom + 75;
            }
    
            private void PropertiesListing_Load(object sender, EventArgs e)
            {
                InitializePropertiesListing();
            }
    
            private void lvwProperties_ItemSelectionChanged(object sender, ListViewItemSelectionChangedEventArgs e)
            {
                if(lvwProperties.SelectedItems.Count == 0)
                    return;
    
                string strFileName = "C:\\Altair Realtors\\Properties.json";
                LinkedList<Property> properties;
    
                if (File.Exists(strFileName) == true)
                {
                    string strProperties = File.ReadAllText(strFileName);
                    properties = JsonSerializer.Deserialize<LinkedList<Property>>(strProperties)!;
    
                    foreach (Property house in properties)
                    {
                        if (house.PropertyNumber!.Equals(lvwProperties.SelectedItems[0]!.Text))
                        {
                            pbxProperty.Image = Image.FromFile(house.PictureFile!);
    
                            Width = pbxProperty.Right + 40;
                            Height = pbxProperty.Bottom + 75;
                            break;
                        }
                    }
                }
    
                if (lvwProperties.SelectedItems.Count == 1)
                {
                    mnuInsertBefore.Enabled   = true;
                    mnuEditProperty.Enabled   = true;
                    mnuInsertAfter.Enabled    = true;
                    mnuDeleteProperty.Enabled = true;
                }
                else
                {
                    mnuInsertBefore.Enabled   = false;
                    mnuEditProperty.Enabled   = false;
                    mnuInsertAfter.Enabled    = false;
                    mnuDeleteProperty.Enabled = false;
                }
            }
    
            private void lvwProperties_DoubleClick(object sender, EventArgs e)
            {
                PropertyEditor pe = new();
    
                pe.ShowProperty(lvwProperties.SelectedItems[0].Text);
    
                pe.ShowDialog();
    
                InitializePropertiesListing();
            }
    
            private void btnNewProperty_Click(object sender, EventArgs e)
            {
                PropertyNew pn = new PropertyNew();
    
                pn.ShowDialog();
    
                InitializePropertiesListing();
            }
    
            private void btnUpdatePropertyDetails_Click(object sender, EventArgs e)
            {
                PropertyEditor pe = new PropertyEditor();
    
                pe.ShowDialog();
    
                InitializePropertiesListing();
            }
    
            private void btnDeleteOrRemoveProperty_Click(object sender, EventArgs e)
            {
                PropertyDelete pd = new();
    
                pd.ShowDialog();
    
                InitializePropertiesListing();
            }
    
            private void mnuAddProperty_Click(object sender, EventArgs e)
            {
                btnNewProperty_Click(sender, e);
    
                InitializePropertiesListing();
            }
    
            private void InsertProperty(Insertion decision)
            {
                LinkedList<Property> properties = new();
                LinkedListNode<Property>? existing = null;
                string strFileName = "C:\\Altair Realtors\\Properties.json";
    
                Property selected = new();
                selected.PropertyNumber = lvwProperties.SelectedItems[0].Text;
    
                if (File.Exists(strFileName) == true)
                {
                    string strProperties = strProperties = File.ReadAllText(strFileName);
                    properties = JsonSerializer.Deserialize<LinkedList<Property>>(strProperties)!;
    
                    existing = properties.Find(selected)!;
                }
                
                PropertyInsert pi = new PropertyInsert();
                Random rndNumber = new Random(DateTime.Now.Millisecond);
                
                pi.txtNewPropertyNumber.Text = rndNumber.Next(100000, 999999).ToString();
                pi.txtExistingPropertyNumber.Text = lvwProperties.SelectedItems[0].Text;
                pi.txtPropertyType.Text = lvwProperties.SelectedItems[0].Group.ToString();
    
                if (decision == Insertion.Before)
                {
                    pi.Text = "Altair Realtors - Property Insertion - Before";
                    pi.btnInsertProperty.Text = "Insert Property Before [" + lvwProperties.SelectedItems[0].Text + "]";
                }
                else
                {
                    pi.Text = "Altair Realtors - Property Insertion - After";
                    pi.btnInsertProperty.Text = "Insert Property After [" + lvwProperties.SelectedItems[0].Text + "]";
                }
    
                
                if (pi.ShowDialog() == DialogResult.OK)
                {
                    Property residence = new();
    
                    residence.PropertyNumber = pi.txtNewPropertyNumber.Text;
                    residence.PropertyType   = pi.txtPropertyType.Text;
                    residence.Address        = pi.txtAddress.Text;
                    residence.City           = pi.txtCity.Text;
                    residence.State          = pi.txtState.Text;
                    residence.ZIPCode        = pi.txtZIPCode.Text;
                    residence.Stories        = short.Parse(pi.txtStories.Text);
                    residence.YearBuilt      = int.Parse(pi.txtYearBuilt.Text);
                    residence.Bedrooms       = short.Parse(pi.txtBedrooms.Text);
                    residence.Bathrooms      = float.Parse(pi.txtBathrooms.Text);
                    residence.Condition      = pi.cbxConditions.Text;
                    residence.SaleStatus     = pi.cbxSaleStatus.Text;
                    residence.MarketValue    = double.Parse(pi.txtMarketValue.Text);
                    residence.PictureFile    = pi.lblPictureFile.Text;
    
                    if(decision == Insertion.Before)
                    {
                        properties.AddBefore(existing!, residence);
                    }
                    else
                    {
                        properties.AddAfter(existing!, residence);
                    }
    
                    JsonSerializerOptions options = new JsonSerializerOptions();
                    options.WriteIndented = true;
    
                    string jsProperties = JsonSerializer.Serialize(properties, typeof(LinkedList<Property>), options);
                    File.WriteAllText(strFileName, jsProperties);
                }
    
                InitializePropertiesListing();
            }
    
            private void mnuInsertBefore_Click(object sender, EventArgs e)
            {
                InsertProperty(Insertion.Before);
    
                InitializePropertiesListing();
            }
    
            private void mnuInsertAfter_Click(object sender, EventArgs e)
            {
                InsertProperty(Insertion.After);
    
                InitializePropertiesListing();
            }
    
            private void mnuEditProperty_Click(object sender, EventArgs e)
            {
                lvwProperties_DoubleClick(sender, e);
    
                InitializePropertiesListing();
            }
    
            private void mnuDeleteProperty_Click(object sender, EventArgs e)
            {
                PropertyDelete pd = new();
    
                pd.ShowProperty(lvwProperties.SelectedItems[0].Text);
    
                pd.ShowDialog();
    
                InitializePropertiesListing();
            }
    
            private void btnPropertiesReview_Click(object sender, EventArgs e)
            {
                PropertiesReview pr = new PropertiesReview();
                
                pr.ShowDialog();
            }
    
            private void btnClose_Click(object sender, EventArgs e)
            {
                Close();
            }
        }
    }

Executing and Testing the Application

After creating the project, you can test it with sample values and operations.

Practical LearningPractical Learning: Executing and Testing the Application

  1. To execute, on the main menu, click Debug and click Start Without Debugging:

    Altair Realtors - Properties Listing

  2. Click the New Real Estate Property button:

    Altair Realtors - Properties Listing

  3. Close the New Real Estate form
  4. Right-click the form and click the Add Real Estate Property option:

    Altair Realtors - Properties Listing

  5. Use any of those options to create some properties as follows:

    Altair Realtors - New Property

    Property # Property Type Address City State ZIP Code Stories Bedrooms Bathrooms Year Built Condition Market Value Sale Status Picture File
    770686 Single Family 4288 Lucow Drive Rockville Maryland 20856 3 5 3.5 1988 Excellent 665580 Available Single-Family-5
    250351 Townhouse 719 Beanson Road Arlington Virginia 22201 4 4 3.5 1995 Good Shape 580795 Sold Townhouse-4
    264649 Condominium 6662 16th Street NW Washington DC 20012 2 1 1 1984 Good Shape 325775 Available Building-3
    975700 Single Family 39 Anesta Court Gettysburg Pennsylvania 17325 2 3 2.5 1988 Excellent 665580 Available Single-Family-4
    575370 Condominium 10574 Spring Floor Road Hinesville Georgia 31313 4 2 2 2014 Good Shape 235775 Available Building-2
    747575 Townhouse 228 South Gather Street Blanchard Oklahoma 73010 3 4 3.5 2020 Excellent 380795 Sold Townhouse-2
    375705 Single Family 8604 Bridge Stone Avenue Brecken Ridge Colorado 80824 3 3 4.5 2022 Unknown 655800 Available Single-Family-1
    886868 Condominium 2644 Swanson Drive Charleston West Virginia 25301 4 3 2 2004 Good Shape 225450 Available Building-4
    694708 Single Family 508 North Harrison Street Papillion Nebraska 68046 2 4 2.5 1986 Unknown 352500 Sold Single-Family-3
    164086 Townhouse 4220 Melmann Drive Baltimore Maryland 21206 3 3 2.5 1982 Needs Remodeling 325970 Available Townhouse-1
    369359 Single Family 8905 Mandarin Road McLean Virginia 22102 3 5 3.5 1992 Unknown 785680 Available Single-Family-6
    864968 Townhouse 2428 Connecticut Avenue Washington DC 20008 3 3 2.5 2015 Needs Remodeling 385600 Sold Townhouse-3
    557357 Single Family 10202 Lockwood Ave Sherman Illinois 62684 3 5 3.5 2022 Under Construction 675880 Sold Single-Family-2
    288206 Condominium 808D Green Tree Road Arbovale West Virginia 24915 3 1 1 2006 Unknown 216925 Available Building-1

    Altair Realtors - New Property

  6. From the Properties Listing form

    Altair Realtors - New Property

    Click Update Property Details
  7. In the Property # text box, type 375705
  8. Click Find

    Altair Realtors - Property Update

  9. Change the values as follows:
    City: Breckenridge
    ZIP Code: 80424
    Bedrooms: 6
    Condition: Needs Remodeling
    Market Value: 465580
    Status: Available
  10. Click Update Property Information and close the form

    Altair Realtors - New Property

  11. In the Townhouse section of the Properties Listing form, right-click the record that starts with the 164086 property number and click Insert New Property Before...

    Altair Realtors - Insert New Property Before

  12. Specify the values as follows:
    Property #: 497520
    Address: 4412 Jeffers Road
    City: Rock Springs
    State: Wyoming
    ZIP Code: 82901
    Stories: 2
    Bedrooms: 3
    Bathrooms: 2.5
    Year Built: 2020
    Condition: Excellent
    Market Value: 238664
    Status: Available
    Picture File: Townhouse-3
  13. Click Insert Property Before [164086]
  14. In the Single-Family section of the Properties Listing form, right-click the record that starts with the 694708 property number and click Insert New Property After...
  15. Specify the values as follows:
    Property #: 268473
    Address: 779 Cedar Plot Street
    City: Scottsdale
    State: Arizona
    ZIP Code: 85251
    Stories: 3
    Bedrooms: 5
    Bathrooms: 3.5
    Year Built: 2016
    Condition: Good Shape
    Market Value: 427992
    Status: Available
    Picture File: Single-Family-7
  16. Click Insert Property After [694708]
  17. Close the form and return to your programming environment
  18. Close your programming environment

Home Copyright © 2014-2023, FunctionX Friday 09 December 2022 Home