LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 74
Default Splash screen not working in hidden workbook

Hi,

i like to use a splash form in a HIDDEN WORKBOOK, but it seems to be
not working.

Problem is that the frmErrorMsg keeps open after the 5 sec. delay, so
there's no Unload event, because the "Close Form" routine isn't
called.

Is there a possibility to get this working in a HIDDEN WORKBOOK (Add-
In)?
Do i have to specify where the Close Form routine can be found?
If so how to do so.

I have following code, works as long as the workbook ISN'T hidden
(IsAddin = False):

Sub StartHere()
'import the common settings into sheet common settings
Dim FullPath As String
Dim Sep As String
Dim SheetName As String
Dim blfileExist As Boolean
Dim blPathExist As Boolean

blnDEBUG = True 'only needed for debugging

strUnitDataLog = strUnit_DataLog & txtFileExtension 'unit
data logging file name

FullPath = ThisWorkbook.path
'test if path exist - server online
'if not found, keep on retrying
blPathExist = FileOrDirExists(FullPath)
While blPathExist = False
strErrorMSG = "Directory " & vbCrLf & _
FullPath & vbCrLf & _
" niet gevonden!" & vbCrLf & vbCrLf & _
"Mogelijk is de server offline of niet verbonden."
frmErrorMsg.cmdOK.Caption = "Retry"
frmErrorMsg.cmdClose.Visible = False
frmErrorMsg.Show
'test again if path exist - server online
blPathExist = FileOrDirExists(FullPath)
Wend
'test if file commonsettings.txt exist, if not show frmCommonSettings
FullPath = ThisWorkbook.path & "\Common Settings" &
txtFileExtension
'test if file exists
'if not show Common Settings form
blPathExist = FileOrDirExists(FullPath)
If blnDEBUG = True Then blPathExist = False
If blPathExist = False Then
strErrorMSG = "Gemeenschappelijk configuratie bestand niet
gevonden. " & vbCrLf & vbCrLf & vbCrLf & "Een ogenblik geduld A.U.B."
& _
vbCrLf & vbCrLf & "Configuratie formulier start binnen 5 sec."
Application.OnTime Now + TimeValue("00:00:05"),
Procedu="CloseForm", Schedule:=True
blnSplash = True
frmErrorMsg.Show
frmCommonSettings.Show
End If
'load common setting file if common settings file exist
'else bail out
If blnErrorTrapped = False Then
Sep = vbTab
SheetName = "Common Settings"
'load common settings
ImportTextFile FullPath, Sep, SheetName
End If
'show main form
frmMainMenu.Show
End Sub

Sub CloseForm()

Unload frmErrorMsg 'remove everything from this form from memory
and close form
End Sub

Any help welcome.
Thanks in advance

Ludo
 
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
Splash Screen Brooke Excel Discussion (Misc queries) 5 March 25th 08 03:58 PM
Splash Screen Bill[_30_] Excel Programming 2 November 3rd 05 05:28 PM
Splash screen Steve Excel Programming 6 August 9th 05 04:53 PM
Splash screen and various screen resolutions George J Excel Programming 4 October 3rd 04 10:15 PM
Splash screen stops Solver add-in working keepITcool Excel Programming 2 July 23rd 04 09:50 AM


All times are GMT +1. The time now is 05:27 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"