Domino 9 und frühere Versionen > ND6: Entwicklung

Notesmaske nach Word?

(1/3) > >>

headshrinker:
Hallo Leute,

und zwar soll ich mich als kleiner Praktikant mit folgendem Problem rumschlagen.
Habe mich auch schon umgesehen, aber irgendwie noch nichts geeignetes gefunden.
Wir haben hier ein Reklamationsdatenbank zurzeit noch in Access. Dort werden alle zuständigen Mitarbeiter per Mail mit Worddokument informiert und prüfen dann die Reklamation. Prüfer schicken Prüfbericht dann zurück....

Bei Umstellung der DB auf Notes habe ich folgendes Problem.
Ein Teil der Mitarbeiter hat Notes und ein Teil leider noch nicht (Auslandsstandorte)
User mit Notes tragen Prüfbericht demnächst direkt in die Datenbank.

Wie kriege ich das aber am besten hin, dass ich die Nicht Notes-User informiere. Ich habe mir das bislang so gedacht, das ich die Reklamationmaske (siehe Bild) in ein Worddokument importiere und dieses dann per Mailanhang sende. Oder gibt’s es da noch einfachere bzw. bessere Möglichkeiten.

Ich habe mich mal mit einem Wordscript probiert, welches ich in der Sandbox gefunden (http://www-10.lotus.com/ldd/sandbox.nsf/ByApplicationName/39d365d1d269d5a588256af40051d9bb?OpenDocument ) habe. Aber leider bekomme ich das überhaupt nicht hin, dass er Werte aus meiner Maske übernimmt. Habe zum probieren mal den Namen eines Feldes ausgetauscht, z.B adress gegen Kunde aus meiner Maske, auch die Textmarke umbenannt, aber leider klappt es nicht.

Script

--- Code: ---Here is the code for creating a new  Word document with form fields and updating the form fields with predefined values.

If you are in a UIDcument it is very easy to substitue the predefined values with variables/fields from the UIDocument


Dim s As New notessession
Dim todaydate As New notesdatetime("Today")

Dim word As Variant
Dim wordoc As Variant

Dim todaysdate As String
Dim orderid As String
Dim producedby As String
Dim storeid As String
Dim customername As String
Dim address As String
Dim citytown As String
Dim postcode As String
Dim daytimeno As String
Dim eveningno As String

'Predefined values: (replace with field values from uidoc)
todaysdate = todaydate.localtime
orderid = "2183763248"
producedby = s.username
storeid = "12345"
customername = "John Doe"
address = "Apartment 5c, 5 Test Avenue"
citytown = "Testtown"
postcode = "XX5 5XX"
daytimeno = "1234567890"
eveningno = "0987654321"

'Create the Word object:
Set word = CreateObject("Word.Application") 'Create Word object
Call word.documents.add("Return and Uplift.dot") 'Create a new document based on the template "Return and Uplift.Dot"
Set worddoc = word.activedocument 'Get a handle for the active document

'Assign the field values:
worddoc.FormFields(1).result = todaysdate
worddoc.FormFields(2).result = orderid
worddoc.FormFields(3).result = producedby
worddoc.FormFields(4).result = storeid
worddoc.FormFields(5).result = customername
worddoc.FormFields(6).result = address
worddoc.FormFields(7).result = citytown
worddoc.FormFields(8).result = postcode
worddoc.FormFields(9).result = daytimeno
worddoc.FormFields(10).result = eveningno

worddoc.saveas(customername) 'save the document with the filename of "John Doe.doc"
word.visible = True 'Comment this line if you don't want to show Word.
'word.quit 'remove comment if you want to close rather than show Word.

--- Ende Code ---

Könnt Ihr mir vielleicht ein paar Tipps geben.

koehlerbv:
Auf gut Deutsch: Dein Chef ist zu geizig, um einen Programmierer zu holen, er holt sich lieber einen ahnungslosen Praktikanten. Dem spendiert er nicht mal Ausbildung. Und wir sollen jetzt kostenlos aushelfen ?!

Mach ich nicht mit.

Bernhard

headshrinker:
Bin Student im Praxissemester. Bin froh das man überhaupt so ein "Projekt" bekommen habe. Viele andere Studenten sitzen nur blöd rum im Praxissemester und wissen nicht was sie tun sollen. Außerdem hat man auch schon gesagt, wenn ich Probleme bekomme, den externen Berater für Notes hier im Hause zu kontaktieren, aber der Anreiz besteht ja darin das selber hinzubekommen.

klaussal:
Wenn Du die Leute nur informieren willst, reicht vielleicht schon ein "RendertoRTItem".

m3:

--- Zitat ---aber leider klappt es nicht.
--- Ende Zitat ---
Aussagekräftige Fehlerbeschreibung. Was studierst Du denn? Biologie?

Navigation

[0] Themen-Index

[#] Nächste Seite

Zur normalen Ansicht wechseln