![]() |
FlowFact - Entwicklungstools |
![]() |
Sub | AD_SetNameAndSalutation(ByVal rsAd As ADODB.Recordset, ByVal strSalutationShort As String, ByVal strTitle As String, ByVal strFirstName As String, ByVal strFamilyName As String) |
rsAD: Recordset der von AD_New oder AD_Find_XXX zurückgegeben wurde. Auch ein 'm_oBase.FF_GetRecordset("SELECT * FROM AD ...")' ist möglich. strSalutationShort: Anredekürzel; z.B. Herr, Frau, Firma, ... oder Leerstring strTitle: Titel strFirstName: Vorname strFamilyName: Nachname Public Sub AD_SetNameAndSalutation(ByVal rsAd As ADODB.Recordset, ByVal strSalutationShort As String, ByVal strTitle As String, ByVal strFirstName As String, ByVal strFamilyName As String) Dim oSalutationList As clsSalutationList Dim idx As Long Dim strSalutationLetter As String Set oSalutationList = STD_GetSalutationList '** Anrede setzen If oSalutationList.Count > 0 Then idx = oSalutationList.FindByShort(strSalutationShort) If idx <= 0 Then idx = 1 End If rsAd("ANREDEKURZ").value = oSalutationList.SalutationShort(idx) rsAd("ANREDE").value = oSalutationList.SalutationLong(idx) strSalutationLetter = oSalutationList.SalutationLetter(idx) strSalutationLetter = oSalutationList.ReplaceSalutationLetterTag(strSalutationLetter, strTitle, strFirstName, strFamilyName) rsAd("BRIEFANREDE").value = strSalutationLetter End If '** Name setzen AD_SetName rsAd, strTitle, strFirstName, strFamilyName End Sub |