home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   alt.msdos.batch.nt      Fun with Windows NT batch files      68,980 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 68,888 of 68,980   
   Zaidy036 to All   
   Missing Operand   
   18 Sep 25 12:35:18   
   
   From: Zaidy036@air.isp.spam   
      
   I fell stupid but for the life of me I cannot see an error but Win 11   
   batch reports missing operand.   
      
   SET T-Hour=%TIME:~0,2%   
   IF %T-Hour% LSS 10 SET T-Hour=%T-Hour:0=%   
   SET T-Min=%TIME:~3,2%   
   IF %T-Min% LSS 10 SET T-Min=%T-Min:0=%   
   SET /A T-Day=%T-Min% + (%T-Hour% * 60)    <<< missing operand ????   
   ECHO %T-Min% + (%T-Hour% * 60)            <<< this shows correctly   
   echo T-Day=%T-Day%                        <<< T-Day is blank   
      
   The purpose of this is to eliminate batch confusing numbers under 10 as   
   non-numeric when calculating minutes after midnight. Will be used as a   
   subroutine.   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca