public bool ImportSerializedAssemblyAccountsType()
 {
     try
     {
         this.peachtreeObj = new PeachtreeSingleTon();
         Import import = (Import)this.peachtreeObj.AppObj.CreateImporter(PeachwIEObj.peachwIEObjInventoryItemsList);
         import.ClearImportFieldList();
         import.AddToImportFieldList((short)PeachwIEObjInventoryItemsListField.peachwIEObjInventoryItemsListField_ItemId);
         import.AddToImportFieldList((short)PeachwIEObjInventoryItemsListField.peachwIEObjInventoryItemsListField_SalesAccountId);
         import.AddToImportFieldList((short)PeachwIEObjInventoryItemsListField.peachwIEObjInventoryItemsListField_InventoryAccountId);
         import.AddToImportFieldList((short)PeachwIEObjInventoryItemsListField.peachwIEObjInventoryItemsListField_InvChgAccountId);
         import.AddToImportFieldList((short)PeachwIEObjInventoryItemsListField.peachwIEObjInventoryItemsListField_NumComp);
         import.AddToImportFieldList((short)PeachwIEObjInventoryItemsListField.peachwIEObjInventoryItemsListField_RevisionNumber);
         import.AddToImportFieldList((short)PeachwIEObjInventoryItemsListField.peachwIEObjInventoryItemsListField_EffectiveDate);
         import.AddToImportFieldList((short)PeachwIEObjInventoryItemsListField.peachwIEObjInventoryItemsListField_ComponentNumber);
         import.AddToImportFieldList((short)PeachwIEObjInventoryItemsListField.peachwIEObjInventoryItemsListField_ComponentID);
         import.AddToImportFieldList((short)PeachwIEObjInventoryItemsListField.peachwIEObjInventoryItemsListField_QuantityNeeded);
         import.SetFileType(PeachwIEFileType.peachwIEFileTypeCSV);
         import.SetFilename(this.FileNameCSV3);
         import.Import();
         return(true);
     }
     catch (Exception exception)
     {
         // MessageBox.Show(exception.Message);
         return(false);
     }
 }
 public bool ImportHideItem()
 {
     try
     {
         this.peachtreeObj = new PeachtreeSingleTon();
         Import import = (Import)this.peachtreeObj.AppObj.CreateImporter(PeachwIEObj.peachwIEObjInventoryItemsList);
         import.ClearImportFieldList();
         import.AddToImportFieldList((short)PeachwIEObjInventoryItemsListField.peachwIEObjInventoryItemsListField_ItemId);
         import.AddToImportFieldList((short)PeachwIEObjInventoryItemsListField.peachwIEObjInventoryItemsListField_Inactive);
         import.SetFileType(PeachwIEFileType.peachwIEFileTypeCSV);
         import.SetFilename(this.FileNameCSV);
         import.Import();
         return(true);
     }
     catch (Exception exception)
     {
         MessageBox.Show(exception.Message);
         return(false);
     }
 }
Exemple #3
0
 public string[] ImportSaleOrder()
 {
     string[] gUIDs = new string[1];
     try
     {
         this.peachtreeObj = new PeachtreeSingleTon();
         Import import = (Import)this.peachtreeObj.AppObj.CreateImporter(PeachwIEObj.peachwIEObjSalesOrders);
         import.ClearImportFieldList();
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_CustomerId);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_CustomerName);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_SalesOrderNumber);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_Date);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_SalesOrderClosed);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_QuoteNumber);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_DropShip);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_ShipToName);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_ShipToAddressLine1);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_ShipToAddressLine2);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_ShipToCity);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_ShipToState);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_ShipToZip);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_ShipToCountry);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_CustomerPurchaseOrder);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_ShipVia);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_DiscountAmount);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_DisplayedTerms);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_SalesRepId);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_ARAccountId);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_ARAmount);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_SalesTaxCode);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_InvoiceNote);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_NotePrintsAfterLineItems);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_StatementNote);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_StatementPrintsBeforeInvoiceRef);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_NumberOfDistributions);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_SalesOrderDistNum);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_Quantity);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_ItemId);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_Description);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_GLAccountId);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_UnitPrice);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_TaxType);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_Amount);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_JobId);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_SalesTaxAuthority);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_TransactionPeriod);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_TransactioNumber);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_InvoiceNote2);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_ShipByDate);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_TransactionGUID);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_UPCSKU);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_Weight);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_CustomerGUID);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_SalesRepresentativeGUID);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_ARAccountGUID);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_GLAccountGUID);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_ItemGUID);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_JobGUID);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_enUMID);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_enUMStockingUnits);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_enStockingQuantity);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_enUMStockingUnitPrice);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_enProposal);
         import.AddToImportFieldList((short)PeachwIEObjSalesOrdersField.peachwIEObjSalesOrdersField_enProposalAccepted);
         import.SetFileType(PeachwIEFileType.peachwIEFileTypeCSV);
         import.SetFilename(this.FileNameCSV);
         import.ImportAndReturnGUIDs(out gUIDs);
         return(gUIDs);
     }
     catch (Exception exception)
     {
         MessageBox.Show(exception.Message);
         return(gUIDs);
     }
 }
Exemple #4
0
 public string[] ImportQuote()
 {
     string[] gUIDs = new string[1];
     try
     {
         this.peachtreeObj = new PeachtreeSingleTon();
         Import import = (Import)this.peachtreeObj.AppObj.CreateImporter(PeachwIEObj.peachwIEObjSalesJournal);
         import.ClearImportFieldList();
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_CustomerId);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_CustomerName);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_InvoiceNumber);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_Date);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_Quote);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_QuoteNumber);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_QuoteGoodThruDate);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_DropShip);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_ShipToName);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_ShipToAddressLine1);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_ShipToAddressLine2);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_ShipToCity);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_ShipToState);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_ShipToZip);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_ShipToCountry);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_CustomerPurchaseOrder);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_ShipVia);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_ShipDate);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_DateDue);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_DiscountAmount);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_DiscountDate);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_DisplayedTerms);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_SalesRepId);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_ARAccountId);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_ARAmount);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_SalesTaxCode);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_InvoiceNote);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_NotePrintsAfterLineItems);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_StatementNote);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_StatementNotePrintsBeforeInvoiceRef);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_BeginningBalanceTransaction);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_DateClearedInAccountRec);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_NumberOfDistributions);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_ApplyToSalesOrder);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_SalesOrderNumber);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_SalesOrderDistNum);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_Quantity);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_ItemId);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_enSerialNumber);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_Description);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_GLAccountId);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_UnitPrice);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_TaxType);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_Amount);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_InventoryAccountId);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_CostOfSalesAccountId);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_CostOfSalesAmount);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_JobId);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_SalesTaxAuthority);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_TransactionPeriod);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_TransactionNumber);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_ReceiptNum);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_InvoiceNote2);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_ShipByDate);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_TransactionGUID);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_UPCSKU);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_Weight);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_ApplyToInvoiceNumber);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_ReturnAuthorization);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_InvoiceDistNum);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_ApplyToInvoiceDistNum);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_IsCreditMemo);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_CustomerGUID);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_SalesRepresentativeGUID);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_ARAccountGUID);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_ItemGUID);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_GLAccountGUID);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_INVAccountGUID);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_COSTAccountGUID);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_JobGUID);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_enGL_DateClearedInBankRec);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_enInvAcntDateClearedInBankRec);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_enCOSAcntDateClearedInBankRec);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_enUMID);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_enUMStockingUnits);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_enStockingQuantity);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_enUMStockingUnitPrice);
         //imp.AddToImportFieldList((short)PeachwIEObjSalesJournalField .peachwIEObjSalesJournalField_enVoidedBy);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_enRetainagePercent);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_enProgressBillingInvoice);
         import.AddToImportFieldList((short)PeachwIEObjSalesJournalField.peachwIEObjSalesJournalField_enApplyToProposal);
         import.SetFileType(PeachwIEFileType.peachwIEFileTypeCSV);
         import.SetFilename(this.FileNameCSV);
         import.ImportAndReturnGUIDs(out gUIDs);
         return(gUIDs);
     }
     catch (Exception exception)
     {
         MessageBox.Show(exception.Message);
         return(gUIDs);
     }
 }