LineItemGroups Class
Properties Methods Events Config Settings Errors
Generates a group aggregate for use in another class's Update request.
Class Name
InQB_LineItemGroups
Procedural Interface
inqb_lineitemgroups_open(); inqb_lineitemgroups_close($res); inqb_lineitemgroups_register_callback($res, $id, $function); inqb_lineitemgroups_get_last_error($res); inqb_lineitemgroups_get_last_error_code($res); inqb_lineitemgroups_set($res, $id, $index, $value); inqb_lineitemgroups_get($res, $id, $index); inqb_lineitemgroups_do_config($res, $configurationstring); inqb_lineitemgroups_do_getgroupupdateaggregate($res); inqb_lineitemgroups_do_parseaggregate($res, $aggregate); inqb_lineitemgroups_do_reset($res);
Remarks
There is not exposed a way to directly edit the contents of a line item group when submitting an Update request with a class from this package. You can change the Quantity, but you cannot change the line items contained inside the group line. The LineItemGroups class is used to parse a line item group aggregate. You may then make changes to the individual line items, and then call the GetGroupUpdateAggregate to return an xml aggregate containing your changes. This is then set to the Aggregate property of the line you wish to modify in your Update.
For instance, the following code changes the BillableStatus of all line items and line item groups in the Bill retrieved from QuickBooks.
Bill.Get("123456");
for (int i = 0; i < Bill1.LineItems.Count; i++) {
if (!Bill.LineItems[i].GroupName.Equals("")) { // this is a group line
LineItemGroups.GroupType = gtBill;
LineItemGroups.ParseAggregate(Bill.LineItems[0].Aggregate);
for (int j = 0; j < LineItemGroups.LineItems.Count) {
LineItemGroups.LineItems[j].BillableStatus = bsHasBeenBilled;
}
LineItemGroups.QBXMLVersion = Bill.QBXMLVersion; // so that the proper fields are included in the update aggregate.
Bill1.LineItems[i].Aggregate = LineItemGroups.GetGroupUpdateAggregate();
} else { // regular line item
Bill.LineItems[i].BillableStatus = bsHasBeenBilled;
}
}
Bill.Update();
Property List
The following is the full list of the properties of the class with short descriptions. Click on the links for further details.
Description | A string description of the item group specified by GroupName or GroupId . |
GroupId | Reference to a group of line items. |
GroupName | Reference to a group of line items. |
GroupType | The type of line item group aggregate to create. |
LineId | Identification number of the transaction line group, used for Updates. |
ItemCount | The number of records in the Item arrays. |
ItemAggregate | Contains an XML aggregate of the line item. |
ItemAmount | Line item property: the total amount of this item. |
ItemBillableStatus | Line item property: Billing status of this item. |
ItemClassId | Line item property: Reference to the class of the item. |
ItemClassName | Line item property: Reference to the class of the item. |
ItemCost | Line item property: Unit cost for item. |
ItemCustomerId | Line item property: A reference to customer for whom the item was ordered. |
ItemCustomerName | Line item property: A reference to customer for whom the item was ordered. |
ItemDescription | Line item property: Description of item. |
ItemId | Line item property: Reference to the kind of item. |
ItemName | Line item property: Reference to the kind of item. |
ItemLineId | Identification number of the transaction line, used for Updates. |
ItemManuallyClosed | Indicates if the line item has been manually closed. |
ItemOther1 | Standard QuickBooks Custom Field available for transaction line items. |
ItemOther2 | Standard QuickBooks Custom Field available for transaction line items. |
ItemOverrideAccountId | An account which will override the default account for the line item. |
ItemOverrideAccountName | An account which will override the default account for the line item. |
ItemPriceLevelId | Line Item property: Used to specify custom pricing for specific customers. |
ItemPriceLevelName | Line Item property: Specify custom pricing for specific customers. |
ItemQuantity | Line item property: Quantity of item or item group. |
ItemRate | Unit rate of item. |
ItemRatePercent | Line item property: A markup or discount percentage. |
ItemServiceDate | Line item property: Date of service. |
ItemTaxCodeId | Line item property: Sales tax information for this item. |
ItemTaxCodeName | Line item property: Sales tax information for this item. |
ItemUnitOfMeasure | Unit of measure describing the Quantity . |
PrintItemsInGroup | Indicates whether line items will be shown on printed forms. |
QBXMLVersion | The version of QBXML used to generate the update aggregate. |
Quantity | The quantity of this line item group. |
TotalAmount | The total amount of this group of line items. |
UnitOfMeasure | Unit of measure describing the Quantity . |
Method List
The following is the full list of the methods of the class with short descriptions. Click on the links for further details.
Config | Sets or retrieves a configuration setting. |
GetGroupUpdateAggregate | Generates a group aggregate for use in another class's Update request. |
ParseAggregate | Parses the aggregate returned from another class's ItemAggregate property. |
Reset | Resets this class to its default state. |
Event List
The following is the full list of the events fired by the class with short descriptions. Click on the links for further details.
Error | Information about errors during data delivery. |
Config Settings
The following is a list of config settings for the class with short descriptions. Click on the links for further details.
BuildInfo | Information about the product's build. |
CodePage | The system code page used for Unicode to Multibyte translations. |
LicenseInfo | Information about the current license. |
MaskSensitive | Whether sensitive data is masked in log messages. |
ProcessIdleEvents | Whether the class uses its internal event loop to process events when the main thread is idle. |
SelectWaitMillis | The length of time in milliseconds the class will wait when DoEvents is called if there are no events to process. |
UseInternalSecurityAPI | Tells the class whether or not to use the system security libraries or an internal implementation. |
Description Property (InQB_LineItemGroups Class)
A string description of the item group specified by GroupName or GroupId .
Object Oriented Interface
public function getDescription();
Procedural Interface
inqb_lineitemgroups_get($res, 1 );
Default Value
''
Remarks
This property will contain the description of the group as returned by QuickBooks.
This property is read-only and not available at design time.
Data Type
String
GroupId Property (InQB_LineItemGroups Class)
Reference to a group of line items.
Object Oriented Interface
public function getGroupId(); public function setGroupId($value);
Procedural Interface
inqb_lineitemgroups_get($res, 2 ); inqb_lineitemgroups_set($res, 2, $value );
Default Value
''
Remarks
Line item groups represent sets of items that are grouped together.
A line item group is a predefined shortcut within QuickBooks. For example, a "Cheeseburger Meal" might consist of a cheeseburger, an order of french fries, and a soft drink. To include an item group in a transaction one should simply set the value of ItemGroup, and optionally, of ItemQuantity. QuickBooks will automatically expand the group into its constituent items. This will send an ItemGroup instead of a regular Item on for this index.
When an ItemGroup is returned from QuickBooks it contains xml aggregates of all of the items in the group you specified. You may access the group's regular properties (total Amount, Quantity, and Description), but the line items returned are not normally accessible. However, you may parse the returned line items by passing the contents of the Aggregate property to the LineItemGroups class. You may use the LineItemGroups class to view or change the contents of the line items, and then pass the xml aggregate generated by the class back to the Aggregate field of the original\ object to use in an Update transaction.
Data Type
String
GroupName Property (InQB_LineItemGroups Class)
Reference to a group of line items.
Object Oriented Interface
public function getGroupName(); public function setGroupName($value);
Procedural Interface
inqb_lineitemgroups_get($res, 3 ); inqb_lineitemgroups_set($res, 3, $value );
Default Value
''
Remarks
Line item groups represent sets of items that are grouped together.
A line item group is a predefined shortcut within QuickBooks. For example, a "Cheeseburger Meal" might consist of a cheeseburger, an order of french fries, and a soft drink. To include an item group in a transaction one should simply set the value of ItemGroup, and optionally, of ItemQuantity. QuickBooks will automatically expand the group into its constituent items. This will send an ItemGroup instead of a regular Item on for this index.
When an ItemGroup is returned from QuickBooks it contains xml aggregates of all of the items in the group you specified. You may access the group's regular properties (total Amount, Quantity, and Description), but the line items returned are not normally accessible. However, you may parse the returned line items by passing the contents of the Aggregate property to the LineItemGroups class. You may use the LineItemGroups class to view or change the contents of the line items, and then pass the xml aggregate generated by the class back to the Aggregate field of the original\ object to use in an Update transaction.
Data Type
String
GroupType Property (InQB_LineItemGroups Class)
The type of line item group aggregate to create.
Object Oriented Interface
public function getGroupType(); public function setGroupType($value);
Procedural Interface
inqb_lineitemgroups_get($res, 4 ); inqb_lineitemgroups_set($res, 4, $value );
Default Value
0
Remarks
This property will be automatically filled after a call to ParseAggregate. The following values are permitted:
gtStandardGroup (0) | Used for the Bill, CCCharge, CCCredit, Check, VendorCredit, and ItemReceipt classs. |
gtCreditMemo (1) | Corresponds to the CreditMemo class. |
gtEstimate (2) | Corresponds to the Estimate class. |
gtInvoice (3) | Corresponds to the Invoice class. |
gtPurchaseOrder (4) | Corresponds to the PurchaseOrder class. |
gtSalesOrder (5) | Corresponds to the SalesOrder class. |
gtSalesReceipt (6) | Corresponds to the SalesReceipt class. |
Data Type
Integer
LineId Property (InQB_LineItemGroups Class)
Identification number of the transaction line group, used for Updates.
Object Oriented Interface
public function getLineId(); public function setLineId($value);
Procedural Interface
inqb_lineitemgroups_get($res, 5 ); inqb_lineitemgroups_set($res, 5, $value );
Default Value
''
Remarks
If you need to add a new transaction line group in a transaction Update request, you can do so by setting the LineId to -1.
Data Type
String
ItemCount Property (InQB_LineItemGroups Class)
The number of records in the Item arrays.
Object Oriented Interface
public function getItemCount(); public function setItemCount($value);
Procedural Interface
inqb_lineitemgroups_get($res, 6 ); inqb_lineitemgroups_set($res, 6, $value );
Default Value
0
Remarks
This property controls the size of the following arrays:
- ItemAggregate
- ItemAmount
- ItemBillableStatus
- ItemClassId
- ItemClassName
- ItemCost
- ItemCustomerId
- ItemCustomerName
- ItemDescription
- ItemId
- ItemLineId
- ItemManuallyClosed
- ItemName
- ItemOther1
- ItemOther2
- ItemOverrideAccountId
- ItemOverrideAccountName
- ItemPriceLevelId
- ItemPriceLevelName
- ItemQuantity
- ItemRate
- ItemRatePercent
- ItemServiceDate
- ItemTaxCodeId
- ItemTaxCodeName
- ItemUnitOfMeasure
This property is not available at design time.
Data Type
Integer
ItemAggregate Property (InQB_LineItemGroups Class)
Contains an XML aggregate of the line item.
Object Oriented Interface
public function getItemAggregate($itemindex); public function setItemAggregate($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 7 , $itemindex); inqb_lineitemgroups_set($res, 7, $value , $itemindex);
Default Value
''
Remarks
Contains an XML aggregate of the line item. If the line item has not been modified since receiving a response from QuickBooks, the exact LineRet aggregate that QuickBooks returned will be contained in this XML aggregate. However, if you have made changes to the this line item's properties the ItemAggregate property will re-generate the line item XML with the new data.
If you set the other line item properties and then query the ItemAggregate, a LineRet aggregate will be generated from the currently set properties.
You may set this property with raw xml. So long as you do not modify any other properties (forcing the line item to regenerate based on new changes), the xml will be sent as-is to the QuickBooks request processor. It is essential that you properly format the XML that you place in this property. When setting this property manually, the class will send exactly what you have set. You must ensure your xml is appropriate for the action you are attempting. For instance, if you are Adding an Invoice, you must ensure the outer tags are "InvoiceLineAdd". If Modifying an Invoice, the outer tags must be "InvoiceLineMod".
If you do not expressly set the ItemAggregate field with your own custom XML, all of this will be taken care of you automatically by the class.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemAmount Property (InQB_LineItemGroups Class)
Line item property: the total amount of this item.
Object Oriented Interface
public function getItemAmount($itemindex); public function setItemAmount($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 8 , $itemindex); inqb_lineitemgroups_set($res, 8, $value , $itemindex);
Default Value
''
Remarks
Line item property: the total amount of this item.
This property represents the total amount of a transaction line. If ItemRate, ItemCost and/or ItemQuantity are specified the ItemAmount will be automatically computed by QuickBooks.
Whether ItemRate or ItemCost is used will depend on the transaction type. ItemRate is available for CreditMemo, Estimate, Invoice, PurchaseOrder, SalesOrder, and SalesReceipt transactions while ItemCost is available for Bill, CCCharge, CCCredit, Check, ItemReceipt, and VendorCredit transactions.
The amount should be formatted as a string in dollars.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemBillableStatus Property (InQB_LineItemGroups Class)
Line item property: Billing status of this item.
Object Oriented Interface
public function getItemBillableStatus($itemindex); public function setItemBillableStatus($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 9 , $itemindex); inqb_lineitemgroups_set($res, 9, $value , $itemindex);
Default Value
0
Remarks
Line item property: Billing status of this item.
The billing status of this line item. If the billing status is empty (that is, if no billing status appears in QuickBooks), then no ItemBillableStatus value will be returned.
Values:
- bsEmpty (0)
- bsBillable (1)
- bsNotBillable (2)
- bsHasBeenBilled (3)
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
Integer
ItemClassId Property (InQB_LineItemGroups Class)
Line item property: Reference to the class of the item.
Object Oriented Interface
public function getItemClassId($itemindex); public function setItemClassId($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 10 , $itemindex); inqb_lineitemgroups_set($res, 10, $value , $itemindex);
Default Value
''
Remarks
Line item property: Reference to the class of the item.
A reference to the class of this item.
Id/Name Reference Properties
This property is used to reference an object that is already done within QuickBooks. This may be done with its Id (this property) or its full Name, for which a corresponding property is defined.
Using the Id is recommended when feasible, as the Id is guaranteed to never change once defined.
Setting the value of this property will set the corresponding Name property to an empty string.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemClassName Property (InQB_LineItemGroups Class)
Line item property: Reference to the class of the item.
Object Oriented Interface
public function getItemClassName($itemindex); public function setItemClassName($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 11 , $itemindex); inqb_lineitemgroups_set($res, 11, $value , $itemindex);
Default Value
''
Remarks
Line item property: Reference to the class of the item.
Name/Id Reference Properties
This property is used to reference an object that is already done within QuickBooks. This may be done with its full Name (this property) or its Id, for which a corresponding property is defined. If Name is used, it must contain the full name of the object referred to, as generated by QuickBooks. For hierarchically defined objects, such as Customers, this includes the names of parent objects, and the full name can be determined by reading the FullName special field.
Setting the value of this property will set the corresponding Id property to an empty string.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemCost Property (InQB_LineItemGroups Class)
Line item property: Unit cost for item.
Object Oriented Interface
public function getItemCost($itemindex); public function setItemCost($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 12 , $itemindex); inqb_lineitemgroups_set($res, 12, $value , $itemindex);
Default Value
''
Remarks
Line item property: Unit cost for item.
The unit cost for this item.
If ItemAmount is specified, then ItemCost will be calculated automatically and should not be specified.
The amount should be formatted as a string in dollars.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemCustomerId Property (InQB_LineItemGroups Class)
Line item property: A reference to customer for whom the item was ordered.
Object Oriented Interface
public function getItemCustomerId($itemindex); public function setItemCustomerId($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 13 , $itemindex); inqb_lineitemgroups_set($res, 13, $value , $itemindex);
Default Value
''
Remarks
Line item property: A reference to customer for whom the item was ordered.
A reference to a Customer for whom this item was ordered.
If this property is set, the expense will be set as billable to the Customer referenced.
Id/Name Reference Properties
This property is used to reference an object that is already done within QuickBooks. This may be done with its Id (this property) or its full Name, for which a corresponding property is defined.
Using the Id is recommended when feasible, as the Id is guaranteed to never change once defined.
Setting the value of this property will set the corresponding Name property to an empty string.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemCustomerName Property (InQB_LineItemGroups Class)
Line item property: A reference to customer for whom the item was ordered.
Object Oriented Interface
public function getItemCustomerName($itemindex); public function setItemCustomerName($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 14 , $itemindex); inqb_lineitemgroups_set($res, 14, $value , $itemindex);
Default Value
''
Remarks
Line item property: A reference to customer for whom the item was ordered.
A reference to a Customer for whom this item was ordered.
If this property is set, the expense will be set as billable to the Customer referenced.
Name/Id Reference Properties
This property is used to reference an object that is already done within QuickBooks. This may be done with its full Name (this property) or its Id, for which a corresponding property is defined. If Name is used, it must contain the full name of the object referred to, as generated by QuickBooks. For hierarchically defined objects, such as Customers, this includes the names of parent objects, and the full name can be determined by reading the FullName special field.
Setting the value of this property will set the corresponding Id property to an empty string.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemDescription Property (InQB_LineItemGroups Class)
Line item property: Description of item.
Object Oriented Interface
public function getItemDescription($itemindex); public function setItemDescription($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 15 , $itemindex); inqb_lineitemgroups_set($res, 15, $value , $itemindex);
Default Value
''
Remarks
Line item property: Description of item.
A string description of the Item specified by ItemName or ItemId.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemId Property (InQB_LineItemGroups Class)
Line item property: Reference to the kind of item.
Object Oriented Interface
public function getItemId($itemindex); public function setItemId($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 16 , $itemindex); inqb_lineitemgroups_set($res, 16, $value , $itemindex);
Default Value
''
Remarks
Line item property: Reference to the kind of item.
Line items represent goods or services bought in a QuickBooks transaction.
Each line item is represented by a number of properties, each prefixed by Item (see the list of properties for individual classs for details). Properties such as ItemQuantity and ItemDescription are always present; some properties are found in only certain types of transactions.
Item is a reference to a kind of item, predefined within QuickBooks. Generally items defined within QuickBooks have default values for ItemDescription, etc., and if only Item is set when adding a record to QuickBooks, the other properties will be set automatically.
This class is used to create a single item. However, any InQB class may be set with an unlimited number of these items. For example:
Invoice.ItemCount = 3
LineItems.ItemName = "Wingnut"
LineItems.Quantity = 8
Invoice.ItemAggregate[0] = LineItems.GetAggregate()
LineItems.ItemName = "Shovel"
LineItems.Quantity = 1
Invoice.ItemAggregate[1] = LineItems.GetAggregate()
LineItems.ItemName = "Mower blade"
LineItems.Quantity = 1
Invoice.ItemAggregate[2] = LineItems.GetAggregate()
Items may also be grouped into ItemGroups, using the LineItemGroups class.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemName Property (InQB_LineItemGroups Class)
Line item property: Reference to the kind of item.
Object Oriented Interface
public function getItemName($itemindex); public function setItemName($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 17 , $itemindex); inqb_lineitemgroups_set($res, 17, $value , $itemindex);
Default Value
''
Remarks
Line item property: Reference to the kind of item.
Line items represent goods or services bought in a QuickBooks transaction.
Each line item is represented by a number of properties, each prefixed by Item (see the list of properties for individual classs for details). Properties such as ItemQuantity and ItemDescription are always present; some properties are found in only certain types of transactions.
Item is a reference to a kind of item, predefined within QuickBooks. Generally items defined within QuickBooks have default values for ItemDescription, etc., and if only Item is set when adding a record to QuickBooks, the other properties will be set automatically.
This class is used to create a single item. However, any InQB class may be set with an unlimited number of these items. For example:
Invoice.ItemCount = 3
LineItems.ItemName = "Wingnut"
LineItems.Quantity = 8
Invoice.ItemAggregate[0] = LineItems.GetAggregate()
LineItems.ItemName = "Shovel"
LineItems.Quantity = 1
Invoice.ItemAggregate[1] = LineItems.GetAggregate()
LineItems.ItemName = "Mower blade"
LineItems.Quantity = 1
Invoice.ItemAggregate[2] = LineItems.GetAggregate()
Items may also be grouped into ItemGroups, using the LineItemGroups class.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemLineId Property (InQB_LineItemGroups Class)
Identification number of the transaction line, used for Updates.
Object Oriented Interface
public function getItemLineId($itemindex); public function setItemLineId($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 18 , $itemindex); inqb_lineitemgroups_set($res, 18, $value , $itemindex);
Default Value
''
Remarks
Identification number of the transaction line, used for Updates.
If you need to add a new transaction line in a transaction Update request, you can do so by setting the ItemLineId to -1.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemManuallyClosed Property (InQB_LineItemGroups Class)
Indicates if the line item has been manually closed.
Object Oriented Interface
public function getItemManuallyClosed($itemindex); public function setItemManuallyClosed($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 19 , $itemindex); inqb_lineitemgroups_set($res, 19, $value , $itemindex);
Default Value
0
Remarks
Indicates if the line item has been manually closed.
If ItemManuallyClosed is mcManuallyClosed, the purchase order line has been closed, even if this item has not been received or its sale canceled. If all the purchase order lines are marked as closed, the purchase order itself is marked as closed as well. You cannot change ItemManuallyClosed to mcNotManuallyClosed after the purchase order line has been fully received. If set to mcNotSet the field is not sent in the request.
Only applicable to Update transactions.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
Integer
ItemOther1 Property (InQB_LineItemGroups Class)
Standard QuickBooks Custom Field available for transaction line items.
Object Oriented Interface
public function getItemOther1($itemindex); public function setItemOther1($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 20 , $itemindex); inqb_lineitemgroups_set($res, 20, $value , $itemindex);
Default Value
''
Remarks
Standard QuickBooks Custom Field available for transaction line items.
The ItemOther1 and ItemOther2 custom fields are available for immediate use: you don't need to enable these in the transaction template to be able to access them via SDK. (However, those ItemOther1 and ItemOther2 fields and their values are viewable and printable in QuickBooks only if the transaction template has these enabled!). QBXMLVersion 6.0 or higher is required to use this property.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemOther2 Property (InQB_LineItemGroups Class)
Standard QuickBooks Custom Field available for transaction line items.
Object Oriented Interface
public function getItemOther2($itemindex); public function setItemOther2($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 21 , $itemindex); inqb_lineitemgroups_set($res, 21, $value , $itemindex);
Default Value
''
Remarks
Standard QuickBooks Custom Field available for transaction line items.
The ItemOther1 and ItemOther2 custom fields are available for immediate use: you don't need to enable these in the transaction template to be able to access them via SDK. (However, those ItemOther1 and ItemOther2 fields and their values are viewable and printable in QuickBooks only if the transaction template has these enabled!). QBXMLVersion 6.0 or higher is required to use this property.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemOverrideAccountId Property (InQB_LineItemGroups Class)
An account which will override the default account for the line item.
Object Oriented Interface
public function getItemOverrideAccountId($itemindex); public function setItemOverrideAccountId($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 22 , $itemindex); inqb_lineitemgroups_set($res, 22, $value , $itemindex);
Default Value
''
Remarks
An account which will override the default account for the line item. QBXMLVersion must be 2.0 or higher to use this configuration setting.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemOverrideAccountName Property (InQB_LineItemGroups Class)
An account which will override the default account for the line item.
Object Oriented Interface
public function getItemOverrideAccountName($itemindex); public function setItemOverrideAccountName($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 23 , $itemindex); inqb_lineitemgroups_set($res, 23, $value , $itemindex);
Default Value
''
Remarks
An account which will override the default account for the line item. QBXMLVersion must be 2.0 or higher to use this configuration setting.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemPriceLevelId Property (InQB_LineItemGroups Class)
Line Item property: Used to specify custom pricing for specific customers.
Object Oriented Interface
public function getItemPriceLevelId($itemindex); public function setItemPriceLevelId($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 24 , $itemindex); inqb_lineitemgroups_set($res, 24, $value , $itemindex);
Default Value
''
Remarks
Line Item property: Used to specify custom pricing for specific customers.
Id for the PriceLevel selected for this transaction.
If ItemPriceLevelId and/or ItemPriceLevelName are specified, then ItemAmount will be calculated automatically and should not be specified.
Note that ItemPriceLevelId and ItemPriceLevelName, OR ItemRate OR ItemRatePercent may be specified. ItemPriceLevelId and ItemPriceLevelName are ONLY available for QBXMLVersions 4.0 and above.
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 ItemRate, which was set using the price level.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemPriceLevelName Property (InQB_LineItemGroups Class)
Line Item property: Specify custom pricing for specific customers.
Object Oriented Interface
public function getItemPriceLevelName($itemindex); public function setItemPriceLevelName($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 25 , $itemindex); inqb_lineitemgroups_set($res, 25, $value , $itemindex);
Default Value
''
Remarks
Line Item property: Specify custom pricing for specific customers.
Id for the PriceLevel selected for this transaction.
If ItemPriceLevelId and/or ItemPriceLevelName are specified, then ItemAmount will be calculated automatically and should not be specified.
Note that ItemPriceLevelId and ItemPriceLevelName, OR ItemRate OR ItemRatePercent may be specified. ItemPriceLevelId and ItemPriceLevelName are ONLY available for QBXMLVersions 4.0 and above.
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 ItemRate, which was set using the price level.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemQuantity Property (InQB_LineItemGroups Class)
Line item property: Quantity of item or item group.
Object Oriented Interface
public function getItemQuantity($itemindex); public function setItemQuantity($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 26 , $itemindex); inqb_lineitemgroups_set($res, 26, $value , $itemindex);
Default Value
''
Remarks
Line item property: Quantity of item or item group.
The quantity of the Item specified in this line.
If ItemQuantity and only one of ItemCost, ItemRate, or ItemAmount are specified, QuickBooks will automatically calculate the other.
This property is a String type in order to allow setting fractional quantities. Setting this property with non-numeric data will cause an error. Correct usage of this property is shown below:
class.Quantity = "3.5"
Leave this property blank and no quantity will be sent to QuickBooks.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemRate Property (InQB_LineItemGroups Class)
Unit rate of item.
Object Oriented Interface
public function getItemRate($itemindex); public function setItemRate($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 27 , $itemindex); inqb_lineitemgroups_set($res, 27, $value , $itemindex);
Default Value
''
Remarks
Unit rate of item.
The unit rate charged for this item.
If ItemAmount is specified, then ItemRate will be calculated automatically and should not be specified.
The amount should be formatted as a string in dollars.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemRatePercent Property (InQB_LineItemGroups Class)
Line item property: A markup or discount percentage.
Object Oriented Interface
public function getItemRatePercent($itemindex); public function setItemRatePercent($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 28 , $itemindex); inqb_lineitemgroups_set($res, 28, $value , $itemindex);
Default Value
''
Remarks
Line item property: A markup or discount percentage.
If ItemRatePercent is specified instead of ItemRate, then this line item represents a percentage markup or discount, to be applied to the previous Item or Item group.
ItemRatePercent should be formatted as a positive or negative integer; a positive value indicates a markup.
Only one of ItemRatePercent and ItemRate may be specified. If ItemRatePercent is set, then ItemRate will be set to its default.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemServiceDate Property (InQB_LineItemGroups Class)
Line item property: Date of service.
Object Oriented Interface
public function getItemServiceDate($itemindex); public function setItemServiceDate($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 29 , $itemindex); inqb_lineitemgroups_set($res, 29, $value , $itemindex);
Default Value
''
Remarks
Line item property: Date of service.
For Items that represent a service, ItemServiceDate refers to the date of service. ItemServiceDate is only applicable for the CreditMemo, Invoice, PurchaseOrder, and SalesReceipt classs.
The standard formatting for dates is YYYY-MM-DD; i.e., September 2, 2002 is formatted as 2002-09-02. When getting the value of a date property, the date will always be in this format.
When setting the value of a date property, the formats MM-DD-YY, MM-DD-YYYY, MM/DD/YY, and MM/DD/YYYY are also acceptable. Dates in these formats will be automatically parsed and stored in YYYY-MM-DD format.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemTaxCodeId Property (InQB_LineItemGroups Class)
Line item property: Sales tax information for this item.
Object Oriented Interface
public function getItemTaxCodeId($itemindex); public function setItemTaxCodeId($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 30 , $itemindex); inqb_lineitemgroups_set($res, 30, $value , $itemindex);
Default Value
''
Remarks
Line item property: Sales tax information for this item.
This is a reference to a sales tax code predefined within QuickBooks.
By default, two standard TaxCodes exist: "TAX", or Taxable Sales, and "NON", or Non-Taxable Sales. The QuickBooks user may also define custom tax codes.
Id/Name Reference Properties
This property is used to reference an object that is already done within QuickBooks. This may be done with its Id (this property) or its full Name, for which a corresponding property is defined.
Using the Id is recommended when feasible, as the Id is guaranteed to never change once defined.
Setting the value of this property will set the corresponding Name property to an empty string.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemTaxCodeName Property (InQB_LineItemGroups Class)
Line item property: Sales tax information for this item.
Object Oriented Interface
public function getItemTaxCodeName($itemindex); public function setItemTaxCodeName($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 31 , $itemindex); inqb_lineitemgroups_set($res, 31, $value , $itemindex);
Default Value
''
Remarks
Line item property: Sales tax information for this item.
This is a reference to a sales tax code predefined within QuickBooks.
By default, two standard TaxCodes exist: "TAX", or Taxable Sales, and "NON", or Non-Taxable Sales. The QuickBooks user may also define custom tax codes.
Name/Id Reference Properties
This property is used to reference an object that is already done within QuickBooks. This may be done with its full Name (this property) or its Id, for which a corresponding property is defined. If Name is used, it must contain the full name of the object referred to, as generated by QuickBooks. For hierarchically defined objects, such as Customers, this includes the names of parent objects, and the full name can be determined by reading the FullName special field.
Setting the value of this property will set the corresponding Id property to an empty string.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
ItemUnitOfMeasure Property (InQB_LineItemGroups Class)
Unit of measure describing the Quantity .
Object Oriented Interface
public function getItemUnitOfMeasure($itemindex); public function setItemUnitOfMeasure($itemindex, $value);
Procedural Interface
inqb_lineitemgroups_get($res, 32 , $itemindex); inqb_lineitemgroups_set($res, 32, $value , $itemindex);
Default Value
''
Remarks
Unit of measure describing the ItemQuantity.
In a transaction line item, the name of the unit of measure selected from within the item's available units. If the company file is enabled only for single unit of measure per item, this must be the base unit!
This property is only available for QBXMLVersion 7.0 and higher.
The $itemindex parameter specifies the index of the item in the array. The size of the array is controlled by the ItemCount property.
This property is not available at design time.
Data Type
String
PrintItemsInGroup Property (InQB_LineItemGroups Class)
Indicates whether line items will be shown on printed forms.
Object Oriented Interface
public function getPrintItemsInGroup();
Procedural Interface
inqb_lineitemgroups_get($res, 33 );
Default Value
false
Remarks
If true, a list of this group's individual items their amounts will appear on printed forms.
This property is read-only and not available at design time.
Data Type
Boolean
QBXMLVersion Property (InQB_LineItemGroups Class)
The version of QBXML used to generate the update aggregate.
Object Oriented Interface
public function getQBXMLVersion(); public function setQBXMLVersion($value);
Procedural Interface
inqb_lineitemgroups_get($res, 34 ); inqb_lineitemgroups_set($res, 34, $value );
Default Value
'3.0'
Remarks
This should match the QBXMLVersion of the class you're generating a group line update aggregate for.
This property is not available at design time.
Data Type
String
Quantity Property (InQB_LineItemGroups Class)
The quantity of this line item group.
Object Oriented Interface
public function getQuantity(); public function setQuantity($value);
Procedural Interface
inqb_lineitemgroups_get($res, 35 ); inqb_lineitemgroups_set($res, 35, $value );
Default Value
''
Remarks
This property is a String type in order to allow setting fractional quantities. Setting this property with non-numeric data will cause an error. Correct usage of this property is shown below:
class.Quantity = "3"
Leave this property blank and no quantity will be sent to QuickBooks.
Data Type
String
TotalAmount Property (InQB_LineItemGroups Class)
The total amount of this group of line items.
Object Oriented Interface
public function getTotalAmount();
Procedural Interface
inqb_lineitemgroups_get($res, 36 );
Default Value
''
Remarks
This property represents the total amount of all transaction lines in the group. This amount will be automatically computed by QuickBooks.
The amount should be formatted as a string in dollars.
This property is read-only and not available at design time.
Data Type
String
UnitOfMeasure Property (InQB_LineItemGroups Class)
Unit of measure describing the Quantity .
Object Oriented Interface
public function getUnitOfMeasure(); public function setUnitOfMeasure($value);
Procedural Interface
inqb_lineitemgroups_get($res, 37 ); inqb_lineitemgroups_set($res, 37, $value );
Default Value
''
Remarks
In a transaction line item, the name of the unit of measure selected from within the item's available units. If the company file is enabled only for single unit of measure per item, this must be the base unit!
This property is only available for QBXMLVersion 7.0 and higher.
Data Type
String
Config Method (InQB_LineItemGroups Class)
Sets or retrieves a configuration setting.
Object Oriented Interface
public function doConfig($configurationstring);
Procedural Interface
inqb_lineitemgroups_do_config($res, $configurationstring);
Remarks
Config is a generic method available in every class. It is used to set and retrieve configuration settings for the class.
These settings are similar in functionality to properties, but they are rarely used. In order to avoid "polluting" the property namespace of the class, access to these internal properties is provided through the Config method.
To set a configuration setting named PROPERTY, you must call Config("PROPERTY=VALUE"), where VALUE is the value of the setting expressed as a string. For boolean values, use the strings "True", "False", "0", "1", "Yes", or "No" (case does not matter).
To read (query) the value of a configuration setting, you must call Config("PROPERTY"). The value will be returned as a string.
GetGroupUpdateAggregate Method (InQB_LineItemGroups Class)
Generates a group aggregate for use in another class's Update request.
Object Oriented Interface
public function doGetGroupUpdateAggregate();
Procedural Interface
inqb_lineitemgroups_do_getgroupupdateaggregate($res);
Remarks
There is not exposed a way to directly edit the contents of a line item group when submitting an Update request with a class from this package. You can change the Quantity, but you cannot change the line items contained inside the group line. The LineItemGroups class is used to parse a line item group aggregate. You may then make changes to the individual line items, and then call the GetGroupUpdateAggregate to return an xml aggregate containing your changes. This is then set to the Aggregate property of the line you wish to modify in your Update.
For instance, the following code changes the BillableStatus of all line items and line item groups in the Bill retrieved from QuickBooks.
Bill.Get("123456");
for (int i = 0; i < Bill1.LineItems.Count; i++) {
if (!Bill.LineItems[i].GroupName.Equals("")) { // this is a group line
LineItemGroups.GroupType = gtBill;
LineItemGroups.ParseAggregate(Bill.LineItems[0].Aggregate);
for (int j = 0; j < LineItemGroups.LineItems.Count) {
LineItemGroups.LineItems[j].BillableStatus = bsHasBeenBilled;
}
LineItemGroups.QBXMLVersion = Bill.QBXMLVersion; // so that the proper fields are included in the update aggregate.
Bill1.LineItems[i].Aggregate = LineItemGroups.GetGroupUpdateAggregate();
} else { // regular line item
Bill.LineItems[i].BillableStatus = bsHasBeenBilled;
}
}
Bill.Update();
ParseAggregate Method (InQB_LineItemGroups Class)
Parses the aggregate returned from another class's ItemAggregate property.
Object Oriented Interface
public function doParseAggregate($aggregate);
Procedural Interface
inqb_lineitemgroups_do_parseaggregate($res, $aggregate);
Remarks
This method takes the XML aggregate returned from any class's ItemAggregate property, and then fills all the properties of this class. For example:
Invoice.Add()
For (i = 0 to Invoice.ItemCount - 1)
LineItems.ParseAggregate(Invoice.ItemAggregate[0])
Debug.Print(LineItems.ItemName & VbTab & LineItems.Quantity & VbTab & LineItems.Amount)
Next
Reset Method (InQB_LineItemGroups Class)
Resets this class to its default state.
Object Oriented Interface
public function doReset();
Procedural Interface
inqb_lineitemgroups_do_reset($res);
Remarks
This method clears all properties and returns the class to its default state.
Error Event (InQB_LineItemGroups Class)
Information about errors during data delivery.
Object Oriented Interface
public function fireError($param);
Procedural Interface
inqb_lineitemgroups_register_callback($res, 1, array($this, 'fireError'));
Parameter List
'errorcode'
'description'
Remarks
The Error event is fired in case of exceptional conditions during message processing.
ErrorCode contains an error code and Description contains a textual description of the error. For a list of valid error codes and their descriptions, please refer to the Error Codes section.
Config Settings (LineItemGroups Class)
The class accepts one or more of the following configuration settings. Configuration settings are similar in functionality to properties, but they are rarely used. In order to avoid "polluting" the property namespace of the class, access to these internal properties is provided through the Config method.Base Config Settings | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
BuildInfo: Information about the product's build.When queried, this setting will return a string containing information about the product's build. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
CodePage:
The system code page used for Unicode to Multibyte translations.The default code page is Unicode UTF-8 (65001).
The following is a list of valid code page identifiers:
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
LicenseInfo:
Information about the current license.When queried, this setting will return a string containing information about the license this instance of a class is using. It will return the following information:
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
MaskSensitive:
Whether sensitive data is masked in log messages.In certain circumstances it may be beneficial to mask sensitive data, like passwords, in log messages. Set this to true to mask sensitive data. The default is true.
This setting only works on these classes: AS3Receiver, AS3Sender, Atom, Client(3DS), FTP, FTPServer, IMAP, OFTPClient, SSHClient, SCP, Server(3DS), Sexec, SFTP, SFTPServer, SSHServer, TCPClient, TCPServer. |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
ProcessIdleEvents: Whether the class uses its internal event loop to process events when the main thread is idle.If set to False, the class will not fire internal idle events. Set this to False to use the class in a background thread on Mac OS. By default, this setting is True. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
SelectWaitMillis: The length of time in milliseconds the class will wait when DoEvents is called if there are no events to process.If there are no events to process when DoEvents is called, the class will wait for the amount of time specified here before returning. The default value is 20. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
UseInternalSecurityAPI:
Tells the class whether or not to use the system security libraries or an internal implementation.
When set to false, the class will use the system security libraries by default to perform cryptographic functions where applicable.
Setting this setting to true tells the class to use the internal implementation instead of using the system security libraries. On Windows, this setting is set to false by default. On Linux/macOS, this setting is set to true by default. To use the system security libraries for Linux, OpenSSL support must be enabled. For more information on how to enable OpenSSL, please refer to the OpenSSL Notes section. |
Trappable Errors (LineItemGroups Class)
LineItemGroups Errors
201 A required field was not specified. | |
421 Update is not supported for this GroupType. | |
901 Unable to parse aggregate. | |
902 Invalid GroupType. |