• Location-dependent signature (code included)

    By Sjef Bosman 2 decades ago

    Is it possible to implement a location-dependent signature in the standard template? It requires

    • a form Signature, fields Location and all signature fields on the Calendar Profile form
    • an option 3 in the Calendar Profile form, to indicate that the signature must be fetched from a Signature document
    • a view Signatures, sorted by Location name
    • an extension in the CoreEmailClasses, to handle option 3



      The following code is all that's required:
      If Me.m_nSignatureOption=3 Then  ' added for signature documents<br/>
          Dim location As String<br/>
          Dim doc_tmp As NotesDocument<br/>
          Dim view_tmp As NotesView<br/>
          <br/>
          location= Me.m_session.GetEnvironmentString(&quot;Location&quot;, True)<br/>
          location= Left(location, Instr(location,&quot;,&quot;)-1)<br/>
          Set view_tmp= Me.m_session.CurrentDatabase.GetView(&quot;Signatures&quot;)<br/>
          Set doc_tmp= view_tmp.GetDocumentByKey(location,True)<br/>
          If Not(doc_tmp Is Nothing) Then<br/>
              Me.m_strSignature= doc_tmp.Signature(0)<br/>
              If doc_tmp.SignatureOption(0)=&quot;1&quot; Then<br/>
                  Me.m_nSignatureOption= 1<br/>
              Else<br/>
                  Me.m_nSignatureOption= 2<br/>
              End If      <br/>
          End If<br/>
          <br/>
      End If ' Case 3<br/>
      <br/>
      
      It has to be inserted just above the line
      Select Case Me.m_nSignatureOption<br/>
      
      it should be around line 744.



      I could send you the template with this extension.
    • I would prefer to have this feature,too

      By Kai Bruemmer 2 decades ago

      I would prefer to have this feature, too.

    • Location based signature

      By Bob Greenberg 2 decades ago

      Did you ever create a template that handles this? I'd like to have a look…I have multiple locaitons each with its own email…each should have its own signature…



      Thanks…



      Bob