Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8343659
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T06:08:00+00:00 2026-06-09T06:08:00+00:00

I have an application in which a user will be saving information that will

  • 0

I have an application in which a user will be saving information that will later be pulled up. Each ‘Trial’ will have its own XML file and within that XML file there will be specific events that are identified by an EventID and specific dogs competing in each event that will have their own DogID.

I need to find a way to check whether or not a specifric event or dog within a specific event has already been written to this file. Below is the code that will create this XML file for the very first time and then be updated when creates a specific event and dog for this file.

XmlWriter w = XmlWriter.Create(fs);

            w.WriteStartDocument();
            w.WriteStartElement("Event");
            for (int counter = 0; counter < registeredEventCount; counter++)
            {

                string eventString = registeredArrayList[counter].ToString();
                // eventString = eventString.Replace(" ", "");

                w.WriteStartElement("Event");
                w.WriteAttributeString("id", eventString);
                // Write a product.
                w.WriteStartElement("dogId");
                w.WriteElementString("eventID", eventSelectComboBox.SelectedItem.ToString());
                w.WriteElementString("ukcNumber", ukcDogNumTextBox.Text.ToString());
                w.WriteElementString("breed", breedTextBox.Text.ToString());
                w.WriteElementString("dogName", dogNameTextBox.Text.ToString());
                w.WriteEndElement();
                w.WriteEndElement();
            }

            w.WriteEndDocument();
            w.Flush();

Any suggestions? I am having trouble finding an effient way to check whether an event has already been created and a dog has already been created wihtin an event.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T06:08:01+00:00Added an answer on June 9, 2026 at 6:08 am

    Use a Dictionary or an HashedSet populated during the file writing, check that dictionary for the proper key in order to check if the dog / event is already “seen” and to skip it.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a web application which has several users and each user will have
I have to implement a iphone application which will record user's voice as you
I'm working on an application for iOS which will have the user fill out
Currently, I have an application, which will save a temporary screenshot, and let user
I have a textbox in my application in which user will enter where clause
I have the application in which user select the particular folder and all the
I have developed a application in which user select the particular folder and it
I have developed a application in which user select the particular folder and it
I have a web application in which a user has to upload images to
I have a simple web application which lets the user upload local user data

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.