Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default macro from General to This Workbook

This is the whole code, I want to save D:\Documents an
Settings\Rune\My Documents\My Webs\myweb\public_html\Resultatliste.htm
as a web document every 5 minutes. I have to made a macro that is onl
for the spesific workbook. (Macro in This Workbook)


Public Declare Function SetTimer Lib "user32" ( _
ByVal HWnd As Long, ByVal nIDEvent As Long, _
ByVal uElapse As Long, ByVal lpTimerFunc As Long) As Long
Public Declare Function KillTimer Lib "user32" ( _
ByVal HWnd As Long, ByVal nIDEvent As Long) As Long

Public TimerID As Long
Public TimerSeconds As Single

Sub StartTimer()
TimerSeconds = 60 ' how often to "pop" the timer.
TimerID = SetTimer(0&, 0&, TimerSeconds * 1000&, AddressO
TimerProc)
End Sub

Sub TimerProc(ByVal HWnd As Long, ByVal uMsg As Long, _
ByVal nIDEvent As Long, ByVal dwTimer As Long)
Application.DisplayAlerts = False
ActiveWorkbook.SaveAs Filename:= _
"D:\Documents and Settings\Rune\My Documents\M
Webs\myweb\public_html\Resultatliste.htm" _
, FileFormat:=xlHtml, ReadOnlyRecommended:=False
CreateBackup:=False
'
' The procedure is called by Windows. Put your
' timer-related code here.
'
End Sub

best regards
Run

--
Message posted from http://www.ExcelForum.com

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
all General formats of the workbook changed to date format suddenl Miri Excel Discussion (Misc queries) 1 May 26th 08 09:24 PM
all the general formats of the workbook suddenly changed to date. Miri Excel Discussion (Misc queries) 2 May 25th 08 12:23 PM
general macro question ynissel Excel Discussion (Misc queries) 17 February 24th 06 03:15 PM
No password protect workbook box in Tools>Options>General MS Excel Discussion (Misc queries) 2 July 16th 05 06:34 AM
adopting a macro to a general situation. Martyn Excel Programming 4 May 25th 04 06:05 PM


All times are GMT +1. The time now is 11:49 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"