Question

Generate document from Employee file not working - 23R2

  • 9 February 2024
  • 5 replies
  • 61 views

Badge +6

Hi,

 

I tried to generate document from employee file, but it is not working correctly

Here are basic data:

  1. I generated mail merge template
  1. I created my own Word Template with macro from Help documentation ( see attachment PLATOVY_VYMER.zip)

    Public Sub DoMailMerge(sFile As String)

        ActiveDocument.MailMerge.OpenDataSource Name:=sFile, _         ConfirmConversions:=False, ReadOnly:=False, LinkToSource:=True, _         AddToRecentFiles:=False, PasswordDocument:="", PasswordTemplate:="", _         WritePasswordDocument:="", WritePasswordTemplate:="", Revert:=False, _         Format:=wdOpenFormatAuto, Connection:="", SQLStatement:="", SQLStatement1 _         :=""    With ActiveDocument.MailMerge         .Destination = wdSendToNewDocument         .MailAsAttachment = False         .MailAddressFieldName = ""         .MailSubject = ""         .SuppressBlankLines = True         With .DataSource             .FirstRecord = wdDefaultFirstRecord             .LastRecord = wdDefaultLastRecord         End With         .Execute Pause:=False     End With End Sub 

 

  1. I created my own word template definition. I specified full path to word template on my local PC.

 

  1. In Employee file I click on Generate document, select my template and click on Generate.

 

  1. Word file is open, I click Yes on message

 

but no data are fetched from application.

 

Are there some additional settings or is it a bug?

Thank for help

 

Romana


5 replies

Badge +2

Hello Romana,

exactly the same issue - when Word is opened I get this message:

And when I click on “Ano”, no data filled into mail merge fields:

Regard

Tomas Krejza

Badge +6

Hi Tomáš,

 

RnD admited this situation as a bug and it should be fixed in 23R2 SU4.

I havent had a chance yet to test it, because I dont have access to db with this service update. I let you know then

Romana

Badge +2

Hello, we are on version 23.2.4 and problem is still there. 

Badge +6

Good to know. I am going to report it again.

Thank you 

 

R.

Badge +2

I was thinking about possible issue with select from table performed in Word mail merge - if there can be any security setting which needs to be done/changed. I don´t know. 

Reply