function doOnload(){if(!bol_isUserCustomerGroup&&(!bol_isUserEmployee&&bol_isUserLinked||bol_isUserEmployee&&bol_isUserImpersonating)){doCustomerItemNumbersExist();}if(intAdCount>=1&&document.getElementById('divAdContainer')){document.getElementById('divAdContainer').style.display='';}doResetTimer();doStartTimer();try{doPrefetch0()}catch(ex){}}function doGetDivContents(str_doGetDivContents_reqCls,str_doGetDivContents_div){var oXhr = new AS.xhr();oXhr.elementUpdate('/catalog/searchAssistant.asp?reqCls='+encodeURIComponent(str_doGetDivContents_reqCls)+'&warehouseId='+encodeURIComponent(intWarehouseID),str_doGetDivContents_div,true,true,false);}function doUpdateTimer(){if(intTimerID){clearTimeout(intTimerID);clockID=0;}if(!strStartTime){strStartTime= new Date();}var tDate= new Date();var tDiff= tDate.getTime()-strStartTime.getTime();tDate.setTime(tDiff);intTimerID=setTimeout('doUpdateTimer()',1000);if (tDate.getSeconds()==6||bolAdFirst==false){with(document){if(getElementById('imgAd')){getElementById('imgAd').src=aryImage[intAdCounter];getElementById('imgAd').alt=aryTitle[intAdCounter];getElementById('adId').value=intAdCounter;}}intAdCounter=intAdCounter+1;if(intAdCounter==intAdCount){intAdCounter=0;}bolAdFirst=true;doResetTimer();}}function doPreviousAd(){doStopTimer();intAdCounter=intAdCounter-1;if(intAdCounter<=0){intAdCounter=intAdCount}with(document){if(getElementById('imgAd')){getElementById('imgAd').src=aryImage[intAdCounter-1];getElementById('imgAd').alt=aryTitle[intAdCounter-1];getElementById('adId').value=intAdCounter-1;}}doResetTimer();doStartTimer();}function doStartTimer(){strStartTime = new Date();intTimerID = setTimeout('doUpdateTimer()',1000)}function doStopTimer(){if(intTimerID){clearTimeout(intTimerID);intTimerID=0;}strStartTime=null;}function doResetTimer(){strStartTime=null}function doResetTimer(){strStartTime=null}function doCustomerItemNumbersExist(){var oXhr = new AS.xhr();oXhr.get('/catalog/searchAssistant.asp?reqCls=doCustomerItemNumbersExist',doHandlerCustomerItemNumbersExist);}function doHandlerCustomerItemNumbersExist(o){if(o.responseText.substr(0,2)=='ok'){var aryResponse=o.responseText.split(':');if(aryResponse[2]=='true'){doCnTbTsk('enabled','txtBoxPaperSearchYourItem');if(doCnTbTsk('exists','txtBoxPackagingSearchYourItem')){doCnTbTsk('enabled','txtBoxPackagingSearchYourItem');}}else{doCnTbTsk('disabled','txtBoxPaperSearchYourItem');if(doCnTbTsk('exists','txtBoxPackagingSearchYourItem')){doCnTbTsk('disabled','txtBoxPackagingSearchYourItem');}}}}