Solved

Create a dataset from a bo.

Posted on 2009-05-03
2
196 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

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

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

Lots of people ask this question on how to extend the “MembershipProvider” to make use of custom authentication like using existing database or make use of some other way of authentication. Many blogs show you how to extend the membership provider c…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

756 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