[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 161
  • Last Modified:

ascii charact coming back from database.

I have the following:
     txtProblem.Text = TicketDS.Tables[0].Rows[0]["ProblemNote"].ToString();
=========================================================
Customer email:
I don't think we have received the summary/detail usage stats & bill for lat month (Feb).  Was this an oversight ?
Did this go out? Can you please re- send to them. Is it possible to make sure that they get the usage report every month. Thanks
======================================================


'

Open in new window

0
mathieu_cupryk
Asked:
mathieu_cupryk
  • 3
  • 2
1 Solution
 
tillgeffkenCommented:
Is this data coming like that from db or are you doing any sort of HtmlEncode or alike with it before displaying?
0
 
nmarunCommented:
Try this:

 txtProblem.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["ProblemNote"].ToString());

Open in new window

0
 
nmarunCommented:
You need to include the System.Web namespace to use the above.
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
mathieu_cuprykAuthor Commented:
if (TicketDS != null && TicketDS.Tables.Count != 0 && TicketDS.Tables[0].Rows.Count > 0)
            {
                txtActionTaken.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["ActionNote"].ToString());
                TicketNumber.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["TicketNumber"].ToString());
                txtClosedBy.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["AgentClosed"].ToString());
                txtCreatedBy.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["AgentCreated"].ToString());
                txtDateAssigned.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["DateAssigned"].ToString());
                txtDateClosed.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["DateClosed"].ToString());
                txtDateCreated.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["DateCreated"].ToString());
                txtDateFollowup.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["FollowupBy"].ToString());
                txtExternalTicket.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["ExternalTicket"].ToString());
                txtFollowupNotes.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["FollowupNote"].ToString());
                txtLastUpdate.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["DateLastModified"].ToString());
                txtProblem.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["ProblemNote"].ToString());
                txtShortDescription.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["ShortDescription"].ToString());
                txtSolution.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["SolutionNote"].ToString());
                txtSubmitVia.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["TicketApplicationType"].ToString());
                txtTrackIt.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["TrackIt"].ToString());
                txtUserID.Text = HttpUtility.HtmlDecode(TicketDS.Tables[0].Rows[0]["UserID"].ToString());
                uxLookupFieldTicketStatus1.DefaultValue = TicketDS.Tables[0].Rows[0]["TicketStatus"].ToString();
                uxLookupFieldTicketAgentFolowup1.DefaultValue = TicketDS.Tables[0].Rows[0]["AgentFollowup"].ToString();
                uxLookupFieldTicketType1.DefaultValue = TicketDS.Tables[0].Rows[0]["TicketType"].ToString();
                uxLookupFieldTicketServiceImpact1.DefaultValue = TicketDS.Tables[0].Rows[0]["ServiceImpact"].ToString();
                uxLookupFieldTicketLocationSIMs1.DefaultValue = TicketDS.Tables[0].Rows[0]["LocationSIMs"].ToString();
                uxLookupFieldTicketRequestType1.DefaultValue = TicketDS.Tables[0].Rows[0]["RequestType"].ToString();
                uxLookupFieldTicketPriority1.DefaultValue = TicketDS.Tables[0].Rows[0]["Priority"].ToString();
                uxLookupFieldTicketContactMethod1.DefaultValue = TicketDS.Tables[0].Rows[0]["ContactMethod"].ToString();
                uxLookupFieldTicketAssignedTo.DefaultValue = TicketDS.Tables[0].Rows[0]["AssignedTo"].ToString();
            }
           

is it ok for each textbox that is being assigned,
0
 
nmarunCommented:
Looks good.. are you still having that issue?
0
 
mathieu_cuprykAuthor Commented:
Thanks.
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now