From bcb3f833e57225e2816a348ecac0b70dad2747a1 Mon Sep 17 00:00:00 2001 From: Behrend Cornelius Date: Wed, 6 Nov 2002 14:23:39 +0000 Subject: #10710# GetFormWizardPaths Routine added --- wizards/source/formwizard/FormWizard.xba | 8 +++----- wizards/source/formwizard/tools.xba | 26 ++++++++++++++++++++++++++ 2 files changed, 29 insertions(+), 5 deletions(-) diff --git a/wizards/source/formwizard/FormWizard.xba b/wizards/source/formwizard/FormWizard.xba index ecd888a770b3..2464769f9c2b 100644 --- a/wizards/source/formwizard/FormWizard.xba +++ b/wizards/source/formwizard/FormWizard.xba @@ -81,11 +81,9 @@ Dim SelList(0) as Integer End If oDBContext = CreateUnoService("com.sun.star.sdb.DatabaseContext") oUcb = createUnoService("com.sun.star.ucb.SimpleFileAccess") - FormPath = GetOfficeSubPath("Template","wizard/bitmap") - WebWizardPath = GetOfficeSubPath("Template","wizard/web") - WizardPath = GetOfficeSubPath("Template","wizard/") - TexturePath = GetOfficeSubPath("Gallery", "www-back/") - WorkPath = GetPathSettings("Work") + If GetFormWizardPaths() = False Then + Exit Sub + End If oDocument.GetCurrentController().Frame.ComponentWindow.Enable = False oProgressBar.Value = 5 GetDatabaseNames() diff --git a/wizards/source/formwizard/tools.xba b/wizards/source/formwizard/tools.xba index 7d457fb4aa79..63af3bff9393 100644 --- a/wizards/source/formwizard/tools.xba +++ b/wizards/source/formwizard/tools.xba @@ -299,4 +299,30 @@ Function GetDBHeight(oDBModel as Object) End If GetDBHeight() = nDBHeight End Function + + +Function GetFormWizardPaths() as Boolean + FormPath = GetOfficeSubPath("Template","wizard/bitmap") + If FormPath <> "" Then + WebWizardPath = GetOfficeSubPath("Template","wizard/web") + If WebWizardPath <> "" Then + WizardPath = GetOfficeSubPath("Template","wizard/") + If Wizardpath <> "" Then + TexturePath = GetOfficeSubPath("Gallery", "www-back/") + If TexturePath <> "" Then + WorkPath = GetPathSettings("Work") + If WorkPath <> "" Then + GetFormWizardPaths = True + Exit Function + End If + End If + End If + End If + End If + If Not IsNull(oDocument) Then + oDocument.dispose() + End If + GetFormWizardPaths() = False +End Function + \ No newline at end of file -- cgit v1.2.3