locked
Email not showing in outlook as it looks in browser generated using C# RRS feed

  • Question

  • User1022158690 posted

    I've problem while generating email using C#. It display in browser as expected but in outlook its not showing well. Following is set of source code that I am being using. Also, here  I've the layout of email in browser and outlook. I would like to seek your advise how to make it same in outlook and browser.

     static string getAddressParts(IOrganizationService service, string pAddressID,string fullAddress) {
    
                int temp = fullAddress.Length;
    
                fullAddress += "<u>Subdivision:</u><br/>";
    
                ColumnSet cols = new ColumnSet("new_county", "new_district", "new_section", "new_block", "new_lot", "new_sheet");
                Entity addresses = service.Retrieve("new_propertyaddress", new Guid(pAddressID), cols);
                if (addresses.Attributes.Contains("new_county") && addresses.Attributes["new_county"].ToString() != null)
                    fullAddress += "County: " + "<b>" + addresses.FormattedValues["new_county"].ToString() + "</b><br/>";
                if (addresses.Attributes.Contains("new_district") && addresses.Attributes["new_district"].ToString() != null)
                    fullAddress += "District: " + "<b>" + addresses.Attributes["new_district"].ToString() + "</b>";
                if (addresses.Attributes.Contains("new_section") && addresses.Attributes["new_section"].ToString() != null)
                    fullAddress += "<span style=\"margin-left:10px;\">Section: <b>" + addresses.Attributes["new_section"].ToString() + "</b></span>";
    
    return fullAddress;
    }

    Tuesday, August 1, 2017 1:14 PM

All replies