Source code of file oscpmwin/oscpmdata.pas from the
osCommerce Product Manager for Windows.


0000:   {%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
0001:   osCommerce Product Manager for Windows (oscpmwin).
0002:   0003:   
0004:   You can contact Mario A. Valdez-Ramirez
0005:   by email at mario@mariovaldez.org or paper mail at
0006:   Olmos 809, San Nicolas, NL. 66495, Mexico.
0007:   
0008:   This program is free software; you can redistribute it and/or modify
0009:   it under the terms of the GNU General Public License as published by
0010:   the Free Software Foundation; either version 2 of the License, or (at
0011:   your option) any later version.
0012:   
0013:   This program is distributed in the hope that it will be useful, but
0014:   WITHOUT ANY WARRANTY; without even the implied warranty of
0015:   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
0016:   General Public License for more details.
0017:   
0018:   You should have received a copy of the GNU General Public License
0019:   along with this program; if not, write to the Free Software
0020:   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
0021:   %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%}
0022:   unit oscpmdata;
0023:   
0024:   interface
0025:   
0026:   USES Windows, Controls, Classes, SysUtils, ComCtrls, Graphics;
0027:   
0028:   
0029:   CONST
0030:     opmC_FindByID = 1;
0031:     opmC_FindByIndex = 2;
0032:     opmC_FindByNode = 3;
0033:     opmC_SQLSelect = 0;
0034:     opmC_SQLInsert = 1;
0035:     opmC_SQLUpdate = 2;
0036:     opmC_SQLDelete = 3;
0037:     opmC_SQLDelIns = 4;
0038:     opmC_SQLDelInsNoZero = 5;
0039:     opmC_ImageDontExist = 0;
0040:     opmC_ImageMayExist = 1;
0041:     opmC_ImageExists = 2;
0042:     opmC_ImageIsEmpty = 3;
0043:     opmC_ImageIsCorrupt = 4;
0044:     opmC_ImageIsBeingProcessed = 5;
0045:     opmC_ConnStatNo = 0;
0046:     opmC_ConnStatYes = 1;
0047:     opmC_ConnStatUnknown = 2;
0048:     opmC_ConnStatIgnore = -1;
0049:     opmC_ProgressNone = 0;
0050:     opmC_ProgressIgnore = -1;
0051:     opmC_PTotalIgnore = -1;
0052:     opmC_SearchIgnore = 0;
0053:     opmC_SearchNo = 1;
0054:     opmC_SearchYes = 2;
0055:     opmC_AppName1 = 'osCommerce Product Manager';
0056:     opmC_AppName2 = 'for Windows';
0057:     opmC_AppShortName = 'oscpmwin';
0058:     opmC_Version = '0.4.1';
0059:     opmC_VisHomepageURL = 'http://www.mariovaldez.net/software/oscpmwin/';
0060:     opmC_HomepageURL = 'http://www.mariovaldez.net/software/oscpmwin/remote.php';
0061:     opmC_WebForumsURL = 'http://www.mariovaldez.net/webapps/forums/remote.php';
0062:     opmC_RedirParameter = 'v';
0063:     opmC_Copyright = 'Copyright 2003-2007 by Mario A. Valdez-Ramirez';
0064:     opmC_Email = 'mario@mariovaldez.org';
0065:     opmC_EmailURL = 'mailto:mario@mariovaldez.org';
0066:     opmC_OSCAppName = 'osCommerce 2.2';
0067:     opmC_OSCHomepageURL = 'http://www.oscommerce.com/';
0068:     opmC_OSCCopyright = 'by Harald Ponce de Leon';
0069:     opmC_UserAgent = opmC_AppShortName + '/' + opmC_Version;
0070:     opmC_CheckUpdates_URL = 'http://www.mariovaldez.net/software/oscpmwin/checkupdates.php';
0071:   
0072:     opmC_Max_DBQuery_Records = 700000;
0073:     opmC_Max_DBQuery_Fields = 50;
0074:   
0075:     opmC_Max_Products_PerList = 50000;
0076:     opmC_Max_Descriptions_PerList = 1000000;
0077:     opmC_Max_Languages_PerList = 20;
0078:     opmC_Max_Categories_PerList = 10000;
0079:     opmC_Max_Menufacturers_PerList = 8000;
0080:     opmC_Max_Taxes_PerList = 150;
0081:     opmC_Max_Currencies_PerList = 25;
0082:     opmC_Max_Config_PerList = 500;
0083:   
0084:     opmC_Def_PDFAuthor = '';
0085:     opmC_Def_Username = 'root';
0086:     opmC_Def_Password = 'root';
0087:     opmC_Def_ImgURL = 'http://localhost/catalog/images/';
0088:     opmC_Def_UploadURL = 'http://localhost/catalog/oscpm1_upload.php';
0089:     opmC_Def_ProxyHost = 'proxy';
0090:     opmC_Def_ProxyPort = 3128;
0091:     opmC_Def_ModConnWait = 3000;
0092:     opmC_Def_HTTPConnWait = 5000;
0093:     opmC_Def_HTTPWaitFactor = 25;
0094:     opmC_Def_ModConnRetries = 2;
0095:     opmC_Def_HTTPConnRetries = 2;
0096:     opmC_Def_HTTPProtocol = 'http';
0097:     opmC_Def_ImgX = 200;
0098:     opmC_Def_ImgY = 250;
0099:     opmC_Def_ImgQ = 50;
0100:     opmC_Def_PaddingColor = 16777215;
0101:     opmC_Min_Port = 1;
0102:     opmC_Max_Port = 65535;
0103:     opmC_Min_ProxyPort = 1;
0104:     opmC_Max_ProxyPort = 65535;
0105:     opmC_Min_ModConnWait = 1000;
0106:     opmC_Max_ModConnWait = 60000;
0107:     opmC_Min_HTTPConnWait = 1000;
0108:     opmC_Max_HTTPConnWait = 60000;
0109:     opmC_Min_ModConnRetries = 1;
0110:     opmC_Max_ModConnRetries = 50;
0111:     opmC_Min_HTTPConnRetries = 1;
0112:     opmC_Max_HTTPConnRetries = 50;
0113:     opmC_Min_ImgX = 20;
0114:     opmC_Max_ImgX = 1024;
0115:     opmC_Min_ImgY = 20;
0116:     opmC_Max_ImgY = 1024;
0117:     opmC_Min_ImgQ = 0;
0118:     opmC_Max_ImgQ = 100;
0119:     opmC_RootCategory = 'Catalog';
0120:     opmC_DefWindow_XSize = 1016;
0121:     opmC_MinWindow_XSize = 300;
0122:     opmC_MaxWindow_XSize = 2000;
0123:     opmC_DefWindow_YSize = 600;
0124:     opmC_MinWindow_YSize = 200;
0125:     opmC_MaxWindow_YSize = 2000;
0126:     opmC_DefPWindow_XSize = 500;
0127:     opmC_MinPWindow_XSize = 500;
0128:     opmC_MaxPWindow_XSize = 2000;
0129:     opmC_DefPWindow_YSize = 500;
0130:     opmC_MinPWindow_YSize = 500;
0131:     opmC_MaxPWindow_YSize = 2000;
0132:     opmC_DefCatList_Size = 200;
0133:     opmC_MinCatList_Size = 50;
0134:     opmC_MaxCatList_Size = 500;
0135:     opmC_DefGauge_Size = 150;
0136:     opmC_DefCurPan_Size = 40;
0137:     opmC_DefMemPan_Size = 100;
0138:     opmC_Def_DisplayLang = 1;
0139:     opmC_Def_Col0X = 25;
0140:     opmC_Def_Col1X = 40;
0141:     opmC_Def_Col2X = 85;
0142:     opmC_Def_Col3X = 90;
0143:     opmC_Def_Col4X = 200;
0144:     opmC_Def_Col5X = 100;
0145:     opmC_Def_Col6X = 32;
0146:     opmC_Def_Col7X = 76;
0147:     opmC_Def_Col8X = 32;
0148:     opmC_Def_Col9X = 100;
0149:     opmC_Def_Col10X = 20;
0150:     opmC_Def_Col20X = 110;
0151:     opmC_Def_Col21X = 110;
0152:     opmC_Def_Col22X = 110;
0153:     opmC_MinColX = 25;
0154:     opmC_Def_Col0Align = taLeftJustify;
0155:     opmC_Def_Col1Align = taRightJustify;
0156:     opmC_Def_Col2Align = taLeftJustify;
0157:     opmC_Def_Col3Align = taLeftJustify;
0158:     opmC_Def_Col4Align = taLeftJustify;
0159:     opmC_Def_Col5Align = taLeftJustify;
0160:     opmC_Def_Col6Align = taRightJustify;
0161:     opmC_Def_Col7Align = taRightJustify;
0162:     opmC_Def_Col8Align = taRightJustify;
0163:     opmC_Def_Col9Align = taLeftJustify;
0164:     opmC_Def_Col10Align = taCenter;
0165:     opmC_Def_Col20Align = taLeftJustify;
0166:     opmC_Def_Col21Align = taLeftJustify;
0167:     opmC_Def_Col22Align = taLeftJustify;
0168:     opmC_Def_RememberDisplay = 1;
0169:     opmC_Def_HotTracking = 0;
0170:     opmC_Def_Autoload = 1;
0171:     opmC_Def_DragDrop = 0;
0172:     opmC_Def_ImgDragDrop = 0;
0173:     opmC_Def_ToolTips = 1;
0174:     opmC_Def_Stripes = 1;
0175:     opmC_Def_CacheIList = 1;
0176:     opmC_Def_UseProxy = 0;
0177:     opmC_Def_ProxyApply = 0;
0178:     opmC_Def_StorePass = 1;
0179:     opmC_Def_Silent = 0;
0180:     opmC_Def_ConfirmDels = 1;
0181:     opmC_Def_ConfirmDrag = 0;
0182:     opmC_Def_ConfirmMods = 0;
0183:     opmC_Def_AllowZeroPrice = 0;
0184:     opmC_Def_AllowEditImageName = 0;
0185:     opmC_Def_AllowNegativeQuantity = 0;
0186:     opmC_Def_AutoDownImg = 0;
0187:     opmC_Def_NoCacheImg = 0;
0188:     opmC_Def_ResizeImg = 1;
0189:     opmC_Def_WatermarkImg = 0;
0190:     opmC_Def_WatermarkFile = '';
0191:     opmC_Def_WatermarkBlend = 85;
0192:     opmC_Min_WatermarkBlend = 0;
0193:     opmC_Max_WatermarkBlend = 100;
0194:     opmC_Def_PaddingImg = 1;
0195:     opmC_Def_KeepARImg = 1;
0196:     opmC_Def_ConfirmExit = 1;
0197:     opmC_Def_CenterImage = 1;
0198:     opmC_Def_DBDebugLog = 0;
0199:     opmC_Def_HTTPCompress = 1;
0200:     opmC_Def_WBDebug = 0;
0201:     opmC_Def_GUILang = 'en';
0202:   
0203:     opmC_Def_CurrLSymbol = '$';
0204:     opmC_Def_CurrRSymbol = '';
0205:     opmC_Def_CurrCode = '';
0206:     opmC_Def_CurrDecSep = '.';
0207:     opmC_Def_CurrThoSep = ',';
0208:     opmC_Def_CurrPrecision = 2;
0209:     opmC_Def_CurrValue = 1;
0210:     opmC_CurrName_MaxLen = 32;
0211:     opmC_CurrCode_MaxLen = 3;
0212:     opmC_CurrLSymbol_MaxLen = 12;
0213:     opmC_CurrRSymbol_MaxLen = 12;
0214:     opmC_CurrDecSep_MaxLen = 1;
0215:     opmC_CurrThoSep_MaxLen = 1;
0216:     opmC_CurrPrecision_Max = 9;
0217:     opmC_CurrPrecision_Min = 0;
0218:     opmC_CurrValue_MaxLen = 14;
0219:     opmC_CurrValue_MaxInt = 5;
0220:     opmC_CurrValue_MaxDec = 8;
0221:     opmC_TaxValue_MaxLen = 8;
0222:     opmC_TaxValue_MaxInt = 3;
0223:     opmC_TaxValue_MaxDec = 4;
0224:     opmC_DBUsername_MaxLen = 128;
0225:     opmC_DBPassword_MaxLen = 128;
0226:     opmC_ProdModel_MaxLen = 25;
0227:     opmC_ProdName_MaxLen = 64;
0228:     opmC_ProdWeight_MaxLen = 6;
0229:     opmC_ProdWeight_MaxInt = 3;
0230:     opmC_ProdWeight_MaxDec = 2;
0231:     opmC_ProdPrice_MaxLen = 16;
0232:     opmC_ProdPrice_MaxInt = 11;
0233:     opmC_ProdPrice_MaxDec = 4;
0234:     opmC_ProdQuantity_MaxLen = 16;
0235:     opmC_ProdURL_MaxLen = 255;
0236:     opmC_ProdImageURL_MaxLen = 64;
0237:     opmC_ProdDescription_MaxLen = 32000;
0238:     opmC_ProdSpecial_MaxLen = 16;
0239:     opmC_ProdSpecial_MaxInt = 11;
0240:     opmC_ProdSpecial_MaxDec = 4;
0241:     opmC_CatName_MaxLen = 32;
0242:     opmC_LangName_MaxLen = 32;
0243:     opmC_ManName_MaxLen = 32;
0244:     opmC_PDFAuthor_MaxLen = 128;
0245:   
0246:     opmC_CatList_Spacer = ' ';
0247:     opmC_Bevel_Size = 2;
0248:     opmC_Wait_Mouse = crHourGlass;
0249:     opmC_Normal_Mouse = crDefault;
0250:     opmC_MaxPast_Usernames = 10;
0251:     opmC_MaxPast_ImgURL = 10;
0252:     opmC_MaxPast_UploadURL = 10;
0253:     opmC_MaxPast_Proxy = 10;
0254:     opmC_Unamed_Cat = '- - - - - - - -';
0255:     opmC_Unamed_Man = '- - - - - - - -';
0256:     opmC_Unamed_Prod = '- - - - - - - -';
0257:     opmC_Unamed_Tax = '- - - - - - - -';
0258:     opmC_Unamed_Currency = '- - - - - - - -';
0259:     opmC_Unamed_CurrencyCode = 'XXX';
0260:     opmC_Def_ExportExt = 'txt';
0261:     opmC_Def_ExportFilename = 'export_products.txt';
0262:     opmC_Def_ExportFilter = '*.txt;*.csv;*.tab';
0263:     opmC_Def_ImportExt = 'txt';
0264:     opmC_Def_ImportFilename = 'import_products.txt';
0265:     opmC_Def_ImportFilter = '*.txt;*.csv;*.tab';
0266:     opmC_ExportSeparator = #9;
0267:     opmC_ExportJSeparator = ' | ';
0268:     opmC_ExportJHSeparator = '-';
0269:     opmC_PasswordChar = '*';
0270:   
0271:     opmC_WebScriptVersion = '0.9.6';
0272:     opmC_WebScriptOKCode = 'MVOSCPM1_NOERROR';
0273:     opmC_WebScriptERRORCode = 'MVOSCPM1_ERROR';
0274:     opmC_WebScriptCorruptCode = 999;
0275:     opmC_WebScriptDefaultCode = 100;
0276:     opmC_WebScriptUnknownCode = 200;
0277:     opmC_WebDefaultCode = 50;
0278:   
0279:     opmC_InsertProdID = 99999999;
0280:     opmC_MaxMemoryLoad = 90;
0281:     opmC_DefaultFont = 'Arial';
0282:     opmC_DefaultFontHeight = -11;
0283:     opmC_DefaultFontCharset = DEFAULT_CHARSET;
0284:     opmC_DefaultFontStyle = [];
0285:     opmC_Min_FontHeight = 6;
0286:     opmC_Max_FontHeight = 100;
0287:     opmC_Def_Clip_ColSize = 30;
0288:     opmC_Min_Clip_ColSize = 3;
0289:     opmC_Max_Clip_ColSize = 400;
0290:     opmC_Def_PRNDirectPrint = 0;
0291:     opmC_PrintTitle_Separator = '-';
0292:     opmC_MiliSecIncrement = 1000;
0293:     opmC_DBTableID_Categories = 'TABLE_CATEGORIES';
0294:     opmC_DBTableID_Manufacturers = 'TABLE_MANUFACTURERS';
0295:     opmC_DBTableID_Languages = 'TABLE_LANGUAGES';
0296:     opmC_DBTableID_Products = 'TABLE_PRODUCTS';
0297:     opmC_DBTableID_Specials = 'TABLE_SPECIALS';
0298:     opmC_DBTableID_ProductsDescription = 'TABLE_PRODUCTS_DESCRIPTION';
0299:     opmC_DBTableID_TaxClass = 'TABLE_TAX_CLASS';
0300:     opmC_DBTableID_Currencies = 'TABLE_CURRENCIES';
0301:     opmC_DBTableID_Configuration = 'TABLE_CONFIGURATION';
0302:     opmC_DBTableID_ProductsToCategories = 'TABLE_PRODUCTS_TO_CATEGORIES';
0303:     opmC_DBTableID_CategoriesDescription = 'TABLE_CATEGORIES_DESCRIPTION';
0304:     opmC_DBTableID_TaxRates = 'TABLE_TAX_RATES';
0305:     opmC_DBTableID_ManufacturersInfo = 'TABLE_MANUFACTURERS_INFO';
0306:     opmC_DebugFile = 'OSCDEBUG.TXT';
0307:     opmC_DebugFileSeparator = '======================================';
0308:     opmC_Def_PDate = 36161;  {01/01/1999}
0309:     opmC_Max_PDate = 44196;  {31/12/2020}
0310:     opmC_Min_PDate = 29221;  {01/01/1980}
0311:     opmC_PDate_Format = 'yyyy-MM-dd';
0312:     opmC_Def_Past_PAvailDate = opmC_Def_PDate;
0313:     opmC_Def_Past_PManufacturer = 0;
0314:     opmC_Def_Past_PTaxClass = 0;
0315:     opmC_Def_Past_PImageDir = '';
0316:   
0317:     opmC_DirReports = 'reports';
0318:     opmC_Report_ProdList1 = 'prodlist1.frf';
0319:     opmC_Def_ReportExt = 'frf';
0320:     opmC_Def_PrintPDFExt = 'pdf';
0321:     opmC_Def_PrintPDFFilename = 'prodlist1.pdf';
0322:     opmC_Def_PrintPDFFilter = '*.pdf';
0323:   
0324:     opmC_ETABitrates = '28 kbps (dialup)'#13#10'56 kbps (dialup)'#13#10'64 kbps (ISDN)'#13#10'128 kbps (ISDN, ADSL, Cable)'#13#10'256 kbps (ADSL, Cable)'#13#10'512 kbps (ADSL, Cable)'#13#10'1500 kbps (ADSL, Cable, LAN)';
0325:     opmC_Def_ETABase = '28';
0326:   
0327:     opmC_SC_Parent = 9999999;
0328:     opmC_SC_BaseID = 10000000;
0329:     opmC_SC_TrashCanID = 10000001;
0330:     opmC_SC_TrashCanIndex = 10000001;
0331:   
0332:     opmC_Capa_OSCommerce = 'OSCSTANDARD';
0333:     opmC_Capa_ZenCart = 'ZENCART';
0334:     opmC_Capa_MorePics6 = 'MOREPICS6';
0335:     opmC_Capa_TotalB2B = 'TOTALB2B';
0336:     opmC_Capa_PollBooth = 'POLLBOOTH';
0337:     opmC_Capa_HeaderTags = 'HEADERTAGS';
0338:   
0339:     opmC_DirBackups = 'backups';
0340:     opmC_Def_BackupExt = 'gz';
0341:     opmC_Def_BackupFilename = '';
0342:     opmC_Def_BackupFilter = '*.gz';
0343:     opmC_TmpBak_Filename = 'oscpmtmp.bak';
0344:   
0345:     opmC_DBTag_RecBegin = 'BR';
0346:     opmC_DBTag_RecEnd = 'ER';
0347:     opmC_DBTag_DataField = 'DF';
0348:     opmC_DBTag_DataBegin = '[';
0349:     opmC_DBTag_DataEnd = ']';
0350:     opmC_DBTag_Comment = '#';
0351:     opmC_DBTag_Stat = 'ST';
0352:     opmC_DBTag_FieldList = 'FL';
0353:   
0354:     opmC_ConfigKey_StoreName = 'STORE_NAME';
0355:     opmC_HashingStrengh = 100;
0356:     opmC_DefErrorDataLen = 200; 
0357:   
0358:   
0359:   TYPE
0360:     opmR_Category = RECORD
0361:                        ID : LONGINT;
0362:                        Parent : LONGINT;
0363:                        Name : STRING;
0364:                        TreeIndex : LONGINT;
0365:                        ListIndex : LONGINT;
0366:                        ImageURL : STRING;
0367:                      END;
0368:     opmR_SingleCategory = RECORD
0369:                             ID : LONGINT;
0370:                             Parent : LONGINT;
0371:                             Name : STRING;
0372:                             LanguageID : LONGINT;
0373:                             ImageURL : STRING;
0374:                           END;
0375:     opmR_Manufacturer = RECORD
0376:                            ID : LONGINT;
0377:                            Name : STRING;
0378:                            ListIndex : LONGINT;
0379:                            ImageURL : STRING;
0380:                          END;
0381:     opmR_Language = RECORD
0382:                        ID : LONGINT;
0383:                        Name : STRING;
0384:                        ListIndex : LONGINT;
0385:                      END;
0386:     opmR_Product = RECORD
0387:                        ID : LONGINT;
0388:                        Model : STRING;
0389:                        Quantity : LONGINT;
0390:                        Price : CURRENCY;
0391:                        Weight : CURRENCY;
0392:                        ManufacturerID : LONGINT;
0393:                        CategoryID : LONGINT;
0394:                        DisplayName : STRING;
0395:                        ImageURL : STRING;
0396:                        Available : LONGINT;
0397:                        Special : CURRENCY;
0398:                        LanguageID : LONGINT;
0399:                        Tax : LONGINT;
0400:                        AvailDate : TDateTime;
0401:                        CreationDate : TDateTime;
0402:                        ChangeDate : TDateTime;
0403:                        ImageURL1, ImageURL2, ImageURL3, ImageURL4, ImageURL5, ImageURL6 : STRING;
0404:                      END;
0405:     opmR_Description = RECORD
0406:                          ID : LONGINT;
0407:                          Name : STRING;
0408:                          Description : STRING;
0409:                          URL : STRING;
0410:                          LanguageID : LONGINT;
0411:                          Viewed : LONGINT;
0412:                        END;
0413:     opmR_Tax = RECORD
0414:                  ID : LONGINT;
0415:                  Name : STRING;
0416:                  ListIndex : LONGINT;
0417:                  SumRate : CURRENCY;
0418:                END;
0419:     opmR_Currency = RECORD
0420:                      ID : LONGINT;
0421:                      Name : STRING;
0422:                      Code : STRING;
0423:                      Left : STRING;
0424:                      Right : STRING;
0425:                      DecimalSep : STRING;
0426:                      ThousandSep : STRING;
0427:                      Precision : LONGINT;
0428:                      Value : CURRENCY;
0429:                      NewValue : CURRENCY;
0430:                      ListIndex : LONGINT;
0431:                      Default : BOOLEAN;
0432:                    END;
0433:     opmR_Config = RECORD
0434:                     ID : LONGINT;
0435:                     Title : STRING;
0436:                     Key : STRING;
0437:                     Value : STRING;
0438:                     Description : STRING;
0439:                     GroupID : LONGINT;
0440:                     SetFunction : STRING;
0441:                   END;
0442:     opmT_CategoryList = ARRAY [0..opmC_Max_Categories_PerList] OF opmR_Category;
0443:     opmT_ManufacturerList = ARRAY [0..opmC_Max_Menufacturers_PerList] OF opmR_Manufacturer;
0444:     opmT_LanguageList = ARRAY [0..opmC_Max_Languages_PerList] OF opmR_Language;
0445:     opmT_ProductList = ARRAY [0..opmC_Max_Products_PerList] OF opmR_Product;
0446:     opmT_DescriptionList = ARRAY [0..opmC_Max_Descriptions_PerList] OF opmR_Description;
0447:     opmT_TaxList = ARRAY [0..opmC_Max_Taxes_PerList] OF opmR_Tax;
0448:     opmT_SingleDescList = ARRAY [0..opmC_Max_Languages_PerList] OF opmR_Description;
0449:     opmT_CurPosDescList = ARRAY [0..opmC_Max_Languages_PerList] OF INTEGER;
0450:     opmT_CharsetList = ARRAY [0..255] OF STRING;
0451:     opmT_SingleCatList = ARRAY [0..opmC_Max_Languages_PerList] OF opmR_SingleCategory;
0452:     opmT_CurrencyList = ARRAY [0..opmC_Max_Currencies_PerList] OF opmR_Currency;
0453:     opmT_ConfigList = ARRAY [0..opmC_Max_Config_PerList] OF opmR_Config;
0454:   
0455:     opmT_DBQuery_Dataset = ARRAY OF ARRAY OF STRING;
0456:     opmR_DBQuery_Recordset = RECORD
0457:                                RowCount : LONGINT;
0458:                                ColCount : LONGINT;
0459:                                DataRows : LONGINT;
0460:                                DataCols : LONGINT;
0461:                                DataSize : LONGINT;
0462:                                OrigSize : LONGINT;
0463:                                Data : opmT_DBQuery_Dataset;
0464:                              END;
0465:   
0466:   
0467:   VAR
0468:     opmG_TMPPath : STRING;
0469:     opmG_ETABase : LONGINT;
0470:     opmG_PDFAuthor : STRING;
0471:     opmG_DBUsername : STRING;
0472:     opmG_DBPassword : STRING;
0473:     opmG_WBImgURL : STRING;
0474:     opmG_WBUploadURL : STRING;
0475:     opmG_WBProxyHost : STRING;
0476:     opmG_WBProxyPort : LONGINT;
0477:     opmG_ModConnWait : LONGINT;
0478:     opmG_HTTPConnWait : LONGINT;
0479:     opmG_ModConnRetries : LONGINT;
0480:     opmG_HTTPConnRetries : LONGINT;
0481:     opmG_WBImgX : LONGINT;
0482:     opmG_WBImgY : LONGINT;
0483:     opmG_WBImgQ : LONGINT;
0484:     opmG_WBPaddingColor : LONGINT;
0485:     opmG_UIWindow_XSize : LONGINT;
0486:     opmG_UIWindow_YSize : LONGINT;
0487:     opmG_UIWindow_XPos : LONGINT;
0488:     opmG_UIWindow_YPos : LONGINT;
0489:     opmG_UICatList_XSize : LONGINT;
0490:     opmG_UICol0X, opmG_UICol1X, opmG_UICol2X, opmG_UICol3X, opmG_UICol4X, opmG_UICol5X, opmG_UICol6X, opmG_UICol7X, opmG_UICol8X, opmG_UICol9X, opmG_UICol10X : LONGINT;
0491:     opmG_UICol20X, opmG_UICol21X, opmG_UICol22X : LONGINT;
0492:     opmG_UIRememberDisplay : WORD;
0493:     opmG_UIHotTracking : WORD;
0494:     opmG_UIClickLoad : WORD;
0495:     opmG_UIDragDrop : WORD;
0496:     opmG_UIImgDragDrop : WORD;
0497:     opmG_UIToolTips : WORD;
0498:     opmG_UIStripes : WORD;
0499:     opmG_UICacheIList : WORD;
0500:     opmG_UseProxy : WORD;
0501:     opmG_ProxyApply : WORD;
0502:     opmG_DBStorePass : WORD;
0503:     opmG_UISilent : WORD;
0504:     opmG_UIConfirmDels : WORD;
0505:     opmG_UIConfirmDrag : WORD;
0506:     opmG_UIConfirmMods : WORD;
0507:     opmG_UIAllowZeroPrice : WORD;
0508:     opmG_UIAllowEditImageName : WORD;
0509:     opmG_UIAllowNegativeQuantity : WORD;
0510:     opmG_UIAutoDownImg : WORD;
0511:     opmG_WBNoCacheImg : WORD;
0512:     opmG_WBResizeImg : WORD;
0513:     opmG_WBWatermarkImg : WORD;
0514:     opmG_WBWatermarkFile : STRING;
0515:     opmG_WBWatermarkBlend : LONGINT;
0516:     opmG_WBPaddingImg : WORD;
0517:     opmG_WBKeepARImg : WORD;
0518:     opmG_UIConfirmExit : WORD;
0519:     opmG_UICenterImage : WORD;
0520:     opmG_DBDebugLog : WORD;
0521:     opmG_HTTPCompress : WORD;
0522:     opmG_UIWBDebug : WORD;
0523:     opmG_UIGUILang : STRING;
0524:     opmG_Past_PAvailDate : LONGINT;
0525:     opmG_Past_PManufacturer : LONGINT;
0526:     opmG_Past_PTaxClass : LONGINT;
0527:     opmG_Past_PImageDir : STRING;
0528:     opmG_FullUserAgent : STRING;
0529:   
0530:     opmG_PastUsername_BoxList : TStringList;
0531:     opmG_PastImgURL_BoxList : TStringList;
0532:     opmG_PastUploadURL_BoxList : TStringList;
0533:     opmG_PastProxy_BoxList : TStringList;
0534:   
0535:     opmG_CategoryList : opmT_CategoryList;
0536:     opmG_ManufacturerList : opmT_ManufacturerList;
0537:     opmG_LanguageList : opmT_LanguageList;
0538:     opmG_ProductList : opmT_ProductList;
0539:     opmG_DescriptionList : opmT_DescriptionList;
0540:     opmG_TaxList : opmT_TaxList;
0541:     opmG_CurrencyList : opmT_CurrencyList;
0542:     opmG_ConfigList : opmT_ConfigList;
0543:     opmG_CategoryBoxList : TStringList;
0544:     opmG_ManufacturerBoxList : TStringList;
0545:     opmG_LanguageBoxList : TStringList;
0546:     opmG_TaxBoxList : TStringList;
0547:     opmG_CurrencyBoxList : TStringList;
0548:     opmG_Cache_ImageDirList : TStringList;
0549:     opmG_Cache_ImageList : TStringList;
0550:   
0551:     opmG_DBTableList : TStringList;
0552:   
0553:     opmG_DBQuery_Recordset : opmR_DBQuery_Recordset;
0554:   
0555:     opm_TotalCategories : LONGINT;
0556:     opm_TotalManufacturers : LONGINT;
0557:     opm_TotalLanguages : LONGINT;
0558:     opm_TotalProducts : LONGINT;
0559:     opm_TotalTaxes : LONGINT;
0560:     opm_TotalCurrencies : LONGINT;
0561:     opm_TotalConfig : LONGINT;
0562:   
0563:     opm_CurrentLang : LONGINT;
0564:     opm_CurrentCategory : LONGINT;
0565:     opm_CurrentMan : LONGINT;
0566:     opm_CurrentProdID : LONGINT;
0567:     opm_CurrentProdRecord : opmR_Product;
0568:     opm_CurrentSingleDescList : opmT_SingleDescList;
0569:     opm_CurrentPEditRecord : opmR_Product;
0570:     opm_CurrentLangRecord : opmR_Language;
0571:     opm_CurrentCatRecord : opmR_Category;
0572:     opm_CurrentManRecord : opmR_Manufacturer;
0573:     opm_CurrentTaxRecord : opmR_Tax;
0574:     opm_CurrentCurrency : opmR_Currency;
0575:     opm_Search_PCategory : LONGINT;
0576:     opm_Search_PManufacturer : LONGINT;
0577:     opm_Search_PModel, opm_Search_PName, opm_Search_PDesc : STRING;
0578:     opm_Search_PSPrice, opm_Search_PImagURL, opm_Search_PAvailable : LONGINT;
0579:     opm_Search_Quick : STRING;
0580:     opm_CanExpandTree_Flag : BOOLEAN;
0581:     opm_WeAreSearching : BOOLEAN;
0582:     opm_WeAreFullScreen : BOOLEAN;
0583:     opm_StopTreeOnChange : BOOLEAN;
0584:     opmG_UIFontName : STRING;
0585:     opmG_UIFontHeight : LONGINT;
0586:     opmG_UIFontCharset : LONGINT;
0587:     opmG_CharsetList : opmT_CharsetList;
0588:     opmG_Clip_ColSize : LONGINT;
0589:     opmG_PRNDirectPrint : WORD;
0590:     opmG_DBTable_Categories : STRING;
0591:     opmG_DBTable_Manufacturers : STRING;
0592:     opmG_DBTable_Languages : STRING;
0593:     opmG_DBTable_Products : STRING;
0594:     opmG_DBTable_Specials : STRING;
0595:     opmG_DBTable_ProductsDescription : STRING;
0596:     opmG_DBTable_TaxClass : STRING;
0597:     opmG_DBTable_Currencies : STRING;
0598:     opmG_DBTable_Configuration : STRING;
0599:     opmG_DBTable_ProductsToCategories : STRING;
0600:     opmG_DBTable_CategoriesDescription : STRING;
0601:     opmG_DBTable_TaxRates : STRING;
0602:     opmG_DBTable_ManufacturersInfo : STRING;
0603:     opmG_PList_LastOrderColumn : LONGINT;
0604:     opmG_PList_LastOrderType : BOOLEAN;
0605:     opmG_Cur_PPrintID : LONGINT;
0606:     opmG_Cur_PPrintRecord : opmR_Product;
0607:     opmG_Cur_PrintListItem : TListItem;
0608:     opmG_Cur_PPrintEOF : BOOLEAN;
0609:     opmG_Cur_PPrintTitle : STRING;
0610:     opmG_Cur_PPrintTitle2 : STRING;
0611:     opmG_Cur_PDFSubject : STRING;
0612:   
0613:     opmG_Capa_OSCommerce : BOOLEAN;
0614:     opmG_Capa_ZenCart : BOOLEAN;
0615:     opmG_Capa_MorePics6 : BOOLEAN;
0616:     opmG_Capa_TotalB2B : BOOLEAN;
0617:     opmG_Capa_PollBooth : BOOLEAN;
0618:     opmG_Capa_HeaderTags : BOOLEAN;
0619:     opmG_CurrentStoreName : STRING;
0620:   
0621:     opm_CurrentProdID_CB : LONGINT;
0622:     opm_CurrentProdRecord_CB : opmR_Product;
0623:     opm_CurrentSingleDescList_CB : opmT_SingleDescList;
0624:   
0625:     opmG_StripeColor : TColor;
0626:   
0627:     opmG_PHPInfo : STRING;
0628:   
0629:   
0630:   
0631:   IMPLEMENTATION
0632:   
0633:   INITIALIZATION
0634:   
0635:     opmG_CategoryBoxList := TStringList.Create;
0636:     opmG_ManufacturerBoxList := TStringList.Create;
0637:     opmG_LanguageBoxList := TStringList.Create;
0638:     opmG_TaxBoxList := TStringList.Create;
0639:     opmG_CurrencyBoxList := TStringList.Create;
0640:     opmG_PastUsername_BoxList := TStringList.Create;
0641:     opmG_PastImgURL_BoxList := TStringList.Create;
0642:     opmG_PastUploadURL_BoxList := TStringList.Create;
0643:     opmG_PastProxy_BoxList := TStringList.Create;
0644:     opmG_Cache_ImageDirList := TStringList.Create;
0645:     opmG_Cache_ImageList := TStringList.Create;
0646:     opmG_DBTableList := TStringList.Create;
0647:     DateSeparator := '-';
0648:     ShortDateFormat	:= 'yyyy/mm/dd';
0649:     DecimalSeparator := '.';
0650:     ThousandSeparator := ',';
0651:     opmG_CharsetList[0] := 'ansi';
0652:     opmG_CharsetList[1] := 'default';
0653:     opmG_CharsetList[2] := 'symbol';
0654:     opmG_CharsetList[77] := 'mac';
0655:     opmG_CharsetList[128] := 'shiftjis';
0656:     opmG_CharsetList[129] := 'hangeul';
0657:     opmG_CharsetList[130] := 'johab';
0658:     opmG_CharsetList[134] := 'gb2312';
0659:     opmG_CharsetList[136] := 'chinesebig5';
0660:     opmG_CharsetList[161] := 'greek';
0661:     opmG_CharsetList[162] := 'turkish';
0662:     opmG_CharsetList[163] := 'vietnamese';
0663:     opmG_CharsetList[177] := 'hebrew';
0664:     opmG_CharsetList[178] := 'arabic';
0665:     opmG_CharsetList[186] := 'baltic';
0666:     opmG_CharsetList[204] := 'russian';
0667:     opmG_CharsetList[222] := 'thai';
0668:     opmG_CharsetList[238] := 'easteurope';
0669:     opmG_CharsetList[255] := 'oem';
0670:   
0671:     opmG_DBQuery_Recordset.RowCount := 0;
0672:     opmG_DBQuery_Recordset.ColCount := 0;
0673:     opmG_DBQuery_Recordset.DataRows := 0;
0674:     opmG_DBQuery_Recordset.DataCols := 0;
0675:     SetLength (opmG_DBQuery_Recordset.Data, opmG_DBQuery_Recordset.RowCount, opmG_DBQuery_Recordset.ColCount);
0676:   
0677:   
0678:   FINALIZATION
0679:   
0680:     FreeAndNIL (opmG_CategoryBoxList);
0681:     FreeAndNIL (opmG_ManufacturerBoxList);
0682:     FreeAndNIL (opmG_LanguageBoxList);
0683:     FreeAndNIL (opmG_TaxBoxList);
0684:     FreeAndNIL (opmG_CurrencyBoxList);
0685:     FreeAndNIL (opmG_PastUsername_BoxList);
0686:     FreeAndNIL (opmG_PastImgURL_BoxList);
0687:     FreeAndNIL (opmG_PastUploadURL_BoxList);
0688:     FreeAndNIL (opmG_PastProxy_BoxList);
0689:     FreeAndNIL (opmG_Cache_ImageDirList);
0690:     FreeAndNIL (opmG_Cache_ImageList);
0691:     FreeAndNIL (opmG_DBTableList);
0692:   
0693:   end.
 
 
NA fum/lmd: 2007.07.15
Copyright ©1994-2018 by Mario A. Valdez-Ramírez.
no siga este enlace / do not follow this link