Yoko

All sides of Injection
It is currently 2026-01-19 06:46:07

All times are UTC+02:00




Post new topic  Reply to topic  [ 3 posts ] 
Author Message
 Post subject: print hour
PostPosted: 2008-05-22 14:04:35 
Offline

Joined: 2005-04-13 16:01:09
Posts: 48
need a macro that prints date and hour plz :D
Got one, but dont work :(

_________________
Image


Top
   
 Post subject: Re: print hour
PostPosted: 2008-05-22 20:03:49 
Offline
Expert!
User avatar

Joined: 2006-02-07 08:51:40
Posts: 1348
Location: г. Старый Оскол
motxu wrote:
need a macro that prints date and hour plz :D
Got one, but dont work :(


This is script.
Code:
Sub MakeTime()
   VAR D, T, Ret, i
   Ret = STR(UO.Time())
   T = ""
   For i = 0 To Len(Ret)
      T = Ret[Len(Ret)-i] + T
      If (I == 2) OR (I == 4) Then
         T = ":" + T
      EndIf
   Next
   Ret = STR(UO.Date())
   D = ""
   For i = 0 To Len(Ret)
      D = Ret[Len(Ret)-i] + D
      If (I == 2) OR (I == 4) Then
         D = "." + D
      EndIf
   Next
   Ret = T + " @ " + D
   RETURN Ret
end sub


And this is some example:
Code:
var test()
VAR Time
Time = MakeTime()
UO.Print(Time)
end sub


I hope you understand. Just one thing, all scripts must be in same script file.


Top
   
 Post subject:
PostPosted: 2008-05-22 23:06:54 
Offline

Joined: 2005-04-13 16:01:09
Posts: 48
thanks bro :D


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 3 posts ] 

All times are UTC+02:00


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Limited