summaryrefslogtreecommitdiff
path: root/wizards/source/tools/Misc.xba
diff options
context:
space:
mode:
authorBehrend Cornelius <bc@openoffice.org>2001-10-01 09:16:06 +0000
committerBehrend Cornelius <bc@openoffice.org>2001-10-01 09:16:06 +0000
commit0067e33ee9e2d5136958a118eee1ce212ff8ce7d (patch)
tree36627c3b5a16c049654fdd4a9d4626059a804c47 /wizards/source/tools/Misc.xba
parentfce21e37ff27f6aede2e09da20d5f18fd03f26a2 (diff)
#92590# Routines for Gimmicks macros added
Diffstat (limited to 'wizards/source/tools/Misc.xba')
-rw-r--r--wizards/source/tools/Misc.xba14
1 files changed, 11 insertions, 3 deletions
diff --git a/wizards/source/tools/Misc.xba b/wizards/source/tools/Misc.xba
index cfc9684c65ed..b9e4848c2bf4 100644
--- a/wizards/source/tools/Misc.xba
+++ b/wizards/source/tools/Misc.xba
@@ -89,13 +89,21 @@ Dim oMasterKey
End Function
-Function GetRegistryKeyContent(sKeyName as string)
+Function GetRegistryKeyContent(sKeyName as string, Optional bforUpdate as Boolean)
Dim oConfigProvider as Object
Dim aNodePath(0) as new com.sun.star.beans.PropertyValue
oConfigProvider = createUnoService(&quot;com.sun.star.configuration.ConfigurationProvider&quot;)
aNodePath(0).Name = &quot;nodepath&quot;
aNodePath(0).Value = sKeyName
- GetRegistryKeyContent = oConfigProvider.createInstanceWithArguments(&quot;com.sun.star.configuration.ConfigurationAccess&quot;, aNodePath())
+ If IsMissing(bForUpdate) Then
+ GetRegistryKeyContent() = oConfigProvider.createInstanceWithArguments(&quot;com.sun.star.configuration.ConfigurationAccess&quot;, aNodePath())
+ Else
+ If bForUpdate Then
+ GetRegistryKeyContent() = oConfigProvider.createInstanceWithArguments(&quot;com.sun.star.configuration.ConfigurationUpdateAccess&quot;, aNodePath())
+ Else
+ GetRegistryKeyContent() = oConfigProvider.createInstanceWithArguments(&quot;com.sun.star.configuration.ConfigurationAccess&quot;, aNodePath())
+ End If
+ End If
End Function
@@ -406,6 +414,7 @@ Sub Main
Next i
End Sub
+
Function GetDocumentType(oDocument)
If oDocument.SupportsService(&quot;com.sun.star.sheet.SpreadsheetDocument&quot;) Then
GetDocumentType() = &quot;scalc&quot;
@@ -419,7 +428,6 @@ Function GetDocumentType(oDocument)
End Function
-
Function GetNumberFormatType(oDocFormats, oFormatObject as Object) as Integer
Dim ThisFormatKey as Long
Dim oObjectFormat as Object