<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Saving character field from C# app to sas with carriage returns in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122968#M33807</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tom,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you that fixed it. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks again to everyone for their help&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 01 Nov 2013 18:03:52 GMT</pubDate>
    <dc:creator>jerry898969</dc:creator>
    <dc:date>2013-11-01T18:03:52Z</dc:date>
    <item>
      <title>Saving character field from C# app to sas with carriage returns</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122959#M33798</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a c# app that has a notes section that allows the users to put some text in there and save it.&amp;nbsp; My issue is that after it is saved and I want to re-display it the carriage return is removed and all the space is removed and everything is stuck together.&amp;nbsp; What is the best way to handle this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a similar situation creating .sas files and adding carriage returns.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help would be appreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Oct 2013 18:35:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122959#M33798</guid>
      <dc:creator>jerry898969</dc:creator>
      <dc:date>2013-10-24T18:35:00Z</dc:date>
    </item>
    <item>
      <title>Re: Saving character field from C# app to sas with carriage returns</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122960#M33799</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This is a pure C# question, right? So this might not be the best place to ask for help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This sounds like a .Net property in your Textbox Control. Which user control do you use? Do you use WinForms or WPF?&lt;/P&gt;&lt;P&gt;Look for some properties like "Mulitline" at your control (e.g. &lt;A href="http://msdn.microsoft.com/en-us/library/vstudio/12w624ff.aspx" title="http://msdn.microsoft.com/en-us/library/vstudio/12w624ff.aspx"&gt;TextBox.Multiline Property (System.Windows.Forms)&lt;/A&gt;)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Oct 2013 07:55:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122960#M33799</guid>
      <dc:creator>AndreasMenrath</dc:creator>
      <dc:date>2013-10-25T07:55:55Z</dc:date>
    </item>
    <item>
      <title>Re: Saving character field from C# app to sas with carriage returns</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122961#M33800</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Andreas,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Within my C# app it displays correctly when typed in.&amp;nbsp; When I send the insert or update sql to sas and then I go back to view the text it's one line with the spaces removed.&amp;nbsp; If I'm saving the text in sas do I have put the carriage returns in when I do the insert or update?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you for your help&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Nov 2013 16:42:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122961#M33800</guid>
      <dc:creator>jerry898969</dc:creator>
      <dc:date>2013-11-01T16:42:12Z</dc:date>
    </item>
    <item>
      <title>Re: Saving character field from C# app to sas with carriage returns</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122962#M33801</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;How are you verifying the carriage return is removed?&amp;nbsp; If you're opening a dataset up in sas (.sas7bdat), it won't display multiline character fields even if they have CRs in them - it will just eat up the space and display as if that character didn't exist.&amp;nbsp; You'd have to look at the hex value of the sting to see if '0D' was in there somewhere.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If that's not the issue (and it doesn't sound like it's the entire issue), then I agree it's probably a C#/.NET issue.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Nov 2013 16:45:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122962#M33801</guid>
      <dc:creator>snoopy369</dc:creator>
      <dc:date>2013-11-01T16:45:33Z</dc:date>
    </item>
    <item>
      <title>Re: Saving character field from C# app to sas with carriage returns</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122963#M33802</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Snoopy,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Thank you for the reply.&amp;nbsp; I see that it is removed when I go into my C# app and open up the form that displays the text.&amp;nbsp; When I initially entered it, it displayed correctly.&amp;nbsp; When I saved and closed the app and then opened it up the carriage returns I added were removed and the text is all together.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Nov 2013 17:00:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122963#M33802</guid>
      <dc:creator>jerry898969</dc:creator>
      <dc:date>2013-11-01T17:00:18Z</dc:date>
    </item>
    <item>
      <title>Re: Saving character field from C# app to sas with carriage returns</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122964#M33803</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;How is this related to SAS?&lt;/P&gt;&lt;P&gt;Is your application storaging text into variables in a SAS dataset?&lt;/P&gt;&lt;P&gt;What actual SAS code are you using to move the data into and out of SAS?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Nov 2013 17:06:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122964#M33803</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2013-11-01T17:06:00Z</dc:date>
    </item>
    <item>
      <title>Re: Saving character field from C# app to sas with carriage returns</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122965#M33804</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tom,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm inserting this text into a variable in a sas dataset.&amp;nbsp; Here is some example code.&lt;/P&gt;&lt;P&gt;proc sql undo_policy = none ; &lt;/P&gt;&lt;P&gt;update tblNotes (cntllev=rec) &lt;/P&gt;&lt;P&gt;set notes='This is a testTHIS IS A TESTtest2TEST3TEST4TEST5TEST6&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TEST7'&lt;/P&gt;&lt;P&gt;where id = 9999; &lt;/P&gt;&lt;P&gt;quit ; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Based on Snoopys suggestion I was able to view the hex after I enter the carriage returns in my multiline textbox.&amp;nbsp;&amp;nbsp; It shows \r\n where my carriage returns are.&amp;nbsp; I'm losing them some how on the way to sas.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Nov 2013 17:09:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122965#M33804</guid>
      <dc:creator>jerry898969</dc:creator>
      <dc:date>2013-11-01T17:09:57Z</dc:date>
    </item>
    <item>
      <title>Re: Saving character field from C# app to sas with carriage returns</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122966#M33805</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you submitted a program like that in a SAS program then the line break would be eliminated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;data _null_;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;notes='12345&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;6789';&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;put notes= / notes= $hex24. ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;run;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;notes=123456789&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;notes=313233343536373839&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But if you put in the hexcodes using literals they will make it in.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;data _null_;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;notes='12345' || '0d0a'x || '6789';&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;put notes= / notes= $hex24. ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;run;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;notes=12345&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em; font-family: 'courier new', courier;"&gt;6789&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;notes=31323334350D0A36373839&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So in whatever C logic you have to generate the string generate it like the example above instead.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;...&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;set notes='This is a testTHIS IS A TESTtest2TEST3TEST4TEST5TEST6'&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; || '0D0A'x&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; || '&lt;/SPAN&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;TEST7' &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;...&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Nov 2013 17:20:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122966#M33805</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2013-11-01T17:20:23Z</dc:date>
    </item>
    <item>
      <title>Re: Saving character field from C# app to sas with carriage returns</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122967#M33806</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tom,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Thank you for the information.&amp;nbsp; I'm working on it now and will post my results when I finish.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Nov 2013 17:33:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122967#M33806</guid>
      <dc:creator>jerry898969</dc:creator>
      <dc:date>2013-11-01T17:33:53Z</dc:date>
    </item>
    <item>
      <title>Re: Saving character field from C# app to sas with carriage returns</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122968#M33807</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tom,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you that fixed it. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks again to everyone for their help&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Nov 2013 18:03:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122968#M33807</guid>
      <dc:creator>jerry898969</dc:creator>
      <dc:date>2013-11-01T18:03:52Z</dc:date>
    </item>
    <item>
      <title>Re: Saving character field from C# app to sas with carriage returns</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122969#M33808</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tom,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sorry to bother you but how would I handle this with an insert statement?&amp;nbsp; When I try this I get an error for the "||".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;proc sql undo_policy = none ; &lt;/P&gt;&lt;P&gt;Insert into tblnotes (cntllev=rec, id, notes)&lt;/P&gt;&lt;P&gt;values(999, 'THIS' || '0d0a'x || 'IS' || '0d0a'x || 'A' || '0d0a'x || 'TEST' || '0d0a'x || 'OF THIS CODE&amp;nbsp;&amp;nbsp; ' || '0d0a'x || 'TESTING')&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;quit ; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for the help&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Nov 2013 18:11:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122969#M33808</guid>
      <dc:creator>jerry898969</dc:creator>
      <dc:date>2013-11-01T18:11:29Z</dc:date>
    </item>
    <item>
      <title>Re: Saving character field from C# app to sas with carriage returns</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122970#M33809</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That type of transactional processing is not something I normally attempt to do with SAS.&amp;nbsp; Why not just insert a blank value and then use the update syntax to put the value into the NOTE variable?&amp;nbsp; Or you could also just have C write the whole string as hex digits?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;values(999,'544849530D0A49530D0A410D0A544553540D0A4F46205448495320434F44452020200D0A54455354494E47'x)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Nov 2013 18:33:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Saving-character-field-from-C-app-to-sas-with-carriage-returns/m-p/122970#M33809</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2013-11-01T18:33:47Z</dc:date>
    </item>
  </channel>
</rss>

