summaryrefslogtreecommitdiff
path: root/wizards/source/template
diff options
context:
space:
mode:
authorBehrend Cornelius <bc@openoffice.org>2002-09-02 11:06:12 +0000
committerBehrend Cornelius <bc@openoffice.org>2002-09-02 11:06:12 +0000
commit17b23e68f3e75c9b9bd3b8964e688044f57770f1 (patch)
tree78362b72efdc501ca22458afd70a32ad75afa55a /wizards/source/template
parent2f82ea11dcb4b6596a1e14e0a6db1f1b43cccd65 (diff)
#96775# Errormessage in macro inserted
Diffstat (limited to 'wizards/source/template')
-rw-r--r--wizards/source/template/Correspondence.xba14
-rw-r--r--wizards/source/template/template.src6
2 files changed, 13 insertions, 7 deletions
diff --git a/wizards/source/template/Correspondence.xba b/wizards/source/template/Correspondence.xba
index 0f688cf46ea5..00380f96fd0a 100644
--- a/wizards/source/template/Correspondence.xba
+++ b/wizards/source/template/Correspondence.xba
@@ -63,7 +63,7 @@ Dim oAddressDialog as Object
Dim oAddressPilot as Object
Dim oFields as Object
Dim oDocSettings as Object
-
+ On Local Error Goto GENERALERROR
bDBFields = DialogModel.Optmerge.State &apos;database or placeholder
TemplateDialog.EndExecute()
@@ -93,10 +93,10 @@ Dim oDocSettings as Object
End If
ParaBreak = com.sun.star.text.ControlCharacter.PARAGRAPH_BREAK
- oDocument = ThisComponent
+ oDocument = ThisComponent
If bDBFields Then
&apos;set the address db as current db at the document
- oDocSettings = oDocument.createInstance(&quot;com.sun.star.document.Settings&quot;)
+ oDocSettings = oDocument.createInstance(&quot;com.sun.star.document.Settings&quot;)
oDocSettings.CurrentDatabaseDataSource = sAddressbook
oDocSettings.CurrentDatabaseCommand = Table
oDocSettings.CurrentDatabaseCommandType = 0
@@ -111,7 +111,7 @@ Dim oDocSettings as Object
oFoundall = oDocument.FindAll(oSearchDesc)
&apos;Loop over the foundings
- For i = oFoundAll.Count -1 To 0 Step -1
+ For i = oFoundAll.Count -1 To 0 Step -1
oFound = oFoundAll.GetByIndex(i)
sFoundString = oFound.String
&apos;Extract the string inside the brackets
@@ -149,6 +149,12 @@ Dim oDocSettings as Object
aArgs(3).Value = Table
oDisp.dispatch(aURL, aArgs())
End If
+
+ GENERALERROR:
+ If Err &lt;&gt; 0 Then
+ Resume LETSGO
+ End If
+ LETSGO:
End Sub
diff --git a/wizards/source/template/template.src b/wizards/source/template/template.src
index 104c91f121da..69995b48d7c7 100644
--- a/wizards/source/template/template.src
+++ b/wizards/source/template/template.src
@@ -2,9 +2,9 @@
*
* $RCSfile: template.src,v $
*
- * $Revision: 1.30 $
+ * $Revision: 1.31 $
*
- * last change: $Author: rt $ $Date: 2001-08-24 05:52:40 $
+ * last change: $Author: bc $ $Date: 2002-09-02 12:06:12 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -406,7 +406,7 @@ String CorrespondenceNoTextmark+1
String CorrespondenceMsgError
{
- Text = "Fehler";
+ Text = "Es ist ein Fehler aufgetreten!";
Text[English] = "Error";
Text[ english_us ] = "Error";
Text[ portuguese ] = "Erro";