Solved

Create a dataset from a bo.

Posted on 2009-05-03
2
199 Views
Last Modified: 2012-05-06
I have a bo.

  public class Ticket
    {


        private int? ticketID = 0;
        private string ticketNumber = "";
        private string ticketType = "";
        private string ticketStatus = "";
        private string ticketSeverity = "";
        private string shortDescription = "";
        private string externalTicket = "";
        private string reasonMenu = "";
        private string problemNote = "";
        private string solutionNote = "";
        private string actionNote = "";
        private string followupNote = "";
        private bool? companiesFlag = false;
        private string agentCreated = "";
        private DateTime? dateCreated = System.DateTime.Now;
        private DateTime? dateLastModified = System.DateTime.Now;
        private string agentClosed = "";
        private DateTime? dateClosed = System.DateTime.Now;
        private string agentFollowup = "";
        private DateTime? followupBy = System.DateTime.Now;
        private bool? deletedFlag = false;
        private string ticketTypeOld = "";
        private string assignedTo = "";
        private string requestType = "";
        private string serviceImpact = "";
        private DateTime? dateTimeAssigned = System.DateTime.Now;
        private string priority = "";
        private DateTime? dateAssigned = System.DateTime.Now;
        private string trackIt = "";
        private string contactMethod = "";
        private string locationSIMs = "";
        private string userID = "";
        private string ticketApplicationType = "";
        private int? accountID = 0;

        #region Properties
        public System.Int32? TicketID
        {
            get
            {
                return ticketID;
            }
            set
            {
                ticketID = value;
            }
        }

        public System.String TicketNumber
        {
            get
            {
                return ticketNumber;
            }
            set
            {
                ticketNumber = value;
            }
        }

        public System.String TicketType
        {
            get
            {
                return ticketType;
            }
            set
            {
                ticketType = value;
            }
        }

        public System.String TicketStatus
        {
            get
            {
                return ticketStatus;
            }
            set
            {
                ticketStatus = value;
            }
        }

        public System.String TicketSeverity
        {
            get
            {
                return ticketSeverity;
            }
            set
            {
                ticketSeverity = value;
            }
        }

        public System.String ShortDescription
        {
            get
            {
                return shortDescription;
            }
            set
            {
                shortDescription = value;
            }
        }

        public System.String ExternalTicket
        {
            get
            {
                return externalTicket;
            }
            set
            {
                externalTicket = value;
            }
        }

        public System.String ReasonMenu
        {
            get
            {
                return reasonMenu;
            }
            set
            {
                reasonMenu = value;
            }
        }

        public System.String ProblemNote
        {
            get
            {
                return problemNote;
            }
            set
            {
                problemNote = value;
            }
        }

        public System.String SolutionNote
        {
            get
            {
                return solutionNote;
            }
            set
            {
                solutionNote = value;
            }
        }

        public System.String ActionNote
        {
            get
            {
                return actionNote;
            }
            set
            {
                actionNote = value;
            }
        }

        public System.String FollowupNote
        {
            get
            {
                return followupNote;
            }
            set
            {
                followupNote = value;
            }
        }

        public System.Boolean? CompaniesFlag
        {
            get
            {
                return companiesFlag;
            }
            set
            {
                companiesFlag = value;
            }
        }

        public System.String AgentCreated
        {
            get
            {
                return agentCreated;
            }
            set
            {
                agentCreated = value;
            }
        }

        public System.DateTime? DateCreated
        {
            get
            {
                return dateCreated;
            }
            set
            {
                dateCreated = value;
            }
        }

        public System.DateTime? DateLastModified
        {
            get
            {
                return dateLastModified;
            }
            set
            {
                dateLastModified = value;
            }
        }

        public System.String AgentClosed
        {
            get
            {
                return agentClosed;
            }
            set
            {
                agentClosed = value;
            }
        }

        public System.DateTime? DateClosed
        {
            get
            {
                return dateClosed;
            }
            set
            {
                dateClosed = value;
            }
        }

        public System.String AgentFollowup
        {
            get
            {
                return agentFollowup;
            }
            set
            {
                agentFollowup = value;
            }
        }

        public System.DateTime? FollowupBy
        {
            get
            {
                return followupBy;
            }
            set
            {
                followupBy = value;
            }
        }

        public System.Boolean? DeletedFlag
        {
            get
            {
                return deletedFlag;
            }
            set
            {
                deletedFlag = value;
            }
        }

        public System.String TicketTypeOld
        {
            get
            {
                return ticketTypeOld;
            }
            set
            {
                ticketTypeOld = value;
            }
        }

        public System.String AssignedTo
        {
            get
            {
                return assignedTo;
            }
            set
            {
                assignedTo = value;
            }
        }

        public System.String RequestType
        {
            get
            {
                return requestType;
            }
            set
            {
                requestType = value;
            }
        }

        public System.String ServiceImpact
        {
            get
            {
                return serviceImpact;
            }
            set
            {
                serviceImpact = value;
            }
        }

        public System.DateTime? DateTimeAssigned
        {
            get
            {
                return dateTimeAssigned;
            }
            set
            {
                dateTimeAssigned = value;
            }
        }

        public System.String Priority
        {
            get
            {
                return priority;
            }
            set
            {
                priority = value;
            }
        }

        public System.DateTime? DateAssigned
        {
            get
            {
                return dateAssigned;
            }
            set
            {
                dateAssigned = value;
            }
        }

        public System.String TrackIt
        {
            get
            {
                return trackIt;
            }
            set
            {
                trackIt = value;
            }
        }

        public System.String ContactMethod
        {
            get
            {
                return contactMethod;
            }
            set
            {
                contactMethod = value;
            }
        }

        public System.String LocationSIMs
        {
            get
            {
                return locationSIMs;
            }
            set
            {
                locationSIMs = value;
            }
        }

        public System.String UserID
        {
            get
            {
                return userID;
            }
            set
            {
                userID = value;
            }
        }

        public System.String TicketApplicationType
        {
            get
            {
                return ticketApplicationType;
            }
            set
            {
                ticketApplicationType = value;
            }
        }

        public System.Int32? AccountID
        {
            get
            {
                return accountID;
            }
            set
            {
                accountID = value;
            }
        }
       
        #endregion
           
        #region "constructors"

        public Ticket(
            System.Int32  TicketID,
            System.String TicketNumber,
            System.String TicketType,
            System.String TicketStatus,
            System.String ticketSeverity,
            System.String shortDescription,
            System.String externalTicket,
            System.String reasonMenu,
            System.String problemNote,
            System.String solutionNote,
            System.String actionNote,
            System.String followupNote,
            System.Boolean? companiesFlag,
            System.String agentCreated,
            System.DateTime? dateCreated,
            System.DateTime? dateLastModified,
            System.String agentClosed,
            System.DateTime? dateClosed,
            System.String agentFollowup,
            System.DateTime? followupBy,
            System.Boolean? deletedFlag,
            System.String ticketTypeOld,
            System.String assignedTo,
            System.String requestType,
            System.String serviceImpact,
            System.DateTime? dateTimeAssigned,
            System.String priority,
            System.DateTime? dateAssigned,
            System.String trackIt,
            System.String contactMethod,
            System.String locationSIMs,
            System.String userID,
            System.String ticketApplicationType,
            System.Int32? accountID)
          {
                ticketID = TicketID;
                ticketNumber = TicketNumber;
                ticketType = TicketType;
                ticketStatus = TicketStatus;
                ticketSeverity = TicketSeverity;
                shortDescription = ShortDescription;
                externalTicket = ExternalTicket;
                reasonMenu = ReasonMenu;
                problemNote = ProblemNote;
                solutionNote = SolutionNote;
                actionNote = ActionNote;
                followupNote = FollowupNote;
                companiesFlag = CompaniesFlag;
                agentCreated = AgentCreated;
                dateCreated = DateCreated;
                dateLastModified = DateLastModified;
                agentClosed = AgentClosed;
                dateClosed = DateClosed;
                agentFollowup = AgentFollowup;
                followupBy = FollowupBy;
                deletedFlag = DeletedFlag;
                ticketTypeOld = TicketTypeOld;
                assignedTo = AssignedTo;
                requestType = RequestType;
                serviceImpact = ServiceImpact;
                dateTimeAssigned = DateTimeAssigned;
                priority = Priority;
                dateAssigned = DateAssigned;
                trackIt = TrackIt;
                contactMethod = ContactMethod;
                locationSIMs = LocationSIMs;
                userID = UserID;
                ticketApplicationType = TicketApplicationType;
                accountID = AccountID;
       
        }
       
        #endregion

    }
}

======================================================================
I need to dataset from the above object.
0
Comment
Question by:mathieu_cupryk
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 9

Accepted Solution

by:
tillgeffken earned 500 total points
ID: 24289154
In order to receive help you may want to consider being a bit more verbose on your requirement. Explain what you're trying to do.

Where is your class getting its data from? What are you planning to do with the DataSet?
0
 

Author Comment

by:mathieu_cupryk
ID: 24290878
I plan to get the data from a form and then do an insert into the database using a DataSet using Enterprise Library.
0

Featured Post

MS Dynamics Made Instantly Simpler

Make Your Microsoft Dynamics Investment Count  & Drastically Decrease Training Time by Providing Intuitive Step-By-Step WalkThru Tutorials.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

IntroductionWhile developing web applications, a single page might contain many regions and each region might contain many number of controls with the capability to perform  postback. Many times you might need to perform some action on an ASP.NET po…
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
Suggested Courses

626 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question