CustomerQuery

Returns data for the specified customers.
Important: We highly recommend that you use the IncludeRetElement tag in your CustomerQuery to include any data you want but do NOT include the ShipAddress data in the Response, unless you need to get the shipping address for a particular customer. Excluding the shipping address data will significantly improve the performance of the CustomerQuery.

Request

Response

XMLOps

VB.NET

C#

Tag Type Max length Implementation Required

ICustomerQuery

Returns data for the specified customers.Important: We highly recommend that you use the IncludeRetElement tag in your CustomerQuery to include any data you want but do NOT include the ShipAddress data in the Response, unless you need to get the shipping address for a particular customer. Excluding the shipping address data will significantly improve the performance of the CustomerQuery.
       

metaData

This is used in a query to cause a count of query objects to be returned. You can specify that the count of query objects is to be returned with the returned objects, or you can specify that only a count and no data is returned. (The default is that no count is returned.) A common use of this feature is to specify a count with no data in order to determine how many objects to expect from the actual query. If you don’t want a query to return a count, either don’t use this feature, or specify the value NoMetaData. If you want only a count, specify the value MetaDataOnly. If you want data and a count, specify MetaDataAndResponseData. You should be aware that the count returned via this setting is not guaranteed to be exact: it could be off slightly due to new object creation or deletions.
IQBENmetaDataType   4.0 us.png  

iterator

The iterator attribute provided with most query types also allows you to break down query results in smaller and more manageable chunks of data. An iterator results in responses that contain only the specified number of objects. Iterators are only valid for the application that starts them, and they are only valid for the current QuickBooks session.
IQBENiteratorType   5.0 us.png  

iteratorID

Returned in the response in the first iteration and supplied in subsequent iterations, this identifies which iteration is to be used in the query continuing the iteration. Required because many different iterations may be currently in use.
IQBUUIDType   5.0 us.png  

ORCustomerListQuery

IORCustomerListQuery      

ListIDList

One or more ListID values. Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IBSTRList      

FullNameList

A list of one or more FullName values. FullName (along with ListID) is a way to identify a list object. The FullName is the name prefixed by the names of each ancestor, for example Jones:Kitchen:Cabinets. FullName values are not case-sensitive.
IBSTRList      

CustomerListFilter

The ICustomerListFilter group object allows you to search for customers based on whether they’re active, when their record was last modified, their name, and their total balance.
ICustomerListFilter      

MaxReturned

Limits the number of objects that a query returns. (To get a count of how many objects could possibly be returned, use the metaData query attribute.) If you include a MaxReturned value, it must be at least 1.
IQBIntType      

ActiveStatus

Used in filters to select list objects based on whether or not they are currently enabled for use by QuickBooks. The default value is asActiveOnly, which selects only list objects that are active.
IQBENActiveStatusType      

FromModifiedDate

Selects objects modified on or after this date. See the note below regarding QBFC usage.For desktop versions of QuickBooks, the FromModifiedDate and ToModifiedDate must be between 1970-01-01 and 2038-01-19T03:14:07 (2038-01-18T19:14:07-08:00 PST). (The time portion of the field was not supported in qbXML version 1.0 or 1.1.) Also, for desktop versions of QuickBooks, if FromModifiedDate includes a date but not a time (for example, if you set FromModifiedDate to 2003-02-14), the time is assumed to be zero (2003-02-14T00:00:00). If you omit FromModifiedDate, it will be set to 1970-01-01T00:00:00 (1969-12-31T16:00:00-08:00 PST).For QBOE, the FromModifiedDate and ToModifiedDate must be between 1900-01-01T00:00:00 and 9999-12-31T00:00:00. If FromModifiedDate includes a date but not a time (for example, if you set FromModifiedDate to 2003-02-14), the time is assumed to be zero (2003-02-14T00:00:00). If you omit FromModifiedDate, it will be set to 1900-01-01T00:00:00.Note: When specifying this in QBFC, you need to supply the parameter asDateOnly, which is a Boolean. If asDateOnly is true, the date value will be represented as a date only (without a time). If asDateOnly is false, the date value will be represented as date and time, padded with zeros if necessary, and set to the beginning of the day if no time is provided. The asDateOnly parameter is especially useful in the ToModifiedDate field of a query: If asDateOnly is set to true in the ToModifiedDate field of a query, then the query includes elements modified up to the end of the day. If asDateOnly is false, the query includes elements modified up to the specified time (or up to the beginning of the day if no time is included).
IQBDateTimeType      

ToModifiedDate

Selects objects modified on or before this date. See the note below on QBFC usage.For desktop versions of QuickBooks, the ToModifiedDate and FromModifiedDate must be between 01/01/1970 and 2038-01-19T03:14:07 (2038-01-18T19:14:07-08:00 PST). (Note that the time portion of the field was not supported in qbXML version 1.0 or 1.1.) If ToModifiedDate includes a date but not a time (for example, if you set ToModifiedDate to 2003-02-14), the time is assumed to be the end of the day (2003-02-14T23:59:59). If you omit ToModifiedDate altogether, it will be set to 2038-01-19T03:14:07 (2038-01-18T19:14:07-08:00 PST).For QBOE, the ToModifiedDate and FromModifiedDate must be between 01/01/1900 and 9999-12-31T00:00:00. If ToModifiedDate includes a date but not a time (for example, if you set ToModifiedDate to 2003-02-14), the time is assumed to be the end of the day (2003-02-14T23:59:59). If you omit ToModifiedDate altogether, it will be set to 9999-12-31T00:00:00.Note: When specifying this in QBFC, you need to supply the parameter asDateOnly, which is a Boolean. If asDateOnly is true, the date value will be represented as a date only (without a time). If asDateOnly is false, the date value will be represented as date and time, padded with zeros if necessary, and set to the beginning of the day if no time is provided. The asDateOnly parameter is especially useful in the ToModifiedDate field of a query: If asDateOnly is set to true in the ToModifiedDate field of a query, then the query includes elements modified up to the end of the day. If asDateOnly is false, the query includes elements modified up to the specified time (or up to the beginning of the day if no time is included).
IQBDateTimeType      

ORNameFilter

IORNameFilter      

NameFilter

Filters according to the object’s Name.
INameFilter      

MatchCriterion

The criterion to match.
IQBENMatchCriterionType     Y

Name

The string to match.
IQBStringType     Y

NameRangeFilter

Filters according to the object’s Name.
INameRangeFilter      

FromName

The first name or item in the search range. If FromName is omitted, the range will begin with first name on the list.
IQBStringType      

ToName

The final name or item in the search range. If ToName is omitted, the range will end with last name on the list.
IQBStringType      

TotalBalanceFilter

Filters according to total balance. Total balance includes the balance for all subaccounts; for example, a customer’s TotalBalance would include all the jobs for that customer.
ITotalBalanceFilter      

Operator

Indicates whether to filter for amounts that are less than, equal to or less than, exactly equal to, greater than, or equal to or greater than the given Amount.
IQBENOperatorType     Y

Amount

The monetary amount to which Operator refers.
IQBAmountType     Y

CurrencyFilter

Filters by the specified currency.
ICurrencyFilter   8.0  

ORCurrencyFilter

IORCurrencyFilter     Y

ListIDList

One or more ListID values. Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IBSTRList      

FullNameList

A list of one or more FullName values. FullName (along with ListID) is a way to identify a list object. The FullName is the name prefixed by the names of each ancestor, for example Jones:Kitchen:Cabinets. FullName values are not case-sensitive.
IBSTRList 64 chars    

ClassFilter

Filter according to class.
IClassFilter   12.0  

ORClassFilter

IORClassFilter     Y

ListIDList

One or more ListID values. Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IBSTRList      

FullNameList

A list of one or more FullName values. FullName (along with ListID) is a way to identify a list object. The FullName is the name prefixed by the names of each ancestor, for example Jones:Kitchen:Cabinets. FullName values are not case-sensitive.
IBSTRList      

ListIDWithChildren

Allows you to filter for data that relates to the specified object and its descendants.
IQBIDType      

FullNameWithChildren

Allows you to filter for data that relates to the specified object and its descendants. For names that do not have children, FullNameWithChildren is exactly the same as FullName.
IQBStringType      

IncludeRetElementList

You use this if you want to limit the data that will be returned in the response. In this list, you specify the name of each top-level element or aggregate that you want to be returned in the response to the request. You cannot specify fields within an aggregate, for example, you cannot specify a City within an Address: you must specify Address and will get the entire address. The names specified in the list are not parsed, so you must be especially careful to supply valid names, properly cased. No error is returned in the status code if you specify an invalid name. Notice that if you want to return custom data or private data extensions, you must specify the DataExtRet element and you must supply the OwnerID set to either a value of 0 (custom data) or the GUID for the private data.
IBSTRList 50 chars 4.0  

OwnerIDList

Zero or more OwnerID values. OwnerID refers to the owner of a data extension:If OwnerID is 0, this is a public data extension, also known as a custom field. Custom fields appear in the QuickBooks UI.If OwnerID is a GUID, for example {6B063959-81B0-4622-85D6-F548C8CCB517}, this field is a private data extension defined by an integrated application. Private data extensions do not appear in the QuickBooks UI. Note that OwnerID values are not case-sensitive, meaning that if you enter an OwnerID value with lower-case letters, the value will be saved and returned with upper-case letters. When you share a private data extension with another application, the other application must know both the OwnerID and the DataExtName, as these together form a data extension’s unique name.
IGUIDList   2.0  
Tag Type Max length Implementation Required

IResponse

Returns data for the specified customers.Important: We highly recommend that you use the IncludeRetElement tag in your CustomerQuery to include any data you want but do NOT include the ShipAddress data in the Response, unless you need to get the shipping address for a particular customer. Excluding the shipping address data will significantly improve the performance of the CustomerQuery.
       

StatusCode

A number that corresponds to a statusSeverity and statusMessage. Five status codes relate directly to signon messages: 2000, 2010, 2020, 2030, and 2040. For details about these and other statusCode values that can be returned, see the statusCode table on the Error Codes page.
IQBIntType     Y

StatusSeverity

One of the following values: INFO The request was completed, and the results are consistent with what your application expected. WARNING The request was completed, but the results might not be consistent with what you expected. ERROR The request was not completed. No data will appear in the server’s response after the statusMessage.
IQBStringType     Y

StatusMessage

A user-readable explanation of the success or error condition that is indicated by the statusCode. For details about the statusMessage values that can be returned, see the “Explanation” column of the statusCode table on the Error Codes page.
IQBStringType     Y

retCount

The retCount is returned in a query if in the query request you specified the metaData attribute with a value of MetaDataOnly (in which case the retCount is the only data returned in the query response) or MetaDataAndResponseData (the query response contains object data AND the approximate count). The retCount value contains the approximate count of the objects that could be expected to be returned from the query. A common use of this feature is to specify a count with no data in order to determine how many objects to expect from the actual query. You should be aware that the count returned in retCount is not guaranteed to be exact: it could be off slightly due to new object creation or deletions.
IQBIntType   4.0 us.png Y

iteratorRemainingCount

This attribute is provided in the response in a query using iterators, indicating the number of objects remaining in the iteration. This can help you specify a MaxReturn value tailored to the number of objects still to be iterated through in your query.
IQBIntType   5.0 us.png Y

iteratorID

Returned in the response in the first iteration and supplied in subsequent iterations, this identifies which iteration is to be used in the query continuing the iteration. Required because many different iterations may be currently in use.
IQBUUIDType   5.0 us.png Y

Detail

ICustomerRetList      

(List

of ICustomerRet Objects)
       

ListID

Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IQBIDType     Y

TimeCreated

Time the object was created.
IQBDateTimeType     Y

TimeModified

Time the object was last modified.
IQBDateTimeType     Y

EditSequence

A number that the server generates and assigns to this object. Every time the object is changed, the server will change its EditSequence value. When you try to modify a list object, you must provide its EditSequence. The server compares the EditSequence you provide with the EditSequence in memory to make sure you are dealing with the latest copy of the object. If you are not, the server will reject the request and return an error. Because EditSequence is only used to check whether two objects match, there is no reason to interpret its value.
IQBStringType 16 chars   Y

Name

The case-insensitive name of a list object, not including the names of its ancestors. Name must be unique, unless it is the Name of a “hierarchical” list object. List objects in different hierarchies can have duplicate names because their FullNames will still be unique. For example, two objects could both have the Name kitchen, but they could have unique FullNames, such as Job12:kitchen and Baker:kitchen. For built-in currencies, Name is the internationally accepted currency name and is not editable.
IQBStringType 41 chars   Y

FullName

FullName (along with ListID) is a way to identify a list object. The FullName is the name prefixed by the names of each ancestor, for example Jones:Kitchen:Cabinets. FullName values are not case-sensitive.
IQBStringType 209 chars   Y

IsActive

If IsActive is true, this object is currently enabled for use by QuickBooks. The default value is true.
IQBBoolType      

ClassRef

Classes can be used to separate transactions into meaningful categories. (For example, transactions could be classified according to department, business location, or type of work.) In QuickBooks, class tracking is off by default. A ClassRef aggregate refers to one of these named classes. For example, in a TimeTracking message, ClassRef refers to the QuickBooks class into which the timed activity falls. If a ClassRef aggregate includes both FullName and ListID, FullName will be ignored. In an InvoiceAdd request, if you specify a ClassRef for the whole invoice, that same ClassRef is automatically used in the line items. If you want to clear that (that is, have NO ClassRef for the line item, you can clear it in the line item by simply not specifying it in the line item.
IQBBaseRef   12.0  

ListID

Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IQBIDType   12.0  

FullName

FullName (along with ListID) is a way to identify a list object. The FullName is the name prefixed by the names of each ancestor, for example Jones:Kitchen:Cabinets. FullName values are not case-sensitive.
IQBStringType 159 chars 12.0  

ParentRef

A reference to the list object that is one level above this one. For example, an inventory item with the FullName of GermanCars:Mercedes-Benz:CL500I99AA might have a parent object with the FullName of GermanCars:Mercedes-Benz.In a request, if a ParentRef aggregate includes both FullName and ListID, FullName will be ignored.
IQBBaseRef      

ListID

Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IQBIDType      

FullName

FullName (along with ListID) is a way to identify a list object. The FullName is the name prefixed by the names of each ancestor, for example Jones:Kitchen:Cabinets. FullName values are not case-sensitive.
IQBStringType      

Sublevel

The number of ancestors. For example, The customer job with Name = carpets and FullName = Jones:Building2:carpets would have a sublevel of 2.
IQBIntType     Y

CompanyName

The name of the QuickBooks user’s business, as specified in QuickBooks. CompanyName and Address are used on invoices, checks, and other forms. (LegalCompanyName and LegalAddress, on the other hand, are used on a company’s tax forms and pay stubs.)
IQBStringType 41 chars    

Salutation

A formal reference, such as Mr. or Dr., that precedes a name.
IQBStringType 15 chars    

FirstName

The first name of a customer, vendor, employee, or person on the “other names” list.
IQBStringType 25 chars    

MiddleName

The middle name of a customer, vendor, employee, or person on the “other names” list.
IQBStringType 5 chars    

LastName

The last name of a customer, vendor, employee, or person on the “other names” list.
IQBStringType 25 chars    

JobTitle

The job title of a customer, vendor, employee, or person on the “other names” list.
IQBStringType 41 chars 12.0  

BillAddress

Whatever address you specify in this aggregate must not result in an address greater than 5 lines, otherwise you’ll get a runtime error, because QuickBooks doesn’t support addresses more than 5 lines. There are two ways to specify an address within this aggregate: Using Addr1 through Addr3 along with the other possible aggregate elements, such as City, State, Postalcode.Using Addr1, Addr2, Addr3, Addr4, and Addr5 to fully specify the address. If you use this so called “address block” approach, you cannot use any other address elements, such as City, State, etc. (Note: this approach is not valid for EmployeeAdd/Mod/Query) If you use the address block approach above, the lines Addr1…Addr5 are each printed as a separate line on the transaction, and the values are returned in the Ret object under the aggregate ShipAddressBlock or BillAddressBlock.
IAddress      

Addr1

The first line of an address.
IQBStringType 41 chars    

Addr2

The second line of an address (if a second line is needed).
IQBStringType 41 chars    

Addr3

The third line of an address (if a third line is needed).
IQBStringType 41 chars    

Addr4

The fourth line of an address (if a fourth line is needed).
IQBStringType 41 chars 2.0  

Addr5

The fifth line of an address (if a fifth line is needed).
IQBStringType 41 chars 6.0  

City

The city name in an address.
IQBStringType 31 chars    

State

The state name in an address.
IQBStringType 21 chars    

PostalCode

The postal code in an address.
IQBStringType 13 chars    

Country

The country name in an address, or, in returned Host information (HostRet or HostInfo), the country for which this edition of QuickBooks was designed. (Possible values are US, CA, UK, and AU.)
IQBStringType 31 chars    

Note

In a BillAddress or ShipAddress aggregate, the Note field value is written at the bottom of the address in the form in which it appears, such as the invoice form.
IQBStringType 41 chars 6.0  

BillAddressBlock

The address expressed as an address block of Addr1 through Addr5, depending on the number of lines in the original request that created the address.
IAddressBlock   6.0  

Addr1

The first line of an address.
IQBStringType 41 chars    

Addr2

The second line of an address (if a second line is needed).
IQBStringType 41 chars    

Addr3

The third line of an address (if a third line is needed).
IQBStringType 41 chars    

Addr4

The fourth line of an address (if a fourth line is needed).
IQBStringType 41 chars    

Addr5

The fifth line of an address (if a fifth line is needed).
IQBStringType 41 chars    

ShipAddress

Whatever address you specify in this aggregate must not result in an address greater than 5 lines, otherwise you’ll get a runtime error, because QuickBooks doesn’t support addresses more than 5 lines. There are two ways to specify an address within this aggregate: Using Addr1 through Addr3 along with the other possible aggregate elements, such as City, State, Postalcode.Using Addr1, Addr2, Addr3, Addr4, and Addr5 to fully specify the address. If you use this so called “address block” approach, you cannot use any other address elements, such as City, State, etc. (Note: this approach is not valid for EmployeeAdd/Mod/Query) If you use the address block approach above, the lines Addr1…Addr5 are each printed as a separate line on the transaction, and the values are returned in the Ret object under the aggregate ShipAddressBlock or BillAddressBlock.
IAddress      

Addr1

The first line of an address.
IQBStringType 41 chars    

Addr2

The second line of an address (if a second line is needed).
IQBStringType 41 chars    

Addr3

The third line of an address (if a third line is needed).
IQBStringType 41 chars    

Addr4

The fourth line of an address (if a fourth line is needed).
IQBStringType 41 chars 2.0  

Addr5

The fifth line of an address (if a fifth line is needed).
IQBStringType 41 chars 6.0  

City

The city name in an address.
IQBStringType 31 chars    

State

The state name in an address.
IQBStringType 21 chars    

PostalCode

The postal code in an address.
IQBStringType 13 chars    

Country

The country name in an address, or, in returned Host information (HostRet or HostInfo), the country for which this edition of QuickBooks was designed. (Possible values are US, CA, UK, and AU.)
IQBStringType 31 chars    

Note

In a BillAddress or ShipAddress aggregate, the Note field value is written at the bottom of the address in the form in which it appears, such as the invoice form.
IQBStringType 41 chars 6.0  

ShipAddressBlock

The address expressed as an address block of Addr1 through Addr5, depending on the number of lines in the original request that created the address.
IAddressBlock   6.0  

Addr1

The first line of an address.
IQBStringType 41 chars    

Addr2

The second line of an address (if a second line is needed).
IQBStringType 41 chars    

Addr3

The third line of an address (if a third line is needed).
IQBStringType 41 chars    

Addr4

The fourth line of an address (if a fourth line is needed).
IQBStringType 41 chars    

Addr5

The fifth line of an address (if a fifth line is needed).
IQBStringType 41 chars    

ShipToAddressList

List of ship to addresses.
IShipToAddressList   12.0  

(List

of IShipToAddress Objects)
       

Name

The case-insensitive name of a list object, not including the names of its ancestors. Name must be unique, unless it is the Name of a “hierarchical” list object. List objects in different hierarchies can have duplicate names because their FullNames will still be unique. For example, two objects could both have the Name kitchen, but they could have unique FullNames, such as Job12:kitchen and Baker:kitchen. For built-in currencies, Name is the internationally accepted currency name and is not editable.
IQBStringType 41 chars   Y

Addr1

The first line of an address.
IQBStringType 41 chars    

Addr2

The second line of an address (if a second line is needed).
IQBStringType 41 chars    

Addr3

The third line of an address (if a third line is needed).
IQBStringType 41 chars    

Addr4

The fourth line of an address (if a fourth line is needed).
IQBStringType 41 chars 2.0  

Addr5

The fifth line of an address (if a fifth line is needed).
IQBStringType 41 chars 6.0  

City

The city name in an address.
IQBStringType 31 chars    

State

The state name in an address.
IQBStringType 21 chars    

PostalCode

The postal code in an address.
IQBStringType 13 chars    

Country

The country name in an address, or, in returned Host information (HostRet or HostInfo), the country for which this edition of QuickBooks was designed. (Possible values are US, CA, UK, and AU.)
IQBStringType 31 chars    

Note

In a BillAddress or ShipAddress aggregate, the Note field value is written at the bottom of the address in the form in which it appears, such as the invoice form.
IQBStringType 41 chars 6.0  

DefaultShipTo

Flag that address is the default ship to address.
IQBBoolType      

Phone

The telephone number.
IQBStringType 21 chars    

AltPhone

A telephone number given as an alternative to Phone.
IQBStringType 21 chars    

Fax

Fax number.
IQBStringType 21 chars    

Email

E-mail address.
IQBStringType 1023 chars    

Cc

Email address that would be carbon copied or CC.
IQBStringType 1023 chars 12.0  

Contact

The name of a contact person for a customer or vendor.
IQBStringType 41 chars    

AltContact

The name of an alternate contact person for a vendor, customer, or “other name” entry.
IQBStringType 41 chars    

AdditionalContactRefList

List of additional contacts.
IQBBaseRefList   12.0  

(List

of IQBBaseRef Objects)
       

ContactName

The name of the contact.
IQBStringType 40 chars   Y

ContactValue

The value of the contact field.
IQBStringType 255 chars   Y

ContactsRetList

A list of contact records.
IContactsRetList   12.0  

(List

of IContactsRet Objects)
       

ListID

Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IQBIDType     Y

TimeCreated

Time the object was created.
IQBDateTimeType     Y

TimeModified

Time the object was last modified.
IQBDateTimeType     Y

EditSequence

A number that the server generates and assigns to this object. Every time the object is changed, the server will change its EditSequence value. When you try to modify a list object, you must provide its EditSequence. The server compares the EditSequence you provide with the EditSequence in memory to make sure you are dealing with the latest copy of the object. If you are not, the server will reject the request and return an error. Because EditSequence is only used to check whether two objects match, there is no reason to interpret its value.
IQBStringType 16 chars   Y

Contact

The name of a contact person for a customer or vendor.
IQBStringType 41 chars    

Salutation

A formal reference, such as Mr. or Dr., that precedes a name.
IQBStringType 15 chars    

FirstName

The first name of a customer, vendor, employee, or person on the “other names” list.
IQBStringType 25 chars   Y

MiddleName

The middle name of a customer, vendor, employee, or person on the “other names” list.
IQBStringType 5 chars    

LastName

The last name of a customer, vendor, employee, or person on the “other names” list.
IQBStringType 25 chars    

JobTitle

The job title of a customer, vendor, employee, or person on the “other names” list.
IQBStringType 41 chars    

AdditionalContactRefList

List of additional contacts.
IQBBaseRefList      

(List

of IQBBaseRef Objects)
       

ContactName

The name of the contact.
IQBStringType 40 chars   Y

ContactValue

The value of the contact field.
IQBStringType 255 chars   Y

CustomerTypeRef

Customer types allow business owners to categorize customers in ways that are meaningful for their businesses. For example, a customer type might indicate which industry a customer represents, or which part of the country a customer is in. A CustomerTypeRef aggregate refers to one of the types on the CustomerType list. In a request, if a CustomerTypeRef aggregate includes both FullName and ListID, FullName will be ignored.
IQBBaseRef      

ListID

Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IQBIDType      

FullName

FullName (along with ListID) is a way to identify a list object. The FullName is the name prefixed by the names of each ancestor, for example Jones:Kitchen:Cabinets. FullName values are not case-sensitive.
IQBStringType 159 chars    

TermsRef

Refers to the payment terms associated with this entity. (This will be an item on the DateDrivenTerms or StandardTerms list.) If a TermsRef aggregate includes both FullName and ListID, FullName will be ignored.
IQBBaseRef      

ListID

Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IQBIDType      

FullName

FullName (along with ListID) is a way to identify a list object. The FullName is the name prefixed by the names of each ancestor, for example Jones:Kitchen:Cabinets. FullName values are not case-sensitive.
IQBStringType 31 chars    

SalesRepRef

A sales representative must be on the Employee, Vendor, or Other Names list within QuickBooks. Sales representative’s names and initials appear on the Rep drop-down list on QuickBooks sales forms. A SalesRepRef refers to a person on the SalesRep list. In a request, if a SalesRepRef aggregate includes both FullName and ListID, FullName will be ignored.
IQBBaseRef      

ListID

Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IQBIDType      

FullName

FullName (along with ListID) is a way to identify a list object. The FullName is the name prefixed by the names of each ancestor, for example Jones:Kitchen:Cabinets. FullName values are not case-sensitive.
IQBStringType 5 chars    

Balance

A positive number indicates money owed by the customer. Compare with TotalBalance.
IQBAmountType      

TotalBalance

Total balance for this customer, including all this customer’s jobs (subcustomers). A positive number indicates money that the customer owes. If a customer does not have any subcustomers, TotalBalance and Balance are the same.
IQBAmountType      

SalesTaxCodeRef

Each item on a sales form is assigned a sales-tax code that indicates whether the item is taxable or non-taxable, and why. Two general codes, which can be modified but not deleted, appear on the sales-tax code list by default:Non-taxable (Name = NON; Desc = Non-Taxable; IsTaxable = false)Taxable (Name = TAX; Desc = Taxable; IsTaxable = true) A sales-tax code can be deleted only if it is no longer associated with any customer, item, or transaction. If the “Do You Charge Sales Tax?” preference within QuickBooks is set to No, QuickBooks will assign the default non-taxable sales-tax code to all sales. A SalesTaxCodeRef aggregate refers to a sales-tax code on the list. In a request, if a SalesTaxCodeRef aggregate includes both FullName and ListID, FullName will be ignored. In a Customer message, SalesTaxCodeRef refers to the sales-tax code that will be used for items related to this customer. In an ItemInventory message, SalesTaxCodeRef refers to the type of sales tax that will be charged for this item, if it is a taxable item and if sales tax is set up within QuickBooks.
IQBBaseRef      

ListID

Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IQBIDType      

FullName

FullName (along with ListID) is a way to identify a list object. The FullName is the name prefixed by the names of each ancestor, for example Jones:Kitchen:Cabinets. FullName values are not case-sensitive.
IQBStringType 3 chars    

ItemSalesTaxRef

A sales-tax item is used to calculate a single sales tax that is collected at a specified rate and paid to a single agency. (Compare with the ItemSalesTaxGroupAdd message.) An ItemSalesTaxRef aggregate refers to an item on this list. In a request, if an ItemSalesTaxRef aggregate includes both FullName and ListID, FullName will be ignored. Taxes can be reflected in transaction line items The following information refers to invoices specifically, but it also applies to sales receipts. Generally its best to assign a tax item or tax group item to an invoice and allow QuickBooks to apply the same tax to all taxable items on the invoice. However in some situations multiple tax combinations are required, so this method doesn’t work. In this case one must use techniques to apply the taxes in the invoice itself as line items. Using lines to apply taxes isn’t always straight forward. When applying taxes as line items, only single tax items can be used, tax groups can only be used for the entire invoice. If you have multiple taxes which apply to all taxable items, and one or more other taxes that only apply to some of the items on an invoice its better to use a tax group which applies to the entire invoice for the taxes which applies to all taxable items and then apply the other taxes in the invoice itself. One applies a tax or tax group to an entire invoice by using the ItemSalesTaxRef aggregate. One can use subtotals to apply a single tax line to multiple items in an invoice, but the tax is only applied automatically for the first tax line after the subtotal line. Any other tax lines which need to be applied to the subtotal line must supply their own amount. If you don’t supply an amount the amount comes out as zero and the tax line is useless. When one does supply an amount, the amount of tax on the subtotal also shows up in the rate column for that tax line. There isn’t any way for the rate to show up as anything other than the amount of the tax. If you have a complicated tax situation where no single tax applies to all taxable items on the invoice, you must choose a zero percent tax to apply for the entire invoice. It is recommended to name such a tax item “Tax Calculated On Invoice” so that it’s clear that the tax is not being applied by QuickBooks on the entire invoice.
IQBBaseRef   us.png  

ListID

Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IQBIDType   us.png  

FullName

FullName (along with ListID) is a way to identify a list object. The FullName is the name prefixed by the names of each ancestor, for example Jones:Kitchen:Cabinets. FullName values are not case-sensitive.
IQBStringType 31 chars us.png  

SalesTaxCountry

The country that sales tax is collected for.
IQBENSalesTaxCountryType   6.0 CA.png uk.png  

ResaleNumber

The customer’s resale number, if they have one. This number will not affect reports or sales tax calculations.
IQBStringType 15 chars    

AccountNumber

Account numbers appear in the QuickBooks chart of accounts, Account fields, and reports and graphs. If the IsUsingAccountNumber preference is false (that is, if the QuickBooks user has the account numbers Preference turned off), you can still set account numbers through the SDK, but the numbers will not be visible in the user interface.
IQBStringType 99 chars    

CreditLimit

Set and returned as a positive number that indicates a customer’s or vendor’s credit limit. If no value has been defined, there is no credit limit.
IQBAmountType      

PreferredPaymentMethodRef

Refers to a PaymentMethod object. In a request, if a PreferredPaymentMethodRef aggregate includes both FullName and ListID, FullName will be ignored.
IQBBaseRef   3.0  

ListID

Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IQBIDType   3.0  

FullName

FullName (along with ListID) is a way to identify a list object. The FullName is the name prefixed by the names of each ancestor, for example Jones:Kitchen:Cabinets. FullName values are not case-sensitive.
IQBStringType 31 chars 3.0  

CreditCardInfo

Customer’s credit-card information.
ICreditCardInfo   3.0  

CreditCardNumber

Credit-card number for this customer or this payment. Beginning with qbXML spec 6.0 and QuickBooks 2007, you must mask the credit card number with lower case “x” and no dashes. For example, xxxxxxxxxxxx1234.
IQBStringType 25 chars    

ExpirationMonth

The month when the credit card expires.
IQBIntType 12 chars    

ExpirationYear

The year when the credit card expires.
IQBIntType      

NameOnCard

The name on the customer’s credit card.
IQBStringType 41 chars    

CreditCardAddress

The address associated with this credit card.
IQBStringType 41 chars    

CreditCardPostalCode

The postal code associated with the address for this credit card.
IQBStringType 41 chars    

JobStatus

JobStatus Status information about a sub-customer; used in reports. The Job- elements (JobDesc, JobEndDate, JobProjectedEndDate, JobStartDate, and JobStatus) correspond to the fields in the Job Info tab of the Edit Job window in QuickBooks.
IQBENJobStatusType      

JobStartDate

The date on which work for a sub-customer was started; used in reports. The Job- elements (JobDesc, JobEndDate, JobProjectedEndDate, JobStartDate, and JobStatus) correspond to the fields in the Job Info tab of the Edit Job window in QuickBooks.
IQBDateType      

JobProjectedEndDate

The date on which work for a sub-customer is expected to be complete; used in reports. The Job- elements (JobDesc, JobEndDate, JobProjectedEndDate, JobStartDate, and JobStatus) correspond to the fields in the Job Info tab of the Edit Job window in QuickBooks.
IQBDateType      

JobEndDate

The date on which work for a sub-customer was completed; used in reports.The Job- elements (JobDesc, JobEndDate, JobProjectedEndDate, JobStartDate, and JobStatus) correspond to the fields in the Job Info tab of the Edit Job window in QuickBooks.
IQBDateType      

JobDesc

A short job description for a sub-customer; used in reports.The Job- elements (JobDesc, JobEndDate, JobProjectedEndDate, JobStartDate, and JobStatus) correspond to the fields in the Job Info tab of the Edit Job window in QuickBooks.
IQBStringType 99 chars    

JobTypeRef

Job type can be used to separate jobs into any categories that are meaningful to the business. A JobTypeRef aggregate refers to a job type on the JobType list. In a request, if a JobTypeRef aggregate includes both FullName and ListID, FullName will be ignored.
IQBBaseRef      

ListID

Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IQBIDType      

FullName

FullName (along with ListID) is a way to identify a list object. The FullName is the name prefixed by the names of each ancestor, for example Jones:Kitchen:Cabinets. FullName values are not case-sensitive.
IQBStringType 159 chars    

Notes

Not supported.
IQBStringType 4095 chars    

AdditionalNotesRetList

List of notes.
IAdditionalNotesRetList   12.0  

(List

of IAdditionalNotesRet Objects)
       

NoteID

The ID of the note.
IQBIntType     Y

Date

The date the note was updated.
IQBDateType     Y

Note

In a BillAddress or ShipAddress aggregate, the Note field value is written at the bottom of the address in the form in which it appears, such as the invoice form.
IQBStringType 4095 chars   Y

PreferredDeliveryMethod

Preference for how invoices are delivered.
IQBENPreferredDeliveryMethodType   12.0  

PriceLevelRef

You can use price levels to specify custom pricing for specific customers. Once you create a price level for a customer, QuickBooks will automatically use the custom price in new invoices, sales receipts, sales orders or credit memos for that customer. You can override this automatic feature, however, when you create the invoices, sales receipts, etc.) The user can now specify a price level on line items in the following supported sales transactions: invoices, sales receipts, credit memos, and sales orders. Notice that the response data for the affected sales transaction does not list the price level that was used. The response simply lists the Rate for the item, which was set using the price level.
IQBBaseRef   4.0  

ListID

Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IQBIDType   4.0  

FullName

FullName (along with ListID) is a way to identify a list object. The FullName is the name prefixed by the names of each ancestor, for example Jones:Kitchen:Cabinets. FullName values are not case-sensitive.
IQBStringType 31 chars 4.0  

ExternalGUID

Allows for the attachment of a user defined GUID value.
IQBGUIDType   8.0  

TaxRegistrationNumber

The tax registration number used in CA and UK.
IQBStringType 30 chars 8.0 CA.png uk.png  

CurrencyRef

The currency object contains all of the information needed by QuickBooks to display and use. For built-in currencies, the name and currency code values are internationally accepted values and thus are not editable. The comma format is editable, as is the IsActive status. For user-defined currencies, every value in the object is editable including name and currency code. When used with PriceLevels, the CurrencyRef should only be used with “per item” price levels.
IQBBaseRef   8.0  

ListID

Along with FullName, ListID is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a ListID. A ListID is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same ListID, and a customer could not have the same ListID as an employee (because Customer and Employee are both name lists). But a customer could have the same ListID as a non-inventory item.
IQBIDType   8.0  

FullName

FullName (along with ListID) is a way to identify a list object. The FullName is the name prefixed by the names of each ancestor, for example Jones:Kitchen:Cabinets. FullName values are not case-sensitive.
IQBStringType 64 chars 8.0  

DataExtRetList

A list of IDataExtRet objects, each of which represents a field that has been added to QuickBooks as a data extension.
IDataExtRetList   2.0  

(List

of IDataExtRet Objects)
       

OwnerID

OwnerID refers to the owner of a data extension, and must be 0 or a valid GUID. (Custom fields, which are visible in the QuickBooks UI, always have an OwnerID of 0. ) Usually you would keep your application’s GUID confidential to prevent other applications from accessing your data extensions. But if you want to share data extensions with another application, the applications need to use the same GUID. In this case, each application could use two GUIDs, one for shared data extensions and one for confidential data extensions. (An application can have any number of GUIDs.) When you share a data extension with another application, the other application must know both the OwnerID and the DataExtName, as these together form a data extension’s unique name.
IQBGUIDType      

DataExtName

The name of the data extension. If this is a custom field, DataExtName will be visible as a label in the QuickBooks user interface. Also because OwnerID and DataExtName together make the data extension unique, and because custom fields all have the same OwnerID of zero, the DataExtName must be a unique value among existing custom fields. In contrast, the DataExtName for private data extensions must be unique only for the specified OwnerID GUID.
IQBStringType 31 chars   Y

DataExtType

The field’s data type, which corresponds to a qbXML data type. In an IDataExtDefAdd request object, if this is a custom field, DataExtType must be detSTR255TYPE.
IQBENDataExtTypeType     Y

DataExtValue

The data in this field. The maximum length of DataExtValue will depend on the DataExtType of this data extension. For example, if DataExtType is STR255TYPE, the maximum length of DataExtValue is 255 characters. If DataExtType is STR1024TYPE, the maximum size of DataExtValue is 1KB.
IQBStringType     Y

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
<?xml version="1.0" encoding="utf-8"?>
<?qbxml version="16.0"?>
<QBXML>
        <QBXMLMsgsRq onError="stopOnError">
                <CustomerQueryRq metaData="ENUMTYPE" iterator="ENUMTYPE" iteratorID="UUIDTYPE">
                        <!-- BEGIN OR -->
                                <ListID >IDTYPE</ListID> <!-- optional, may repeat -->
                        <!-- OR -->
                                <FullName >STRTYPE</FullName> <!-- optional, may repeat -->
                        <!-- OR -->
                                <MaxReturned >INTTYPE</MaxReturned> <!-- optional -->
                                <!-- ActiveStatus may have one of the following values: ActiveOnly [DEFAULT], InactiveOnly, All -->
                                <ActiveStatus >ENUMTYPE</ActiveStatus> <!-- optional -->
                                <FromModifiedDate >DATETIMETYPE</FromModifiedDate> <!-- optional -->
                                <ToModifiedDate >DATETIMETYPE</ToModifiedDate> <!-- optional -->
                                <!-- BEGIN OR -->
                                        <NameFilter> <!-- optional -->
                                                <!-- MatchCriterion may have one of the following values: StartsWith, Contains, EndsWith -->
                                                <MatchCriterion >ENUMTYPE</MatchCriterion> <!-- required -->
                                                <Name >STRTYPE</Name> <!-- required -->
                                        </NameFilter>
                                <!-- OR -->
                                        <NameRangeFilter> <!-- optional -->
                                                <FromName >STRTYPE</FromName> <!-- optional -->
                                                <ToName >STRTYPE</ToName> <!-- optional -->
                                        </NameRangeFilter>
                                <!-- END OR -->
                                <TotalBalanceFilter> <!-- optional -->
                                        <!-- Operator may have one of the following values: LessThan, LessThanEqual, Equal, GreaterThan, GreaterThanEqual -->
                                        <Operator >ENUMTYPE</Operator> <!-- required -->
                                        <Amount >AMTTYPE</Amount> <!-- required -->
                                </TotalBalanceFilter>
                                <CurrencyFilter> <!-- optional -->
                                        <!-- BEGIN OR -->
                                                <ListID >IDTYPE</ListID> <!-- optional, may repeat -->
                                        <!-- OR -->
                                                <FullName >STRTYPE</FullName> <!-- optional, may repeat -->
                                        <!-- END OR -->
                                </CurrencyFilter>
                                <ClassFilter> <!-- optional -->
                                        <!-- BEGIN OR -->
                                                <ListID >IDTYPE</ListID> <!-- optional, may repeat -->
                                        <!-- OR -->
                                                <FullName >STRTYPE</FullName> <!-- optional, may repeat -->
                                        <!-- OR -->
                                                <ListIDWithChildren >IDTYPE</ListIDWithChildren> <!-- optional -->
                                        <!-- OR -->
                                                <FullNameWithChildren >STRTYPE</FullNameWithChildren> <!-- optional -->
                                        <!-- END OR -->
                                </ClassFilter>
                        <!-- END OR -->
                        <IncludeRetElement >STRTYPE</IncludeRetElement> <!-- optional, may repeat -->
                        <OwnerID >GUIDTYPE</OwnerID> <!-- optional, may repeat -->
                </CustomerQueryRq>

                <CustomerQueryRs statusCode="INTTYPE" statusSeverity="STRTYPE" statusMessage="STRTYPE" retCount="INTTYPE" iteratorRemainingCount="INTTYPE" iteratorID="UUIDTYPE">
                        <CustomerRet> <!-- optional, may repeat -->
                                <ListID >IDTYPE</ListID> <!-- required -->
                                <TimeCreated >DATETIMETYPE</TimeCreated> <!-- required -->
                                <TimeModified >DATETIMETYPE</TimeModified> <!-- required -->
                                <EditSequence >STRTYPE</EditSequence> <!-- required -->
                                <Name >STRTYPE</Name> <!-- required -->
                                <FullName >STRTYPE</FullName> <!-- required -->
                                <IsActive >BOOLTYPE</IsActive> <!-- optional -->
                                <ClassRef> <!-- optional -->
                                        <ListID >IDTYPE</ListID> <!-- optional -->
                                        <FullName >STRTYPE</FullName> <!-- optional -->
                                </ClassRef>
                                <ParentRef> <!-- optional -->
                                        <ListID >IDTYPE</ListID> <!-- optional -->
                                        <FullName >STRTYPE</FullName> <!-- optional -->
                                </ParentRef>
                                <Sublevel >INTTYPE</Sublevel> <!-- required -->
                                <CompanyName >STRTYPE</CompanyName> <!-- optional -->
                                <Salutation >STRTYPE</Salutation> <!-- optional -->
                                <FirstName >STRTYPE</FirstName> <!-- optional -->
                                <MiddleName >STRTYPE</MiddleName> <!-- optional -->
                                <LastName >STRTYPE</LastName> <!-- optional -->
                                <JobTitle >STRTYPE</JobTitle> <!-- optional -->
                                <BillAddress> <!-- optional -->
                                        <Addr1 >STRTYPE</Addr1> <!-- optional -->
                                        <Addr2 >STRTYPE</Addr2> <!-- optional -->
                                        <Addr3 >STRTYPE</Addr3> <!-- optional -->
                                        <Addr4 >STRTYPE</Addr4> <!-- optional -->
                                        <Addr5 >STRTYPE</Addr5> <!-- optional -->
                                        <City >STRTYPE</City> <!-- optional -->
                                        <State >STRTYPE</State> <!-- optional -->
                                        <PostalCode >STRTYPE</PostalCode> <!-- optional -->
                                        <Country >STRTYPE</Country> <!-- optional -->
                                        <Note >STRTYPE</Note> <!-- optional -->
                                </BillAddress>
                                <BillAddressBlock> <!-- optional -->
                                        <Addr1 >STRTYPE</Addr1> <!-- optional -->
                                        <Addr2 >STRTYPE</Addr2> <!-- optional -->
                                        <Addr3 >STRTYPE</Addr3> <!-- optional -->
                                        <Addr4 >STRTYPE</Addr4> <!-- optional -->
                                        <Addr5 >STRTYPE</Addr5> <!-- optional -->
                                </BillAddressBlock>
                                <ShipAddress> <!-- optional -->
                                        <Addr1 >STRTYPE</Addr1> <!-- optional -->
                                        <Addr2 >STRTYPE</Addr2> <!-- optional -->
                                        <Addr3 >STRTYPE</Addr3> <!-- optional -->
                                        <Addr4 >STRTYPE</Addr4> <!-- optional -->
                                        <Addr5 >STRTYPE</Addr5> <!-- optional -->
                                        <City >STRTYPE</City> <!-- optional -->
                                        <State >STRTYPE</State> <!-- optional -->
                                        <PostalCode >STRTYPE</PostalCode> <!-- optional -->
                                        <Country >STRTYPE</Country> <!-- optional -->
                                        <Note >STRTYPE</Note> <!-- optional -->
                                </ShipAddress>
                                <ShipAddressBlock> <!-- optional -->
                                        <Addr1 >STRTYPE</Addr1> <!-- optional -->
                                        <Addr2 >STRTYPE</Addr2> <!-- optional -->
                                        <Addr3 >STRTYPE</Addr3> <!-- optional -->
                                        <Addr4 >STRTYPE</Addr4> <!-- optional -->
                                        <Addr5 >STRTYPE</Addr5> <!-- optional -->
                                </ShipAddressBlock>
                                <ShipToAddress> <!-- must occur 0 - 50 times -->
                                        <Name >STRTYPE</Name> <!-- required -->
                                        <Addr1 >STRTYPE</Addr1> <!-- optional -->
                                        <Addr2 >STRTYPE</Addr2> <!-- optional -->
                                        <Addr3 >STRTYPE</Addr3> <!-- optional -->
                                        <Addr4 >STRTYPE</Addr4> <!-- optional -->
                                        <Addr5 >STRTYPE</Addr5> <!-- optional -->
                                        <City >STRTYPE</City> <!-- optional -->
                                        <State >STRTYPE</State> <!-- optional -->
                                        <PostalCode >STRTYPE</PostalCode> <!-- optional -->
                                        <Country >STRTYPE</Country> <!-- optional -->
                                        <Note >STRTYPE</Note> <!-- optional -->
                                        <DefaultShipTo >BOOLTYPE</DefaultShipTo> <!-- optional -->
                                </ShipToAddress>
                                <Phone >STRTYPE</Phone> <!-- optional -->
                                <AltPhone >STRTYPE</AltPhone> <!-- optional -->
                                <Fax >STRTYPE</Fax> <!-- optional -->
                                <Email >STRTYPE</Email> <!-- optional -->
                                <Cc >STRTYPE</Cc> <!-- optional -->
                                <Contact >STRTYPE</Contact> <!-- optional -->
                                <AltContact >STRTYPE</AltContact> <!-- optional -->
                                <AdditionalContactRef> <!-- must occur 0 - 8 times -->
                                        <ContactName >STRTYPE</ContactName> <!-- required -->
                                        <ContactValue >STRTYPE</ContactValue> <!-- required -->
                                </AdditionalContactRef>
                                <ContactsRet> <!-- optional, may repeat -->
                                        <ListID >IDTYPE</ListID> <!-- required -->
                                        <TimeCreated >DATETIMETYPE</TimeCreated> <!-- required -->
                                        <TimeModified >DATETIMETYPE</TimeModified> <!-- required -->
                                        <EditSequence >STRTYPE</EditSequence> <!-- required -->
                                        <Contact >STRTYPE</Contact> <!-- optional -->
                                        <Salutation >STRTYPE</Salutation> <!-- optional -->
                                        <FirstName >STRTYPE</FirstName> <!-- required -->
                                        <MiddleName >STRTYPE</MiddleName> <!-- optional -->
                                        <LastName >STRTYPE</LastName> <!-- optional -->
                                        <JobTitle >STRTYPE</JobTitle> <!-- optional -->
                                        <AdditionalContactRef> <!-- must occur 0 - 5 times -->
                                                <ContactName >STRTYPE</ContactName> <!-- required -->
                                                <ContactValue >STRTYPE</ContactValue> <!-- required -->
                                        </AdditionalContactRef>
                                </ContactsRet>
                                <CustomerTypeRef> <!-- optional -->
                                        <ListID >IDTYPE</ListID> <!-- optional -->
                                        <FullName >STRTYPE</FullName> <!-- optional -->
                                </CustomerTypeRef>
                                <TermsRef> <!-- optional -->
                                        <ListID >IDTYPE</ListID> <!-- optional -->
                                        <FullName >STRTYPE</FullName> <!-- optional -->
                                </TermsRef>
                                <SalesRepRef> <!-- optional -->
                                        <ListID >IDTYPE</ListID> <!-- optional -->
                                        <FullName >STRTYPE</FullName> <!-- optional -->
                                </SalesRepRef>
                                <Balance >AMTTYPE</Balance> <!-- optional -->
                                <TotalBalance >AMTTYPE</TotalBalance> <!-- optional -->
                                <SalesTaxCodeRef> <!-- optional -->
                                        <ListID >IDTYPE</ListID> <!-- optional -->
                                        <FullName >STRTYPE</FullName> <!-- optional -->
                                </SalesTaxCodeRef>
                                <ItemSalesTaxRef> <!-- optional -->
                                        <ListID >IDTYPE</ListID> <!-- optional -->
                                        <FullName >STRTYPE</FullName> <!-- optional -->
                                </ItemSalesTaxRef>
                                <!-- SalesTaxCountry may have one of the following values: Australia, Canada [DEFAULT], UK, US -->
                                <SalesTaxCountry >ENUMTYPE</SalesTaxCountry> <!-- optional -->
                                <ResaleNumber >STRTYPE</ResaleNumber> <!-- optional -->
                                <AccountNumber >STRTYPE</AccountNumber> <!-- optional -->
                                <CreditLimit >AMTTYPE</CreditLimit> <!-- optional -->
                                <PreferredPaymentMethodRef> <!-- optional -->
                                        <ListID >IDTYPE</ListID> <!-- optional -->
                                        <FullName >STRTYPE</FullName> <!-- optional -->
                                </PreferredPaymentMethodRef>
                                <CreditCardInfo> <!-- optional -->
                                        <CreditCardNumber >STRTYPE</CreditCardNumber> <!-- optional -->
                                        <ExpirationMonth >INTTYPE</ExpirationMonth> <!-- optional -->
                                        <ExpirationYear >INTTYPE</ExpirationYear> <!-- optional -->
                                        <NameOnCard >STRTYPE</NameOnCard> <!-- optional -->
                                        <CreditCardAddress >STRTYPE</CreditCardAddress> <!-- optional -->
                                        <CreditCardPostalCode >STRTYPE</CreditCardPostalCode> <!-- optional -->
                                </CreditCardInfo>
                                <!-- JobStatus may have one of the following values: Awarded, Closed, InProgress, None [DEFAULT], NotAwarded, Pending -->
                                <JobStatus >ENUMTYPE</JobStatus> <!-- optional -->
                                <JobStartDate >DATETYPE</JobStartDate> <!-- optional -->
                                <JobProjectedEndDate >DATETYPE</JobProjectedEndDate> <!-- optional -->
                                <JobEndDate >DATETYPE</JobEndDate> <!-- optional -->
                                <JobDesc >STRTYPE</JobDesc> <!-- optional -->
                                <JobTypeRef> <!-- optional -->
                                        <ListID >IDTYPE</ListID> <!-- optional -->
                                        <FullName >STRTYPE</FullName> <!-- optional -->
                                </JobTypeRef>
                                <Notes >STRTYPE</Notes> <!-- optional -->
                                <AdditionalNotesRet> <!-- optional, may repeat -->
                                        <NoteID >INTTYPE</NoteID> <!-- required -->
                                        <Date >DATETYPE</Date> <!-- required -->
                                        <Note >STRTYPE</Note> <!-- required -->
                                </AdditionalNotesRet>
                                <!-- PreferredDeliveryMethod may have one of the following values: None [Default], Email, Fax -->
                                <PreferredDeliveryMethod >ENUMTYPE</PreferredDeliveryMethod> <!-- optional -->
                                <PriceLevelRef> <!-- optional -->
                                        <ListID >IDTYPE</ListID> <!-- optional -->
                                        <FullName >STRTYPE</FullName> <!-- optional -->
                                </PriceLevelRef>
                                <ExternalGUID >GUIDTYPE</ExternalGUID> <!-- optional -->
                                <TaxRegistrationNumber >STRTYPE</TaxRegistrationNumber> <!-- optional -->
                                <CurrencyRef> <!-- optional -->
                                        <ListID >IDTYPE</ListID> <!-- optional -->
                                        <FullName >STRTYPE</FullName> <!-- optional -->
                                </CurrencyRef>
                                <DataExtRet> <!-- optional, may repeat -->
                                        <OwnerID >GUIDTYPE</OwnerID> <!-- optional -->
                                        <DataExtName >STRTYPE</DataExtName> <!-- required -->
                                        <!-- DataExtType may have one of the following values: AMTTYPE, DATETIMETYPE, INTTYPE, PERCENTTYPE, PRICETYPE, QUANTYPE, STR1024TYPE, STR255TYPE -->
                                        <DataExtType >ENUMTYPE</DataExtType> <!-- required -->
                                        <DataExtValue >STRTYPE</DataExtValue> <!-- required -->
                                </DataExtRet>
                        </CustomerRet>
                </CustomerQueryRs>
        </QBXMLMsgsRq>
</QBXML>

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
'The following sample code is generated as an illustration of
'Creating requests and parsing responses ONLY
'This code is NOT intended to show best practices or ideal code
'Use at your most careful discretion

imports System
imports System.Net
imports System.Drawing
imports System.Collections
imports System.ComponentModel
imports System.Windows.Forms
imports System.Data
imports System.IO
imports Interop.QBFC16

Module com.intuit.idn.samples
        Public Class Sample
                Public Sub  DoCustomerQuery()
                        Dim sessionBegun as Boolean
                        sessionBegun = False
                        Dim connectionOpen as Boolean
                        connectionOpen = False
                        Dim sessionManager as QBSessionManager
                        sessionManager = nothing

                        Try
                                'Create the session Manager object
                                sessionManager = new QBSessionManager

                                'Create the message set request object to hold our request
                                Dim requestMsgSet as IMsgSetRequest
                                requestMsgSet = sessionManager.CreateMsgSetRequest("US",16,0)
                                requestMsgSet.Attributes.OnError = ENRqOnError.roeContinue

                                BuildCustomerQueryRq(requestMsgSet)

                                'Connect to QuickBooks and begin a session
                                sessionManager.OpenConnection("","Sample Code from OSR")
                                connectionOpen = True
                                sessionManager.BeginSession("", ENOpenMode.omDontCare)
                                sessionBegun = True

                                'Send the request and get the response from QuickBooks
                                Dim responseMsgSet as IMsgSetResponse
                                responseMsgSet = sessionManager.DoRequests(requestMsgSet)

                                'End the session and close the connection to QuickBooks
                                sessionManager.EndSession()
                                sessionBegun = False
                                sessionManager.CloseConnection()
                                connectionOpen = False

                                WalkCustomerQueryRs(responseMsgSet)
                        Catch e as Exception
                                MessageBox.Show(e.Message, "Error")
                                if (sessionBegun) then
                                        sessionManager.EndSession()
                                End If
                                if (connectionOpen) then
                                        sessionManager.CloseConnection()
                                End If
                        End Try
                End Sub
                Public Sub BuildCustomerQueryRq(requestMsgSet as IMsgSetRequest)
                        Dim CustomerQueryRq as ICustomerQuery
                        CustomerQueryRq= requestMsgSet.AppendCustomerQueryRq()
                        Dim ORCustomerListQueryElementType7630 as String
                        ORCustomerListQueryElementType7630 = "ListIDList"
                        if (ORCustomerListQueryElementType7630 == "ListIDList") then
                                'Set field value for ListIDList
                                'May create more than one of these if needed
                                CustomerQueryRq.ORCustomerListQuery.ListIDList.Add("200000-1011023419")
                        End If
                        if (ORCustomerListQueryElementType7630 == "FullNameList") then
                                'Set field value for FullNameList
                                'May create more than one of these if needed
                                CustomerQueryRq.ORCustomerListQuery.FullNameList.Add("ab")
                        End If
                        if (ORCustomerListQueryElementType7630 == "CustomerListFilter") then
                                'Set field value for MaxReturned
                                CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.MaxReturned.SetValue(6)
                                'Set field value for ActiveStatus
                                CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ActiveStatus.SetValue(ENActiveStatus.asActiveOnly [DEFAULT])
                                'Set field value for FromModifiedDate
                                CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.FromModifiedDate.SetValue(DateTime.Parse("12/15/2007 12:15:12"),false)
                                'Set field value for ToModifiedDate
                                CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ToModifiedDate.SetValue(DateTime.Parse("12/15/2007 12:15:12"),false)
                                Dim ORNameFilterElementType7631 as String
                                ORNameFilterElementType7631 = "NameFilter"
                                if (ORNameFilterElementType7631 == "NameFilter") then
                                        'Set field value for MatchCriterion
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ORNameFilter.NameFilter.MatchCriterion.SetValue(ENMatchCriterion.mcStartsWith)
                                        'Set field value for Name
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ORNameFilter.NameFilter.Name.SetValue("ab")
                                End If
                                if (ORNameFilterElementType7631 == "NameRangeFilter") then
                                        'Set field value for FromName
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ORNameFilter.NameRangeFilter.FromName.SetValue("ab")
                                        'Set field value for ToName
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ORNameFilter.NameRangeFilter.ToName.SetValue("ab")
                                End If
                                'Set field value for Operator
                                CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.TotalBalanceFilter.Operator.SetValue(ENOperator.oLessThan)
                                'Set field value for Amount
                                CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.TotalBalanceFilter.Amount.SetValue(10.01)
                                Dim ORCurrencyFilterElementType7632 as String
                                ORCurrencyFilterElementType7632 = "ListIDList"
                                if (ORCurrencyFilterElementType7632 == "ListIDList") then
                                        'Set field value for ListIDList
                                        'May create more than one of these if needed
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.CurrencyFilter.ORCurrencyFilter.ListIDList.Add("200000-1011023419")
                                End If
                                if (ORCurrencyFilterElementType7632 == "FullNameList") then
                                        'Set field value for FullNameList
                                        'May create more than one of these if needed
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.CurrencyFilter.ORCurrencyFilter.FullNameList.Add("ab")
                                End If
                                Dim ORClassFilterElementType7633 as String
                                ORClassFilterElementType7633 = "ListIDList"
                                if (ORClassFilterElementType7633 == "ListIDList") then
                                        'Set field value for ListIDList
                                        'May create more than one of these if needed
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ClassFilter.ORClassFilter.ListIDList.Add("200000-1011023419")
                                End If
                                if (ORClassFilterElementType7633 == "FullNameList") then
                                        'Set field value for FullNameList
                                        'May create more than one of these if needed
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ClassFilter.ORClassFilter.FullNameList.Add("ab")
                                End If
                                if (ORClassFilterElementType7633 == "ListIDWithChildren") then
                                        'Set field value for ListIDWithChildren
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ClassFilter.ORClassFilter.ListIDWithChildren.SetValue("200000-1011023419")
                                End If
                                if (ORClassFilterElementType7633 == "FullNameWithChildren") then
                                        'Set field value for FullNameWithChildren
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ClassFilter.ORClassFilter.FullNameWithChildren.SetValue("ab")
                                End If
                        End If
                        'Set field value for IncludeRetElementList
                        'May create more than one of these if needed
                        CustomerQueryRq.IncludeRetElementList.Add("ab")
                        'Set field value for OwnerIDList
                        'May create more than one of these if needed
                        CustomerQueryRq.OwnerIDList.Add(System.Guid.NewGuid().ToString())
                End Sub




                Public Sub WalkCustomerQueryRs( responseMsgSet as IMsgSetResponse)
                        if (responseMsgSet is nothing) then
                                Exit Sub
                        End If

                        Dim responseList as IResponseList
                        responseList = responseMsgSet.ResponseList
                        if (responseList is nothing) then
                                Exit Sub
                        End If

                        'if we sent only one request, there is only one response, we'll walk the list for this sample
                        for j=0 to responseList.Count-1
                                Dim response as IResponse
                                response = responseList.GetAt(j)
                                'check the status code of the response, 0=ok, >0 is warning
                                if (response.StatusCode >= 0) then
                                        'the request-specific response is in the details, make sure we have some
                                        if (not response.Detail is nothing) then
                                                'make sure the response is the type we're expecting
                                                Dim responseType as ENResponseType
                                                responseType = CType(response.Type.GetValue(),ENResponseType)
                                                if (responseType == ENResponseType.rtCustomerQueryRs) then
                                                        'upcast to more specific type here, this is safe because we checked with response.Type check above
                                                        Dim CustomerRet as ICustomerRetList
                                                        CustomerRet = CType(response.Detail,ICustomerRetList)
                                                        WalkCustomerRet(CustomerRet.GetAt(i))
                                                End If
                                        End If
                                End If
                        Next j
                End Sub




                Public Sub WalkCustomerRet(CustomerRet as ICustomerRet)
                        if (CustomerRet is nothing) then
                                Exit Sub
                        End If

                        'Go through all the elements of ICustomerRetList
                        'Get value of ListID
                        Dim ListID7634 as String
                        ListID7634 = CustomerRet.ListID.GetValue()
                        'Get value of TimeCreated
                        Dim TimeCreated7635 as DateTime
                        TimeCreated7635 = CustomerRet.TimeCreated.GetValue()
                        'Get value of TimeModified
                        Dim TimeModified7636 as DateTime
                        TimeModified7636 = CustomerRet.TimeModified.GetValue()
                        'Get value of EditSequence
                        Dim EditSequence7637 as String
                        EditSequence7637 = CustomerRet.EditSequence.GetValue()
                        'Get value of Name
                        Dim Name7638 as String
                        Name7638 = CustomerRet.Name.GetValue()
                        'Get value of FullName
                        Dim FullName7639 as String
                        FullName7639 = CustomerRet.FullName.GetValue()
                        'Get value of IsActive
                        if ( not CustomerRet.IsActive is nothing) then
                                Dim IsActive7640 as Boolean
                                IsActive7640 = CustomerRet.IsActive.GetValue()
                        End If
                        if (not CustomerRet.ClassRef. is nothing) then
                                'Get value of ListID
                                if ( not CustomerRet.ClassRef.ListID is nothing) then
                                        Dim ListID7641 as String
                                        ListID7641 = CustomerRet.ClassRef.ListID.GetValue()
                                End If
                                'Get value of FullName
                                if ( not CustomerRet.ClassRef.FullName is nothing) then
                                        Dim FullName7642 as String
                                        FullName7642 = CustomerRet.ClassRef.FullName.GetValue()
                                End If
                        End If
                        if (not CustomerRet.ParentRef. is nothing) then
                                'Get value of ListID
                                if ( not CustomerRet.ParentRef.ListID is nothing) then
                                        Dim ListID7643 as String
                                        ListID7643 = CustomerRet.ParentRef.ListID.GetValue()
                                End If
                                'Get value of FullName
                                if ( not CustomerRet.ParentRef.FullName is nothing) then
                                        Dim FullName7644 as String
                                        FullName7644 = CustomerRet.ParentRef.FullName.GetValue()
                                End If
                        End If
                        'Get value of Sublevel
                        Dim Sublevel7645 as Integer
                        Sublevel7645 = CustomerRet.Sublevel.GetValue()
                        'Get value of CompanyName
                        if ( not CustomerRet.CompanyName is nothing) then
                                Dim CompanyName7646 as String
                                CompanyName7646 = CustomerRet.CompanyName.GetValue()
                        End If
                        'Get value of Salutation
                        if ( not CustomerRet.Salutation is nothing) then
                                Dim Salutation7647 as String
                                Salutation7647 = CustomerRet.Salutation.GetValue()
                        End If
                        'Get value of FirstName
                        if ( not CustomerRet.FirstName is nothing) then
                                Dim FirstName7648 as String
                                FirstName7648 = CustomerRet.FirstName.GetValue()
                        End If
                        'Get value of MiddleName
                        if ( not CustomerRet.MiddleName is nothing) then
                                Dim MiddleName7649 as String
                                MiddleName7649 = CustomerRet.MiddleName.GetValue()
                        End If
                        'Get value of LastName
                        if ( not CustomerRet.LastName is nothing) then
                                Dim LastName7650 as String
                                LastName7650 = CustomerRet.LastName.GetValue()
                        End If
                        'Get value of JobTitle
                        if ( not CustomerRet.JobTitle is nothing) then
                                Dim JobTitle7651 as String
                                JobTitle7651 = CustomerRet.JobTitle.GetValue()
                        End If
                        if (not CustomerRet.BillAddress. is nothing) then
                                'Get value of Addr1
                                if ( not CustomerRet.BillAddress.Addr1 is nothing) then
                                        Dim Addr17652 as String
                                        Addr17652 = CustomerRet.BillAddress.Addr1.GetValue()
                                End If
                                'Get value of Addr2
                                if ( not CustomerRet.BillAddress.Addr2 is nothing) then
                                        Dim Addr27653 as String
                                        Addr27653 = CustomerRet.BillAddress.Addr2.GetValue()
                                End If
                                'Get value of Addr3
                                if ( not CustomerRet.BillAddress.Addr3 is nothing) then
                                        Dim Addr37654 as String
                                        Addr37654 = CustomerRet.BillAddress.Addr3.GetValue()
                                End If
                                'Get value of Addr4
                                if ( not CustomerRet.BillAddress.Addr4 is nothing) then
                                        Dim Addr47655 as String
                                        Addr47655 = CustomerRet.BillAddress.Addr4.GetValue()
                                End If
                                'Get value of Addr5
                                if ( not CustomerRet.BillAddress.Addr5 is nothing) then
                                        Dim Addr57656 as String
                                        Addr57656 = CustomerRet.BillAddress.Addr5.GetValue()
                                End If
                                'Get value of City
                                if ( not CustomerRet.BillAddress.City is nothing) then
                                        Dim City7657 as String
                                        City7657 = CustomerRet.BillAddress.City.GetValue()
                                End If
                                'Get value of State
                                if ( not CustomerRet.BillAddress.State is nothing) then
                                        Dim State7658 as String
                                        State7658 = CustomerRet.BillAddress.State.GetValue()
                                End If
                                'Get value of PostalCode
                                if ( not CustomerRet.BillAddress.PostalCode is nothing) then
                                        Dim PostalCode7659 as String
                                        PostalCode7659 = CustomerRet.BillAddress.PostalCode.GetValue()
                                End If
                                'Get value of Country
                                if ( not CustomerRet.BillAddress.Country is nothing) then
                                        Dim Country7660 as String
                                        Country7660 = CustomerRet.BillAddress.Country.GetValue()
                                End If
                                'Get value of Note
                                if ( not CustomerRet.BillAddress.Note is nothing) then
                                        Dim Note7661 as String
                                        Note7661 = CustomerRet.BillAddress.Note.GetValue()
                                End If
                        End If
                        if (not CustomerRet.BillAddressBlock. is nothing) then
                                'Get value of Addr1
                                if ( not CustomerRet.BillAddressBlock.Addr1 is nothing) then
                                        Dim Addr17662 as String
                                        Addr17662 = CustomerRet.BillAddressBlock.Addr1.GetValue()
                                End If
                                'Get value of Addr2
                                if ( not CustomerRet.BillAddressBlock.Addr2 is nothing) then
                                        Dim Addr27663 as String
                                        Addr27663 = CustomerRet.BillAddressBlock.Addr2.GetValue()
                                End If
                                'Get value of Addr3
                                if ( not CustomerRet.BillAddressBlock.Addr3 is nothing) then
                                        Dim Addr37664 as String
                                        Addr37664 = CustomerRet.BillAddressBlock.Addr3.GetValue()
                                End If
                                'Get value of Addr4
                                if ( not CustomerRet.BillAddressBlock.Addr4 is nothing) then
                                        Dim Addr47665 as String
                                        Addr47665 = CustomerRet.BillAddressBlock.Addr4.GetValue()
                                End If
                                'Get value of Addr5
                                if ( not CustomerRet.BillAddressBlock.Addr5 is nothing) then
                                        Dim Addr57666 as String
                                        Addr57666 = CustomerRet.BillAddressBlock.Addr5.GetValue()
                                End If
                        End If
                        if (not CustomerRet.ShipAddress. is nothing) then
                                'Get value of Addr1
                                if ( not CustomerRet.ShipAddress.Addr1 is nothing) then
                                        Dim Addr17667 as String
                                        Addr17667 = CustomerRet.ShipAddress.Addr1.GetValue()
                                End If
                                'Get value of Addr2
                                if ( not CustomerRet.ShipAddress.Addr2 is nothing) then
                                        Dim Addr27668 as String
                                        Addr27668 = CustomerRet.ShipAddress.Addr2.GetValue()
                                End If
                                'Get value of Addr3
                                if ( not CustomerRet.ShipAddress.Addr3 is nothing) then
                                        Dim Addr37669 as String
                                        Addr37669 = CustomerRet.ShipAddress.Addr3.GetValue()
                                End If
                                'Get value of Addr4
                                if ( not CustomerRet.ShipAddress.Addr4 is nothing) then
                                        Dim Addr47670 as String
                                        Addr47670 = CustomerRet.ShipAddress.Addr4.GetValue()
                                End If
                                'Get value of Addr5
                                if ( not CustomerRet.ShipAddress.Addr5 is nothing) then
                                        Dim Addr57671 as String
                                        Addr57671 = CustomerRet.ShipAddress.Addr5.GetValue()
                                End If
                                'Get value of City
                                if ( not CustomerRet.ShipAddress.City is nothing) then
                                        Dim City7672 as String
                                        City7672 = CustomerRet.ShipAddress.City.GetValue()
                                End If
                                'Get value of State
                                if ( not CustomerRet.ShipAddress.State is nothing) then
                                        Dim State7673 as String
                                        State7673 = CustomerRet.ShipAddress.State.GetValue()
                                End If
                                'Get value of PostalCode
                                if ( not CustomerRet.ShipAddress.PostalCode is nothing) then
                                        Dim PostalCode7674 as String
                                        PostalCode7674 = CustomerRet.ShipAddress.PostalCode.GetValue()
                                End If
                                'Get value of Country
                                if ( not CustomerRet.ShipAddress.Country is nothing) then
                                        Dim Country7675 as String
                                        Country7675 = CustomerRet.ShipAddress.Country.GetValue()
                                End If
                                'Get value of Note
                                if ( not CustomerRet.ShipAddress.Note is nothing) then
                                        Dim Note7676 as String
                                        Note7676 = CustomerRet.ShipAddress.Note.GetValue()
                                End If
                        End If
                        if (not CustomerRet.ShipAddressBlock. is nothing) then
                                'Get value of Addr1
                                if ( not CustomerRet.ShipAddressBlock.Addr1 is nothing) then
                                        Dim Addr17677 as String
                                        Addr17677 = CustomerRet.ShipAddressBlock.Addr1.GetValue()
                                End If
                                'Get value of Addr2
                                if ( not CustomerRet.ShipAddressBlock.Addr2 is nothing) then
                                        Dim Addr27678 as String
                                        Addr27678 = CustomerRet.ShipAddressBlock.Addr2.GetValue()
                                End If
                                'Get value of Addr3
                                if ( not CustomerRet.ShipAddressBlock.Addr3 is nothing) then
                                        Dim Addr37679 as String
                                        Addr37679 = CustomerRet.ShipAddressBlock.Addr3.GetValue()
                                End If
                                'Get value of Addr4
                                if ( not CustomerRet.ShipAddressBlock.Addr4 is nothing) then
                                        Dim Addr47680 as String
                                        Addr47680 = CustomerRet.ShipAddressBlock.Addr4.GetValue()
                                End If
                                'Get value of Addr5
                                if ( not CustomerRet.ShipAddressBlock.Addr5 is nothing) then
                                        Dim Addr57681 as String
                                        Addr57681 = CustomerRet.ShipAddressBlock.Addr5.GetValue()
                                End If
                        End If
                        if (not CustomerRet.ShipToAddressList is nothing)
                                Dim i7682 as Integer
                                for i7682 = 0  to CustomerRet.ShipToAddressList.Count - 1
                                        Dim ShipToAddress as IShipToAddress
                                        ShipToAddress = CustomerRet.ShipToAddressList.GetAt(i7682)
                                        'Get value of Name
                                        Dim Name7683 as String
                                        Name7683 = ShipToAddressName.GetValue()
                                        'Get value of Addr1
                                        if ( not ShipToAddressAddr1 is nothing) then
                                                Dim Addr17684 as String
                                                Addr17684 = ShipToAddressAddr1.GetValue()
                                        End If
                                        'Get value of Addr2
                                        if ( not ShipToAddressAddr2 is nothing) then
                                                Dim Addr27685 as String
                                                Addr27685 = ShipToAddressAddr2.GetValue()
                                        End If
                                        'Get value of Addr3
                                        if ( not ShipToAddressAddr3 is nothing) then
                                                Dim Addr37686 as String
                                                Addr37686 = ShipToAddressAddr3.GetValue()
                                        End If
                                        'Get value of Addr4
                                        if ( not ShipToAddressAddr4 is nothing) then
                                                Dim Addr47687 as String
                                                Addr47687 = ShipToAddressAddr4.GetValue()
                                        End If
                                        'Get value of Addr5
                                        if ( not ShipToAddressAddr5 is nothing) then
                                                Dim Addr57688 as String
                                                Addr57688 = ShipToAddressAddr5.GetValue()
                                        End If
                                        'Get value of City
                                        if ( not ShipToAddressCity is nothing) then
                                                Dim City7689 as String
                                                City7689 = ShipToAddressCity.GetValue()
                                        End If
                                        'Get value of State
                                        if ( not ShipToAddressState is nothing) then
                                                Dim State7690 as String
                                                State7690 = ShipToAddressState.GetValue()
                                        End If
                                        'Get value of PostalCode
                                        if ( not ShipToAddressPostalCode is nothing) then
                                                Dim PostalCode7691 as String
                                                PostalCode7691 = ShipToAddressPostalCode.GetValue()
                                        End If
                                        'Get value of Country
                                        if ( not ShipToAddressCountry is nothing) then
                                                Dim Country7692 as String
                                                Country7692 = ShipToAddressCountry.GetValue()
                                        End If
                                        'Get value of Note
                                        if ( not ShipToAddressNote is nothing) then
                                                Dim Note7693 as String
                                                Note7693 = ShipToAddressNote.GetValue()
                                        End If
                                        'Get value of DefaultShipTo
                                        if ( not ShipToAddressDefaultShipTo is nothing) then
                                                Dim DefaultShipTo7694 as Boolean
                                                DefaultShipTo7694 = ShipToAddressDefaultShipTo.GetValue()
                                        End If
                                Next i7682
                        End If
                        'Get value of Phone
                        if ( not CustomerRet.Phone is nothing) then
                                Dim Phone7695 as String
                                Phone7695 = CustomerRet.Phone.GetValue()
                        End If
                        'Get value of AltPhone
                        if ( not CustomerRet.AltPhone is nothing) then
                                Dim AltPhone7696 as String
                                AltPhone7696 = CustomerRet.AltPhone.GetValue()
                        End If
                        'Get value of Fax
                        if ( not CustomerRet.Fax is nothing) then
                                Dim Fax7697 as String
                                Fax7697 = CustomerRet.Fax.GetValue()
                        End If
                        'Get value of Email
                        if ( not CustomerRet.Email is nothing) then
                                Dim Email7698 as String
                                Email7698 = CustomerRet.Email.GetValue()
                        End If
                        'Get value of Cc
                        if ( not CustomerRet.Cc is nothing) then
                                Dim Cc7699 as String
                                Cc7699 = CustomerRet.Cc.GetValue()
                        End If
                        'Get value of Contact
                        if ( not CustomerRet.Contact is nothing) then
                                Dim Contact7700 as String
                                Contact7700 = CustomerRet.Contact.GetValue()
                        End If
                        'Get value of AltContact
                        if ( not CustomerRet.AltContact is nothing) then
                                Dim AltContact7701 as String
                                AltContact7701 = CustomerRet.AltContact.GetValue()
                        End If
                        if (not CustomerRet.AdditionalContactRefList is nothing)
                                Dim i7702 as Integer
                                for i7702 = 0  to CustomerRet.AdditionalContactRefList.Count - 1
                                        Dim QBBaseRef as IQBBaseRef
                                        QBBaseRef = CustomerRet.AdditionalContactRefList.GetAt(i7702)
                                        'Get value of ContactName
                                        Dim ContactName7703 as String
                                        ContactName7703 = QBBaseRefContactName.GetValue()
                                        'Get value of ContactValue
                                        Dim ContactValue7704 as String
                                        ContactValue7704 = QBBaseRefContactValue.GetValue()
                                Next i7702
                        End If
                        if (not CustomerRet.ContactsRetList is nothing)
                                Dim i7705 as Integer
                                for i7705 = 0  to CustomerRet.ContactsRetList.Count - 1
                                        Dim ContactsRet as IContactsRet
                                        ContactsRet = CustomerRet.ContactsRetList.GetAt(i7705)
                                        'Get value of ListID
                                        Dim ListID7706 as String
                                        ListID7706 = ContactsRetListID.GetValue()
                                        'Get value of TimeCreated
                                        Dim TimeCreated7707 as DateTime
                                        TimeCreated7707 = ContactsRetTimeCreated.GetValue()
                                        'Get value of TimeModified
                                        Dim TimeModified7708 as DateTime
                                        TimeModified7708 = ContactsRetTimeModified.GetValue()
                                        'Get value of EditSequence
                                        Dim EditSequence7709 as String
                                        EditSequence7709 = ContactsRetEditSequence.GetValue()
                                        'Get value of Contact
                                        if ( not ContactsRetContact is nothing) then
                                                Dim Contact7710 as String
                                                Contact7710 = ContactsRetContact.GetValue()
                                        End If
                                        'Get value of Salutation
                                        if ( not ContactsRetSalutation is nothing) then
                                                Dim Salutation7711 as String
                                                Salutation7711 = ContactsRetSalutation.GetValue()
                                        End If
                                        'Get value of FirstName
                                        Dim FirstName7712 as String
                                        FirstName7712 = ContactsRetFirstName.GetValue()
                                        'Get value of MiddleName
                                        if ( not ContactsRetMiddleName is nothing) then
                                                Dim MiddleName7713 as String
                                                MiddleName7713 = ContactsRetMiddleName.GetValue()
                                        End If
                                        'Get value of LastName
                                        if ( not ContactsRetLastName is nothing) then
                                                Dim LastName7714 as String
                                                LastName7714 = ContactsRetLastName.GetValue()
                                        End If
                                        'Get value of JobTitle
                                        if ( not ContactsRetJobTitle is nothing) then
                                                Dim JobTitle7715 as String
                                                JobTitle7715 = ContactsRetJobTitle.GetValue()
                                        End If
                                        if (not ContactsRetAdditionalContactRefList is nothing)
                                                Dim i7716 as Integer
                                                for i7716 = 0  to ContactsRetAdditionalContactRefList.Count - 1
                                                        Dim QBBaseRef as IQBBaseRef
                                                        QBBaseRef = ContactsRetAdditionalContactRefList.GetAt(i7716)
                                                        'Get value of ContactName
                                                        Dim ContactName7717 as String
                                                        ContactName7717 = QBBaseRefContactName.GetValue()
                                                        'Get value of ContactValue
                                                        Dim ContactValue7718 as String
                                                        ContactValue7718 = QBBaseRefContactValue.GetValue()
                                                Next i7716
                                        End If
                                Next i7705
                        End If
                        if (not CustomerRet.CustomerTypeRef. is nothing) then
                                'Get value of ListID
                                if ( not CustomerRet.CustomerTypeRef.ListID is nothing) then
                                        Dim ListID7719 as String
                                        ListID7719 = CustomerRet.CustomerTypeRef.ListID.GetValue()
                                End If
                                'Get value of FullName
                                if ( not CustomerRet.CustomerTypeRef.FullName is nothing) then
                                        Dim FullName7720 as String
                                        FullName7720 = CustomerRet.CustomerTypeRef.FullName.GetValue()
                                End If
                        End If
                        if (not CustomerRet.TermsRef. is nothing) then
                                'Get value of ListID
                                if ( not CustomerRet.TermsRef.ListID is nothing) then
                                        Dim ListID7721 as String
                                        ListID7721 = CustomerRet.TermsRef.ListID.GetValue()
                                End If
                                'Get value of FullName
                                if ( not CustomerRet.TermsRef.FullName is nothing) then
                                        Dim FullName7722 as String
                                        FullName7722 = CustomerRet.TermsRef.FullName.GetValue()
                                End If
                        End If
                        if (not CustomerRet.SalesRepRef. is nothing) then
                                'Get value of ListID
                                if ( not CustomerRet.SalesRepRef.ListID is nothing) then
                                        Dim ListID7723 as String
                                        ListID7723 = CustomerRet.SalesRepRef.ListID.GetValue()
                                End If
                                'Get value of FullName
                                if ( not CustomerRet.SalesRepRef.FullName is nothing) then
                                        Dim FullName7724 as String
                                        FullName7724 = CustomerRet.SalesRepRef.FullName.GetValue()
                                End If
                        End If
                        'Get value of Balance
                        if ( not CustomerRet.Balance is nothing) then
                                Dim Balance7725 as Double
                                Balance7725 = CustomerRet.Balance.GetValue()
                        End If
                        'Get value of TotalBalance
                        if ( not CustomerRet.TotalBalance is nothing) then
                                Dim TotalBalance7726 as Double
                                TotalBalance7726 = CustomerRet.TotalBalance.GetValue()
                        End If
                        if (not CustomerRet.SalesTaxCodeRef. is nothing) then
                                'Get value of ListID
                                if ( not CustomerRet.SalesTaxCodeRef.ListID is nothing) then
                                        Dim ListID7727 as String
                                        ListID7727 = CustomerRet.SalesTaxCodeRef.ListID.GetValue()
                                End If
                                'Get value of FullName
                                if ( not CustomerRet.SalesTaxCodeRef.FullName is nothing) then
                                        Dim FullName7728 as String
                                        FullName7728 = CustomerRet.SalesTaxCodeRef.FullName.GetValue()
                                End If
                        End If
                        if (not CustomerRet.ItemSalesTaxRef. is nothing) then
                                'Get value of ListID
                                if ( not CustomerRet.ItemSalesTaxRef.ListID is nothing) then
                                        Dim ListID7729 as String
                                        ListID7729 = CustomerRet.ItemSalesTaxRef.ListID.GetValue()
                                End If
                                'Get value of FullName
                                if ( not CustomerRet.ItemSalesTaxRef.FullName is nothing) then
                                        Dim FullName7730 as String
                                        FullName7730 = CustomerRet.ItemSalesTaxRef.FullName.GetValue()
                                End If
                        End If
                        'Get value of SalesTaxCountry
                        if ( not CustomerRet.SalesTaxCountry is nothing) then
                                Dim SalesTaxCountry7731 as ENSalesTaxCountry
                                SalesTaxCountry7731 = CustomerRet.SalesTaxCountry.GetValue()
                        End If
                        'Get value of ResaleNumber
                        if ( not CustomerRet.ResaleNumber is nothing) then
                                Dim ResaleNumber7732 as String
                                ResaleNumber7732 = CustomerRet.ResaleNumber.GetValue()
                        End If
                        'Get value of AccountNumber
                        if ( not CustomerRet.AccountNumber is nothing) then
                                Dim AccountNumber7733 as String
                                AccountNumber7733 = CustomerRet.AccountNumber.GetValue()
                        End If
                        'Get value of CreditLimit
                        if ( not CustomerRet.CreditLimit is nothing) then
                                Dim CreditLimit7734 as Double
                                CreditLimit7734 = CustomerRet.CreditLimit.GetValue()
                        End If
                        if (not CustomerRet.PreferredPaymentMethodRef. is nothing) then
                                'Get value of ListID
                                if ( not CustomerRet.PreferredPaymentMethodRef.ListID is nothing) then
                                        Dim ListID7735 as String
                                        ListID7735 = CustomerRet.PreferredPaymentMethodRef.ListID.GetValue()
                                End If
                                'Get value of FullName
                                if ( not CustomerRet.PreferredPaymentMethodRef.FullName is nothing) then
                                        Dim FullName7736 as String
                                        FullName7736 = CustomerRet.PreferredPaymentMethodRef.FullName.GetValue()
                                End If
                        End If
                        if (not CustomerRet.CreditCardInfo. is nothing) then
                                'Get value of CreditCardNumber
                                if ( not CustomerRet.CreditCardInfo.CreditCardNumber is nothing) then
                                        Dim CreditCardNumber7737 as String
                                        CreditCardNumber7737 = CustomerRet.CreditCardInfo.CreditCardNumber.GetValue()
                                End If
                                'Get value of ExpirationMonth
                                if ( not CustomerRet.CreditCardInfo.ExpirationMonth is nothing) then
                                        Dim ExpirationMonth7738 as Integer
                                        ExpirationMonth7738 = CustomerRet.CreditCardInfo.ExpirationMonth.GetValue()
                                End If
                                'Get value of ExpirationYear
                                if ( not CustomerRet.CreditCardInfo.ExpirationYear is nothing) then
                                        Dim ExpirationYear7739 as Integer
                                        ExpirationYear7739 = CustomerRet.CreditCardInfo.ExpirationYear.GetValue()
                                End If
                                'Get value of NameOnCard
                                if ( not CustomerRet.CreditCardInfo.NameOnCard is nothing) then
                                        Dim NameOnCard7740 as String
                                        NameOnCard7740 = CustomerRet.CreditCardInfo.NameOnCard.GetValue()
                                End If
                                'Get value of CreditCardAddress
                                if ( not CustomerRet.CreditCardInfo.CreditCardAddress is nothing) then
                                        Dim CreditCardAddress7741 as String
                                        CreditCardAddress7741 = CustomerRet.CreditCardInfo.CreditCardAddress.GetValue()
                                End If
                                'Get value of CreditCardPostalCode
                                if ( not CustomerRet.CreditCardInfo.CreditCardPostalCode is nothing) then
                                        Dim CreditCardPostalCode7742 as String
                                        CreditCardPostalCode7742 = CustomerRet.CreditCardInfo.CreditCardPostalCode.GetValue()
                                End If
                        End If
                        'Get value of JobStatus
                        if ( not CustomerRet.JobStatus is nothing) then
                                Dim JobStatus7743 as ENJobStatus
                                JobStatus7743 = CustomerRet.JobStatus.GetValue()
                        End If
                        'Get value of JobStartDate
                        if ( not CustomerRet.JobStartDate is nothing) then
                                Dim JobStartDate7744 as DateTime
                                JobStartDate7744 = CustomerRet.JobStartDate.GetValue()
                        End If
                        'Get value of JobProjectedEndDate
                        if ( not CustomerRet.JobProjectedEndDate is nothing) then
                                Dim JobProjectedEndDate7745 as DateTime
                                JobProjectedEndDate7745 = CustomerRet.JobProjectedEndDate.GetValue()
                        End If
                        'Get value of JobEndDate
                        if ( not CustomerRet.JobEndDate is nothing) then
                                Dim JobEndDate7746 as DateTime
                                JobEndDate7746 = CustomerRet.JobEndDate.GetValue()
                        End If
                        'Get value of JobDesc
                        if ( not CustomerRet.JobDesc is nothing) then
                                Dim JobDesc7747 as String
                                JobDesc7747 = CustomerRet.JobDesc.GetValue()
                        End If
                        if (not CustomerRet.JobTypeRef. is nothing) then
                                'Get value of ListID
                                if ( not CustomerRet.JobTypeRef.ListID is nothing) then
                                        Dim ListID7748 as String
                                        ListID7748 = CustomerRet.JobTypeRef.ListID.GetValue()
                                End If
                                'Get value of FullName
                                if ( not CustomerRet.JobTypeRef.FullName is nothing) then
                                        Dim FullName7749 as String
                                        FullName7749 = CustomerRet.JobTypeRef.FullName.GetValue()
                                End If
                        End If
                        'Get value of Notes
                        if ( not CustomerRet.Notes is nothing) then
                                Dim Notes7750 as String
                                Notes7750 = CustomerRet.Notes.GetValue()
                        End If
                        if (not CustomerRet.AdditionalNotesRetList is nothing)
                                Dim i7751 as Integer
                                for i7751 = 0  to CustomerRet.AdditionalNotesRetList.Count - 1
                                        Dim AdditionalNotesRet as IAdditionalNotesRet
                                        AdditionalNotesRet = CustomerRet.AdditionalNotesRetList.GetAt(i7751)
                                        'Get value of NoteID
                                        Dim NoteID7752 as Integer
                                        NoteID7752 = AdditionalNotesRetNoteID.GetValue()
                                        'Get value of Date
                                        Dim Date7753 as DateTime
                                        Date7753 = AdditionalNotesRetDate.GetValue()
                                        'Get value of Note
                                        Dim Note7754 as String
                                        Note7754 = AdditionalNotesRetNote.GetValue()
                                Next i7751
                        End If
                        'Get value of PreferredDeliveryMethod
                        if ( not CustomerRet.PreferredDeliveryMethod is nothing) then
                                Dim PreferredDeliveryMethod7755 as ENPreferredDeliveryMethod
                                PreferredDeliveryMethod7755 = CustomerRet.PreferredDeliveryMethod.GetValue()
                        End If
                        if (not CustomerRet.PriceLevelRef. is nothing) then
                                'Get value of ListID
                                if ( not CustomerRet.PriceLevelRef.ListID is nothing) then
                                        Dim ListID7756 as String
                                        ListID7756 = CustomerRet.PriceLevelRef.ListID.GetValue()
                                End If
                                'Get value of FullName
                                if ( not CustomerRet.PriceLevelRef.FullName is nothing) then
                                        Dim FullName7757 as String
                                        FullName7757 = CustomerRet.PriceLevelRef.FullName.GetValue()
                                End If
                        End If
                        'Get value of ExternalGUID
                        if ( not CustomerRet.ExternalGUID is nothing) then
                                Dim ExternalGUID7758 as String
                                ExternalGUID7758 = CustomerRet.ExternalGUID.GetValue()
                        End If
                        'Get value of TaxRegistrationNumber
                        if ( not CustomerRet.TaxRegistrationNumber is nothing) then
                                Dim TaxRegistrationNumber7759 as String
                                TaxRegistrationNumber7759 = CustomerRet.TaxRegistrationNumber.GetValue()
                        End If
                        if (not CustomerRet.CurrencyRef. is nothing) then
                                'Get value of ListID
                                if ( not CustomerRet.CurrencyRef.ListID is nothing) then
                                        Dim ListID7760 as String
                                        ListID7760 = CustomerRet.CurrencyRef.ListID.GetValue()
                                End If
                                'Get value of FullName
                                if ( not CustomerRet.CurrencyRef.FullName is nothing) then
                                        Dim FullName7761 as String
                                        FullName7761 = CustomerRet.CurrencyRef.FullName.GetValue()
                                End If
                        End If
                        if (not CustomerRet.DataExtRetList is nothing)
                                Dim i7762 as Integer
                                for i7762 = 0  to CustomerRet.DataExtRetList.Count - 1
                                        Dim DataExtRet as IDataExtRet
                                        DataExtRet = CustomerRet.DataExtRetList.GetAt(i7762)
                                        'Get value of OwnerID
                                        if ( not DataExtRetOwnerID is nothing) then
                                                Dim OwnerID7763 as String
                                                OwnerID7763 = DataExtRetOwnerID.GetValue()
                                        End If
                                        'Get value of DataExtName
                                        Dim DataExtName7764 as String
                                        DataExtName7764 = DataExtRetDataExtName.GetValue()
                                        'Get value of DataExtType
                                        Dim DataExtType7765 as ENDataExtType
                                        DataExtType7765 = DataExtRetDataExtType.GetValue()
                                        'Get value of DataExtValue
                                        Dim DataExtValue7766 as String
                                        DataExtValue7766 = DataExtRetDataExtValue.GetValue()
                                Next i7762
                        End If
                End Sub




        End Class
End Module

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
//The following sample code is generated as an illustration of
//Creating requests and parsing responses ONLY
//This code is NOT intended to show best practices or ideal code
//Use at your most careful discretion

using System;
using System.Net;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using System.Data;
using System.IO;
using Interop.QBFC16;

namespace com.intuit.idn.samples
{
        public class Sample
        {
                public void  DoCustomerQuery()
                {
                        bool sessionBegun = false;
                        bool connectionOpen = false;
                        QBSessionManager sessionManager = null;

                        try
                        {
                                //Create the session Manager object
                                sessionManager = new QBSessionManager();

                                //Create the message set request object to hold our request
                                IMsgSetRequest requestMsgSet = sessionManager.CreateMsgSetRequest("US",16,0);
                                requestMsgSet.Attributes.OnError = ENRqOnError.roeContinue;

                                BuildCustomerQueryRq(requestMsgSet);

                                //Connect to QuickBooks and begin a session
                                sessionManager.OpenConnection("","Sample Code from OSR");
                                connectionOpen = true;
                                sessionManager.BeginSession("", ENOpenMode.omDontCare);
                                sessionBegun = true;

                                //Send the request and get the response from QuickBooks
                                IMsgSetResponse responseMsgSet = sessionManager.DoRequests(requestMsgSet);

                                //End the session and close the connection to QuickBooks
                                sessionManager.EndSession();
                                sessionBegun = false;
                                sessionManager.CloseConnection();
                                connectionOpen = false;

                                WalkCustomerQueryRs(responseMsgSet);
                        }
                        catch (Exception e)
                        {
                                MessageBox.Show(e.Message, "Error");
                                if (sessionBegun)
                                {
                                        sessionManager.EndSession();
                                }
                                if (connectionOpen)
                                {
                                        sessionManager.CloseConnection();
                                }
                        }
                }
                void BuildCustomerQueryRq(IMsgSetRequest requestMsgSet)
                {
                        ICustomerQuery CustomerQueryRq= requestMsgSet.AppendCustomerQueryRq();
                        //Set attributes
                        //Set field value for metaData
                        CustomerQueryRq.metaData.SetValue("IQBENmetaDataType");
                        //Set field value for iterator
                        CustomerQueryRq.iterator.SetValue("IQBENiteratorType");
                        //Set field value for iteratorID
                        CustomerQueryRq.iteratorID.SetValue("IQBUUIDType");
                        string ORCustomerListQueryElementType7493 = "ListIDList";
                        if (ORCustomerListQueryElementType7493 == "ListIDList")
                        {
                                //Set field value for ListIDList
                                //May create more than one of these if needed
                                CustomerQueryRq.ORCustomerListQuery.ListIDList.Add("200000-1011023419");
                        }
                        if (ORCustomerListQueryElementType7493 == "FullNameList")
                        {
                                //Set field value for FullNameList
                                //May create more than one of these if needed
                                CustomerQueryRq.ORCustomerListQuery.FullNameList.Add("ab");
                        }
                        if (ORCustomerListQueryElementType7493 == "CustomerListFilter")
                        {
                                //Set field value for MaxReturned
                                CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.MaxReturned.SetValue(6);
                                //Set field value for ActiveStatus
                                CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ActiveStatus.SetValue(ENActiveStatus.asActiveOnly [DEFAULT]);
                                //Set field value for FromModifiedDate
                                CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.FromModifiedDate.SetValue(DateTime.Parse("12/15/2007 12:15:12"),false);
                                //Set field value for ToModifiedDate
                                CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ToModifiedDate.SetValue(DateTime.Parse("12/15/2007 12:15:12"),false);
                                string ORNameFilterElementType7494 = "NameFilter";
                                if (ORNameFilterElementType7494 == "NameFilter")
                                {
                                        //Set field value for MatchCriterion
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ORNameFilter.NameFilter.MatchCriterion.SetValue(ENMatchCriterion.mcStartsWith);
                                        //Set field value for Name
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ORNameFilter.NameFilter.Name.SetValue("ab");
                                }
                                if (ORNameFilterElementType7494 == "NameRangeFilter")
                                {
                                        //Set field value for FromName
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ORNameFilter.NameRangeFilter.FromName.SetValue("ab");
                                        //Set field value for ToName
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ORNameFilter.NameRangeFilter.ToName.SetValue("ab");
                                }
                                //Set field value for Operator
                                CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.TotalBalanceFilter.Operator.SetValue(ENOperator.oLessThan);
                                //Set field value for Amount
                                CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.TotalBalanceFilter.Amount.SetValue(10.01);
                                string ORCurrencyFilterElementType7495 = "ListIDList";
                                if (ORCurrencyFilterElementType7495 == "ListIDList")
                                {
                                        //Set field value for ListIDList
                                        //May create more than one of these if needed
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.CurrencyFilter.ORCurrencyFilter.ListIDList.Add("200000-1011023419");
                                }
                                if (ORCurrencyFilterElementType7495 == "FullNameList")
                                {
                                        //Set field value for FullNameList
                                        //May create more than one of these if needed
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.CurrencyFilter.ORCurrencyFilter.FullNameList.Add("ab");
                                }
                                string ORClassFilterElementType7496 = "ListIDList";
                                if (ORClassFilterElementType7496 == "ListIDList")
                                {
                                        //Set field value for ListIDList
                                        //May create more than one of these if needed
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ClassFilter.ORClassFilter.ListIDList.Add("200000-1011023419");
                                }
                                if (ORClassFilterElementType7496 == "FullNameList")
                                {
                                        //Set field value for FullNameList
                                        //May create more than one of these if needed
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ClassFilter.ORClassFilter.FullNameList.Add("ab");
                                }
                                if (ORClassFilterElementType7496 == "ListIDWithChildren")
                                {
                                        //Set field value for ListIDWithChildren
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ClassFilter.ORClassFilter.ListIDWithChildren.SetValue("200000-1011023419");
                                }
                                if (ORClassFilterElementType7496 == "FullNameWithChildren")
                                {
                                        //Set field value for FullNameWithChildren
                                        CustomerQueryRq.ORCustomerListQuery.CustomerListFilter.ClassFilter.ORClassFilter.FullNameWithChildren.SetValue("ab");
                                }
                        }
                        //Set field value for IncludeRetElementList
                        //May create more than one of these if needed
                        CustomerQueryRq.IncludeRetElementList.Add("ab");
                        //Set field value for OwnerIDList
                        //May create more than one of these if needed
                        CustomerQueryRq.OwnerIDList.Add(Guid.NewGuid().ToString());
                }




                void WalkCustomerQueryRs(IMsgSetResponse responseMsgSet)
                {
                        if (responseMsgSet == null) return;
                        IResponseList responseList = responseMsgSet.ResponseList;
                        if (responseList == null) return;
                        //if we sent only one request, there is only one response, we'll walk the list for this sample
                        for(int i=0; i < responseList.Count; i++)
                        {
                                IResponse response = responseList.GetAt(i);
                                //check the status code of the response, 0=ok, >0 is warning
                                if (response.StatusCode >= 0)
                                {
                                        //the request-specific response is in the details, make sure we have some
                                        if (response.Detail != null)
                                        {
                                                //make sure the response is the type we're expecting
                                                ENResponseType responseType = (ENResponseType)response.Type.GetValue();
                                                if (responseType == ENResponseType.rtCustomerQueryRs)
                                                {
                                                        //upcast to more specific type here, this is safe because we checked with response.Type check above
                                                        ICustomerRetList CustomerRet = (ICustomerRetList)response.Detail;
                                                        WalkCustomerRet(CustomerRet.GetAt(i));
                                                }
                                        }
                                }
                        }
                }




                void WalkCustomerRet(ICustomerRet CustomerRet)
                {
                        if (CustomerRet == null) return;
                        //Go through all the elements of ICustomerRetList
                        //Get value of ListID
                        string ListID7497 = (string)CustomerRet.ListID.GetValue();
                        //Get value of TimeCreated
                        DateTime TimeCreated7498 = (DateTime)CustomerRet.TimeCreated.GetValue();
                        //Get value of TimeModified
                        DateTime TimeModified7499 = (DateTime)CustomerRet.TimeModified.GetValue();
                        //Get value of EditSequence
                        string EditSequence7500 = (string)CustomerRet.EditSequence.GetValue();
                        //Get value of Name
                        string Name7501 = (string)CustomerRet.Name.GetValue();
                        //Get value of FullName
                        string FullName7502 = (string)CustomerRet.FullName.GetValue();
                        //Get value of IsActive
                        if (CustomerRet.IsActive != null)
                        {
                                bool IsActive7503 = (bool)CustomerRet.IsActive.GetValue();
                        }
                        if (CustomerRet.ClassRef != null)
                        {
                                //Get value of ListID
                                if (CustomerRet.ClassRef.ListID != null)
                                {
                                        string ListID7504 = (string)CustomerRet.ClassRef.ListID.GetValue();
                                }
                                //Get value of FullName
                                if (CustomerRet.ClassRef.FullName != null)
                                {
                                        string FullName7505 = (string)CustomerRet.ClassRef.FullName.GetValue();
                                }
                        }
                        if (CustomerRet.ParentRef != null)
                        {
                                //Get value of ListID
                                if (CustomerRet.ParentRef.ListID != null)
                                {
                                        string ListID7506 = (string)CustomerRet.ParentRef.ListID.GetValue();
                                }
                                //Get value of FullName
                                if (CustomerRet.ParentRef.FullName != null)
                                {
                                        string FullName7507 = (string)CustomerRet.ParentRef.FullName.GetValue();
                                }
                        }
                        //Get value of Sublevel
                        int Sublevel7508 = (int)CustomerRet.Sublevel.GetValue();
                        //Get value of CompanyName
                        if (CustomerRet.CompanyName != null)
                        {
                                string CompanyName7509 = (string)CustomerRet.CompanyName.GetValue();
                        }
                        //Get value of Salutation
                        if (CustomerRet.Salutation != null)
                        {
                                string Salutation7510 = (string)CustomerRet.Salutation.GetValue();
                        }
                        //Get value of FirstName
                        if (CustomerRet.FirstName != null)
                        {
                                string FirstName7511 = (string)CustomerRet.FirstName.GetValue();
                        }
                        //Get value of MiddleName
                        if (CustomerRet.MiddleName != null)
                        {
                                string MiddleName7512 = (string)CustomerRet.MiddleName.GetValue();
                        }
                        //Get value of LastName
                        if (CustomerRet.LastName != null)
                        {
                                string LastName7513 = (string)CustomerRet.LastName.GetValue();
                        }
                        //Get value of JobTitle
                        if (CustomerRet.JobTitle != null)
                        {
                                string JobTitle7514 = (string)CustomerRet.JobTitle.GetValue();
                        }
                        if (CustomerRet.BillAddress != null)
                        {
                                //Get value of Addr1
                                if (CustomerRet.BillAddress.Addr1 != null)
                                {
                                        string Addr17515 = (string)CustomerRet.BillAddress.Addr1.GetValue();
                                }
                                //Get value of Addr2
                                if (CustomerRet.BillAddress.Addr2 != null)
                                {
                                        string Addr27516 = (string)CustomerRet.BillAddress.Addr2.GetValue();
                                }
                                //Get value of Addr3
                                if (CustomerRet.BillAddress.Addr3 != null)
                                {
                                        string Addr37517 = (string)CustomerRet.BillAddress.Addr3.GetValue();
                                }
                                //Get value of Addr4
                                if (CustomerRet.BillAddress.Addr4 != null)
                                {
                                        string Addr47518 = (string)CustomerRet.BillAddress.Addr4.GetValue();
                                }
                                //Get value of Addr5
                                if (CustomerRet.BillAddress.Addr5 != null)
                                {
                                        string Addr57519 = (string)CustomerRet.BillAddress.Addr5.GetValue();
                                }
                                //Get value of City
                                if (CustomerRet.BillAddress.City != null)
                                {
                                        string City7520 = (string)CustomerRet.BillAddress.City.GetValue();
                                }
                                //Get value of State
                                if (CustomerRet.BillAddress.State != null)
                                {
                                        string State7521 = (string)CustomerRet.BillAddress.State.GetValue();
                                }
                                //Get value of PostalCode
                                if (CustomerRet.BillAddress.PostalCode != null)
                                {
                                        string PostalCode7522 = (string)CustomerRet.BillAddress.PostalCode.GetValue();
                                }
                                //Get value of Country
                                if (CustomerRet.BillAddress.Country != null)
                                {
                                        string Country7523 = (string)CustomerRet.BillAddress.Country.GetValue();
                                }
                                //Get value of Note
                                if (CustomerRet.BillAddress.Note != null)
                                {
                                        string Note7524 = (string)CustomerRet.BillAddress.Note.GetValue();
                                }
                        }
                        if (CustomerRet.BillAddressBlock != null)
                        {
                                //Get value of Addr1
                                if (CustomerRet.BillAddressBlock.Addr1 != null)
                                {
                                        string Addr17525 = (string)CustomerRet.BillAddressBlock.Addr1.GetValue();
                                }
                                //Get value of Addr2
                                if (CustomerRet.BillAddressBlock.Addr2 != null)
                                {
                                        string Addr27526 = (string)CustomerRet.BillAddressBlock.Addr2.GetValue();
                                }
                                //Get value of Addr3
                                if (CustomerRet.BillAddressBlock.Addr3 != null)
                                {
                                        string Addr37527 = (string)CustomerRet.BillAddressBlock.Addr3.GetValue();
                                }
                                //Get value of Addr4
                                if (CustomerRet.BillAddressBlock.Addr4 != null)
                                {
                                        string Addr47528 = (string)CustomerRet.BillAddressBlock.Addr4.GetValue();
                                }
                                //Get value of Addr5
                                if (CustomerRet.BillAddressBlock.Addr5 != null)
                                {
                                        string Addr57529 = (string)CustomerRet.BillAddressBlock.Addr5.GetValue();
                                }
                        }
                        if (CustomerRet.ShipAddress != null)
                        {
                                //Get value of Addr1
                                if (CustomerRet.ShipAddress.Addr1 != null)
                                {
                                        string Addr17530 = (string)CustomerRet.ShipAddress.Addr1.GetValue();
                                }
                                //Get value of Addr2
                                if (CustomerRet.ShipAddress.Addr2 != null)
                                {
                                        string Addr27531 = (string)CustomerRet.ShipAddress.Addr2.GetValue();
                                }
                                //Get value of Addr3
                                if (CustomerRet.ShipAddress.Addr3 != null)
                                {
                                        string Addr37532 = (string)CustomerRet.ShipAddress.Addr3.GetValue();
                                }
                                //Get value of Addr4
                                if (CustomerRet.ShipAddress.Addr4 != null)
                                {
                                        string Addr47533 = (string)CustomerRet.ShipAddress.Addr4.GetValue();
                                }
                                //Get value of Addr5
                                if (CustomerRet.ShipAddress.Addr5 != null)
                                {
                                        string Addr57534 = (string)CustomerRet.ShipAddress.Addr5.GetValue();
                                }
                                //Get value of City
                                if (CustomerRet.ShipAddress.City != null)
                                {
                                        string City7535 = (string)CustomerRet.ShipAddress.City.GetValue();
                                }
                                //Get value of State
                                if (CustomerRet.ShipAddress.State != null)
                                {
                                        string State7536 = (string)CustomerRet.ShipAddress.State.GetValue();
                                }
                                //Get value of PostalCode
                                if (CustomerRet.ShipAddress.PostalCode != null)
                                {
                                        string PostalCode7537 = (string)CustomerRet.ShipAddress.PostalCode.GetValue();
                                }
                                //Get value of Country
                                if (CustomerRet.ShipAddress.Country != null)
                                {
                                        string Country7538 = (string)CustomerRet.ShipAddress.Country.GetValue();
                                }
                                //Get value of Note
                                if (CustomerRet.ShipAddress.Note != null)
                                {
                                        string Note7539 = (string)CustomerRet.ShipAddress.Note.GetValue();
                                }
                        }
                        if (CustomerRet.ShipAddressBlock != null)
                        {
                                //Get value of Addr1
                                if (CustomerRet.ShipAddressBlock.Addr1 != null)
                                {
                                        string Addr17540 = (string)CustomerRet.ShipAddressBlock.Addr1.GetValue();
                                }
                                //Get value of Addr2
                                if (CustomerRet.ShipAddressBlock.Addr2 != null)
                                {
                                        string Addr27541 = (string)CustomerRet.ShipAddressBlock.Addr2.GetValue();
                                }
                                //Get value of Addr3
                                if (CustomerRet.ShipAddressBlock.Addr3 != null)
                                {
                                        string Addr37542 = (string)CustomerRet.ShipAddressBlock.Addr3.GetValue();
                                }
                                //Get value of Addr4
                                if (CustomerRet.ShipAddressBlock.Addr4 != null)
                                {
                                        string Addr47543 = (string)CustomerRet.ShipAddressBlock.Addr4.GetValue();
                                }
                                //Get value of Addr5
                                if (CustomerRet.ShipAddressBlock.Addr5 != null)
                                {
                                        string Addr57544 = (string)CustomerRet.ShipAddressBlock.Addr5.GetValue();
                                }
                        }
                        if (CustomerRet.ShipToAddressList != null)
                        {
                                for (int i7545 = 0; i7545 < CustomerRet.ShipToAddressList.Count; i7545++)
                                {
                                        IShipToAddress ShipToAddress = CustomerRet.ShipToAddressList.GetAt(i7545);
                                        //Get value of Name
                                        string Name7546 = (string)ShipToAddress.Name.GetValue();
                                        //Get value of Addr1
                                        if (ShipToAddress.Addr1 != null)
                                        {
                                                string Addr17547 = (string)ShipToAddress.Addr1.GetValue();
                                        }
                                        //Get value of Addr2
                                        if (ShipToAddress.Addr2 != null)
                                        {
                                                string Addr27548 = (string)ShipToAddress.Addr2.GetValue();
                                        }
                                        //Get value of Addr3
                                        if (ShipToAddress.Addr3 != null)
                                        {
                                                string Addr37549 = (string)ShipToAddress.Addr3.GetValue();
                                        }
                                        //Get value of Addr4
                                        if (ShipToAddress.Addr4 != null)
                                        {
                                                string Addr47550 = (string)ShipToAddress.Addr4.GetValue();
                                        }
                                        //Get value of Addr5
                                        if (ShipToAddress.Addr5 != null)
                                        {
                                                string Addr57551 = (string)ShipToAddress.Addr5.GetValue();
                                        }
                                        //Get value of City
                                        if (ShipToAddress.City != null)
                                        {
                                                string City7552 = (string)ShipToAddress.City.GetValue();
                                        }
                                        //Get value of State
                                        if (ShipToAddress.State != null)
                                        {
                                                string State7553 = (string)ShipToAddress.State.GetValue();
                                        }
                                        //Get value of PostalCode
                                        if (ShipToAddress.PostalCode != null)
                                        {
                                                string PostalCode7554 = (string)ShipToAddress.PostalCode.GetValue();
                                        }
                                        //Get value of Country
                                        if (ShipToAddress.Country != null)
                                        {
                                                string Country7555 = (string)ShipToAddress.Country.GetValue();
                                        }
                                        //Get value of Note
                                        if (ShipToAddress.Note != null)
                                        {
                                                string Note7556 = (string)ShipToAddress.Note.GetValue();
                                        }
                                        //Get value of DefaultShipTo
                                        if (ShipToAddress.DefaultShipTo != null)
                                        {
                                                bool DefaultShipTo7557 = (bool)ShipToAddress.DefaultShipTo.GetValue();
                                        }
                                }
                        }
                        //Get value of Phone
                        if (CustomerRet.Phone != null)
                        {
                                string Phone7558 = (string)CustomerRet.Phone.GetValue();
                        }
                        //Get value of AltPhone
                        if (CustomerRet.AltPhone != null)
                        {
                                string AltPhone7559 = (string)CustomerRet.AltPhone.GetValue();
                        }
                        //Get value of Fax
                        if (CustomerRet.Fax != null)
                        {
                                string Fax7560 = (string)CustomerRet.Fax.GetValue();
                        }
                        //Get value of Email
                        if (CustomerRet.Email != null)
                        {
                                string Email7561 = (string)CustomerRet.Email.GetValue();
                        }
                        //Get value of Cc
                        if (CustomerRet.Cc != null)
                        {
                                string Cc7562 = (string)CustomerRet.Cc.GetValue();
                        }
                        //Get value of Contact
                        if (CustomerRet.Contact != null)
                        {
                                string Contact7563 = (string)CustomerRet.Contact.GetValue();
                        }
                        //Get value of AltContact
                        if (CustomerRet.AltContact != null)
                        {
                                string AltContact7564 = (string)CustomerRet.AltContact.GetValue();
                        }
                        if (CustomerRet.AdditionalContactRefList != null)
                        {
                                for (int i7565 = 0; i7565 < CustomerRet.AdditionalContactRefList.Count; i7565++)
                                {
                                        IQBBaseRef QBBaseRef = CustomerRet.AdditionalContactRefList.GetAt(i7565);
                                        //Get value of ContactName
                                        string ContactName7566 = (string)QBBaseRef.ContactName.GetValue();
                                        //Get value of ContactValue
                                        string ContactValue7567 = (string)QBBaseRef.ContactValue.GetValue();
                                }
                        }
                        if (CustomerRet.ContactsRetList != null)
                        {
                                for (int i7568 = 0; i7568 < CustomerRet.ContactsRetList.Count; i7568++)
                                {
                                        IContactsRet ContactsRet = CustomerRet.ContactsRetList.GetAt(i7568);
                                        //Get value of ListID
                                        string ListID7569 = (string)ContactsRet.ListID.GetValue();
                                        //Get value of TimeCreated
                                        DateTime TimeCreated7570 = (DateTime)ContactsRet.TimeCreated.GetValue();
                                        //Get value of TimeModified
                                        DateTime TimeModified7571 = (DateTime)ContactsRet.TimeModified.GetValue();
                                        //Get value of EditSequence
                                        string EditSequence7572 = (string)ContactsRet.EditSequence.GetValue();
                                        //Get value of Contact
                                        if (ContactsRet.Contact != null)
                                        {
                                                string Contact7573 = (string)ContactsRet.Contact.GetValue();
                                        }
                                        //Get value of Salutation
                                        if (ContactsRet.Salutation != null)
                                        {
                                                string Salutation7574 = (string)ContactsRet.Salutation.GetValue();
                                        }
                                        //Get value of FirstName
                                        string FirstName7575 = (string)ContactsRet.FirstName.GetValue();
                                        //Get value of MiddleName
                                        if (ContactsRet.MiddleName != null)
                                        {
                                                string MiddleName7576 = (string)ContactsRet.MiddleName.GetValue();
                                        }
                                        //Get value of LastName
                                        if (ContactsRet.LastName != null)
                                        {
                                                string LastName7577 = (string)ContactsRet.LastName.GetValue();
                                        }
                                        //Get value of JobTitle
                                        if (ContactsRet.JobTitle != null)
                                        {
                                                string JobTitle7578 = (string)ContactsRet.JobTitle.GetValue();
                                        }
                                        if (ContactsRet.AdditionalContactRefList != null)
                                        {
                                                for (int i7579 = 0; i7579 < ContactsRet.AdditionalContactRefList.Count; i7579++)
                                                {
                                                        IQBBaseRef QBBaseRef = ContactsRet.AdditionalContactRefList.GetAt(i7579);
                                                        //Get value of ContactName
                                                        string ContactName7580 = (string)QBBaseRef.ContactName.GetValue();
                                                        //Get value of ContactValue
                                                        string ContactValue7581 = (string)QBBaseRef.ContactValue.GetValue();
                                                }
                                        }
                                }
                        }
                        if (CustomerRet.CustomerTypeRef != null)
                        {
                                //Get value of ListID
                                if (CustomerRet.CustomerTypeRef.ListID != null)
                                {
                                        string ListID7582 = (string)CustomerRet.CustomerTypeRef.ListID.GetValue();
                                }
                                //Get value of FullName
                                if (CustomerRet.CustomerTypeRef.FullName != null)
                                {
                                        string FullName7583 = (string)CustomerRet.CustomerTypeRef.FullName.GetValue();
                                }
                        }
                        if (CustomerRet.TermsRef != null)
                        {
                                //Get value of ListID
                                if (CustomerRet.TermsRef.ListID != null)
                                {
                                        string ListID7584 = (string)CustomerRet.TermsRef.ListID.GetValue();
                                }
                                //Get value of FullName
                                if (CustomerRet.TermsRef.FullName != null)
                                {
                                        string FullName7585 = (string)CustomerRet.TermsRef.FullName.GetValue();
                                }
                        }
                        if (CustomerRet.SalesRepRef != null)
                        {
                                //Get value of ListID
                                if (CustomerRet.SalesRepRef.ListID != null)
                                {
                                        string ListID7586 = (string)CustomerRet.SalesRepRef.ListID.GetValue();
                                }
                                //Get value of FullName
                                if (CustomerRet.SalesRepRef.FullName != null)
                                {
                                        string FullName7587 = (string)CustomerRet.SalesRepRef.FullName.GetValue();
                                }
                        }
                        //Get value of Balance
                        if (CustomerRet.Balance != null)
                        {
                                double Balance7588 = (double)CustomerRet.Balance.GetValue();
                        }
                        //Get value of TotalBalance
                        if (CustomerRet.TotalBalance != null)
                        {
                                double TotalBalance7589 = (double)CustomerRet.TotalBalance.GetValue();
                        }
                        if (CustomerRet.SalesTaxCodeRef != null)
                        {
                                //Get value of ListID
                                if (CustomerRet.SalesTaxCodeRef.ListID != null)
                                {
                                        string ListID7590 = (string)CustomerRet.SalesTaxCodeRef.ListID.GetValue();
                                }
                                //Get value of FullName
                                if (CustomerRet.SalesTaxCodeRef.FullName != null)
                                {
                                        string FullName7591 = (string)CustomerRet.SalesTaxCodeRef.FullName.GetValue();
                                }
                        }
                        if (CustomerRet.ItemSalesTaxRef != null)
                        {
                                //Get value of ListID
                                if (CustomerRet.ItemSalesTaxRef.ListID != null)
                                {
                                        string ListID7592 = (string)CustomerRet.ItemSalesTaxRef.ListID.GetValue();
                                }
                                //Get value of FullName
                                if (CustomerRet.ItemSalesTaxRef.FullName != null)
                                {
                                        string FullName7593 = (string)CustomerRet.ItemSalesTaxRef.FullName.GetValue();
                                }
                        }
                        //Get value of SalesTaxCountry
                        if (CustomerRet.SalesTaxCountry != null)
                        {
                                ENSalesTaxCountry SalesTaxCountry7594 = (ENSalesTaxCountry)CustomerRet.SalesTaxCountry.GetValue();
                        }
                        //Get value of ResaleNumber
                        if (CustomerRet.ResaleNumber != null)
                        {
                                string ResaleNumber7595 = (string)CustomerRet.ResaleNumber.GetValue();
                        }
                        //Get value of AccountNumber
                        if (CustomerRet.AccountNumber != null)
                        {
                                string AccountNumber7596 = (string)CustomerRet.AccountNumber.GetValue();
                        }
                        //Get value of CreditLimit
                        if (CustomerRet.CreditLimit != null)
                        {
                                double CreditLimit7597 = (double)CustomerRet.CreditLimit.GetValue();
                        }
                        if (CustomerRet.PreferredPaymentMethodRef != null)
                        {
                                //Get value of ListID
                                if (CustomerRet.PreferredPaymentMethodRef.ListID != null)
                                {
                                        string ListID7598 = (string)CustomerRet.PreferredPaymentMethodRef.ListID.GetValue();
                                }
                                //Get value of FullName
                                if (CustomerRet.PreferredPaymentMethodRef.FullName != null)
                                {
                                        string FullName7599 = (string)CustomerRet.PreferredPaymentMethodRef.FullName.GetValue();
                                }
                        }
                        if (CustomerRet.CreditCardInfo != null)
                        {
                                //Get value of CreditCardNumber
                                if (CustomerRet.CreditCardInfo.CreditCardNumber != null)
                                {
                                        string CreditCardNumber7600 = (string)CustomerRet.CreditCardInfo.CreditCardNumber.GetValue();
                                }
                                //Get value of ExpirationMonth
                                if (CustomerRet.CreditCardInfo.ExpirationMonth != null)
                                {
                                        int ExpirationMonth7601 = (int)CustomerRet.CreditCardInfo.ExpirationMonth.GetValue();
                                }
                                //Get value of ExpirationYear
                                if (CustomerRet.CreditCardInfo.ExpirationYear != null)
                                {
                                        int ExpirationYear7602 = (int)CustomerRet.CreditCardInfo.ExpirationYear.GetValue();
                                }
                                //Get value of NameOnCard
                                if (CustomerRet.CreditCardInfo.NameOnCard != null)
                                {
                                        string NameOnCard7603 = (string)CustomerRet.CreditCardInfo.NameOnCard.GetValue();
                                }
                                //Get value of CreditCardAddress
                                if (CustomerRet.CreditCardInfo.CreditCardAddress != null)
                                {
                                        string CreditCardAddress7604 = (string)CustomerRet.CreditCardInfo.CreditCardAddress.GetValue();
                                }
                                //Get value of CreditCardPostalCode
                                if (CustomerRet.CreditCardInfo.CreditCardPostalCode != null)
                                {
                                        string CreditCardPostalCode7605 = (string)CustomerRet.CreditCardInfo.CreditCardPostalCode.GetValue();
                                }
                        }
                        //Get value of JobStatus
                        if (CustomerRet.JobStatus != null)
                        {
                                ENJobStatus JobStatus7606 = (ENJobStatus)CustomerRet.JobStatus.GetValue();
                        }
                        //Get value of JobStartDate
                        if (CustomerRet.JobStartDate != null)
                        {
                                DateTime JobStartDate7607 = (DateTime)CustomerRet.JobStartDate.GetValue();
                        }
                        //Get value of JobProjectedEndDate
                        if (CustomerRet.JobProjectedEndDate != null)
                        {
                                DateTime JobProjectedEndDate7608 = (DateTime)CustomerRet.JobProjectedEndDate.GetValue();
                        }
                        //Get value of JobEndDate
                        if (CustomerRet.JobEndDate != null)
                        {
                                DateTime JobEndDate7609 = (DateTime)CustomerRet.JobEndDate.GetValue();
                        }
                        //Get value of JobDesc
                        if (CustomerRet.JobDesc != null)
                        {
                                string JobDesc7610 = (string)CustomerRet.JobDesc.GetValue();
                        }
                        if (CustomerRet.JobTypeRef != null)
                        {
                                //Get value of ListID
                                if (CustomerRet.JobTypeRef.ListID != null)
                                {
                                        string ListID7611 = (string)CustomerRet.JobTypeRef.ListID.GetValue();
                                }
                                //Get value of FullName
                                if (CustomerRet.JobTypeRef.FullName != null)
                                {
                                        string FullName7612 = (string)CustomerRet.JobTypeRef.FullName.GetValue();
                                }
                        }
                        //Get value of Notes
                        if (CustomerRet.Notes != null)
                        {
                                string Notes7613 = (string)CustomerRet.Notes.GetValue();
                        }
                        if (CustomerRet.AdditionalNotesRetList != null)
                        {
                                for (int i7614 = 0; i7614 < CustomerRet.AdditionalNotesRetList.Count; i7614++)
                                {
                                        IAdditionalNotesRet AdditionalNotesRet = CustomerRet.AdditionalNotesRetList.GetAt(i7614);
                                        //Get value of NoteID
                                        int NoteID7615 = (int)AdditionalNotesRet.NoteID.GetValue();
                                        //Get value of Date
                                        DateTime Date7616 = (DateTime)AdditionalNotesRet.Date.GetValue();
                                        //Get value of Note
                                        string Note7617 = (string)AdditionalNotesRet.Note.GetValue();
                                }
                        }
                        //Get value of PreferredDeliveryMethod
                        if (CustomerRet.PreferredDeliveryMethod != null)
                        {
                                ENPreferredDeliveryMethod PreferredDeliveryMethod7618 = (ENPreferredDeliveryMethod)CustomerRet.PreferredDeliveryMethod.GetValue();
                        }
                        if (CustomerRet.PriceLevelRef != null)
                        {
                                //Get value of ListID
                                if (CustomerRet.PriceLevelRef.ListID != null)
                                {
                                        string ListID7619 = (string)CustomerRet.PriceLevelRef.ListID.GetValue();
                                }
                                //Get value of FullName
                                if (CustomerRet.PriceLevelRef.FullName != null)
                                {
                                        string FullName7620 = (string)CustomerRet.PriceLevelRef.FullName.GetValue();
                                }
                        }
                        //Get value of ExternalGUID
                        if (CustomerRet.ExternalGUID != null)
                        {
                                string ExternalGUID7621 = (string)CustomerRet.ExternalGUID.GetValue();
                        }
                        //Get value of TaxRegistrationNumber
                        if (CustomerRet.TaxRegistrationNumber != null)
                        {
                                string TaxRegistrationNumber7622 = (string)CustomerRet.TaxRegistrationNumber.GetValue();
                        }
                        if (CustomerRet.CurrencyRef != null)
                        {
                                //Get value of ListID
                                if (CustomerRet.CurrencyRef.ListID != null)
                                {
                                        string ListID7623 = (string)CustomerRet.CurrencyRef.ListID.GetValue();
                                }
                                //Get value of FullName
                                if (CustomerRet.CurrencyRef.FullName != null)
                                {
                                        string FullName7624 = (string)CustomerRet.CurrencyRef.FullName.GetValue();
                                }
                        }
                        if (CustomerRet.DataExtRetList != null)
                        {
                                for (int i7625 = 0; i7625 < CustomerRet.DataExtRetList.Count; i7625++)
                                {
                                        IDataExtRet DataExtRet = CustomerRet.DataExtRetList.GetAt(i7625);
                                        //Get value of OwnerID
                                        if (DataExtRet.OwnerID != null)
                                        {
                                                string OwnerID7626 = (string)DataExtRet.OwnerID.GetValue();
                                        }
                                        //Get value of DataExtName
                                        string DataExtName7627 = (string)DataExtRet.DataExtName.GetValue();
                                        //Get value of DataExtType
                                        ENDataExtType DataExtType7628 = (ENDataExtType)DataExtRet.DataExtType.GetValue();
                                        //Get value of DataExtValue
                                        string DataExtValue7629 = (string)DataExtRet.DataExtValue.GetValue();
                                }
                        }
                }




        }
}