Loading

Open

Skip Feed
  1. Multi-language email notifications
    Hi all, I don't have a question but thought I could share some ideas here. It looks like most members of the community are happy with email notifications in english only. Unfortunately, one of our customers has a legal requirement to offer as well the user interface as the communication in English and French. My approach is to add a parameter to the workflow that represents the selected UI language in AP. In addition, I will duplicate the "email notification" activity to define a MailBody in English and a second one in French. Using a run condition for these activites checking the newly created parameter should solve the requirement. Just as a point to start from I added this powershell webservice to my environment and it seems to work well.   Of course, there will be more efficient ways to solve this :-) Hope this helps :-) Axel --- AP powershell webservice --- function AP_language { param( $Username ) #Open Database connection to AP database $connection = New-Object System.Data.SqlClient.SqlConnection   $connection.ConnectionString = "Server=SnowAutomationPlatformSQLServer;        Database=SnowAutomationPlatformDomain;Trusted_Connection=True;"   $connection.Open()       # Build Command string to read UserID from database   $command = New-Object System.Data.SQLClient.SQLCommand   $command.Connection = $connection   $command.CommandText = "SELECT Id FROM dbo.Users where UserId = '$Username';" # read UserID from database   $UserID = $command.ExecuteScalar() # Build next command string to read CurrentCulture for selected User   $command = New-Object System.Data.SQLClient.SQLCommand   $command.Connection = $connection   $command.CommandText = "SELECT [value] FROM dbo.UserSettings where UserId = '$UserID' AND [Key] = 'CurrentCulture';" # Read CurrentCulture from database   $UserLang = $command.ExecuteScalar() # value from db looks like {"value":"de"} - get language code   if ($Userlang.contains("de")) { # German language selected       $result = "de"   }   Elseif ($Userlang.contains("fr")) { # French language selected       $result = "fr"   }   Else { # all other language selections       $result = "en"   } $Connection.Close() # close database connection $result } #End function
    Expand Post
    Question with a best answer.

    Best Answer

    Hi Axel,

     

    I believe this is a post from the previous system and is more of a "post" than a "question" in this version of Snow Globe, and therefor i'm adding an answer here to mark it as completed just to get it filtered out as completed :)

     

    Perhaps you have a updated solution for this to share?

     

    Also, I believe there are no real tools within AP for this. If you have a suggestion of something that would work well for this, please add it to the ideas board! :)

     

    Thank you!

     

    //Oskar

     

     

    Expand Post
    Oskar Frolin by Oskar Frolin (Flexera Software)

    • Oskar Frolin (Flexera Software)

      Hi Axel,

       

      I believe this is a post from the previous system and is more of a "post" than a "question" in this version of Snow Globe, and therefor i'm adding an answer here to mark it as completed just to get it filtered out as completed :)

       

      Perhaps you have a updated solution for this to share?

       

      Also, I believe there are no real tools within AP for this. If you have a suggestion of something that would work well for this, please add it to the ideas board! :)

       

      Thank you!

       

      //Oskar

       

       

      Expand Post
      Selected as Best

End of Feed
1 Chatter Feed Items
ALL CONVERSATIONS
UNSOLVED
ARTICLES
1 Post

Related Topics

    Loading
    Open | Flexera