BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
GreggB
Pyrite | Level 9

I am unable to paste a program directly to this space.  I have to copy it and paste it to Notepad and then copy from Notepad to here.  Any suggestions?

1 ACCEPTED SOLUTION

Accepted Solutions
art297
Opal | Level 21

One alternative is to use Google Chrome.  It seems to have a friendlier relationship with the software that drives the site.

View solution in original post

15 REPLIES 15
Linlin
Lapis Lazuli | Level 10

I have same problem. it is caused by using Internet Explorer.

GreggB
Pyrite | Level 9

are you using IE9?

art297
Opal | Level 21

One alternative is to use Google Chrome.  It seems to have a friendlier relationship with the software that drives the site.

GreggB
Pyrite | Level 9

Ok, I'll try that.

Linlin
Lapis Lazuli | Level 10

I use IE8 at office. I don't have any problem using Google Chrome on my laptop.

Rick_SAS
SAS Super FREQ

I use IE9 and also have the problem.  I am envious of those who paste in beautiful color-coded text. As @GreggB says, one workaround it to paste from the SAS editor into some other program (eg, Notepad), and then copy/paste from there. (Incidentally, it's not just the Enhanced Editor: pasting from EG 4.3 into IE9 has the same problem.)

Linlin
Lapis Lazuli | Level 10

Hi Rick,

You can have color-coded text by using Microsoft Word.

art297
Opal | Level 21

Rick,

Even with Chrome, a temporary diversion to Word I think is necessary to keep all of the colors.

I've never tested it, but here are three copies, using three different methods.  First, a straight copy/paste, then a copy/paste via notepad, and finally a copy/paste via Word .. all via Google Chrome:

/*A REALLY useful program*/ <-Straight

proc freq data=sashelp.class;

  tables sex;

run;

/*A REALLY useful program*/ <- via Notepad

proc freq data=sashelp.class;

  tables sex;

run;

/*A REALLY useful program*/ <-via Word

proc freq data=sashelp.class;

  tables sex;

run;

Rick_SAS
SAS Super FREQ

Ooooh! Ahhhhh! Thanks for the tip!

GreggB
Pyrite | Level 9

ta-DOW!!  Thanks.

data _null_;

set Orion.Employee_Addresses;

where Employee_ID=&idnum;

call symputx('Name',Employee_Name);

run;

Ksharp
Super User

If you are using FireFox.

Firstly, copy and paste your color code from sas editor to MS word.

Secondly, save this word file as html file (you can find this function in menu).

Thirdly, use firefox browser to open this html file.

Fourthly,drag mouse and select these color code ,righ-click and select partial source code

              copy these source code .

At SAS Forum , click html button at top right corner. input

<pre>

</pre>

and paste (or Ctrl +v ) these source code between <pre> </pre>

data have;

infile datalines dlm='(), ';

input height weight @@;

datalines;

(1893, 5552) (12909, 177) (3710, 12959) (4131, 7051) (919, 245) (11896, 2634) (14775, 13426) (7238, 7331) (5698, 9658) (11563, 8170) (11412, 12432) (12478, 1220) (751, 2705) (14923, 11908) (137, 11601) (6680, 967) (3601, 2186) (4393, 1611) (3214, 7605) (4419, 5225) (623, 7010) (10992, 4439) (592, 2747) (6167, 816) (467, 441) (13938, 11090) (6434, 1569) (3603, 10640) (6648, 7398) (1473, 12780) (883, 8220) (9570, 13668) (14088, 8289) (5097, 5337) (1210, 11379) (12805, 4341) (5681, 8336) (4791, 5611) (14100, 14378) (12325, 1739) (7353, 10406) (3542, 3372) (1879, 631) (2777, 938) (9121, 5168) (9732, 12320) (9068, 12061) (13727, 14728) (13286, 8982) (10617, 10916) (1052, 8412) (9801, 5497) (1851, 6658) (13203, 2218) (10293, 1500) (10316, 13825) (6743, 12878) (24, 10473) (2782, 10297) (11100, 4373) (8130, 6739) (829, 3954) (12545, 8303) (11187, 437) (1314, 8035) (11544, 4167) (6588, 1374) (10048, 3186) (12841, 8319) (6685, 10230) (194, 8966) (5787, 564) (10012, 5619) (2266, 419) (13976, 13323) (2245, 674) (8466, 2712) (12388, 2991) (4859, 9097) (3194, 14302) (3470, 10962) (1861, 3060) (7234, 11975) (1467, 8544) (3830, 10832) (11515, 11138) (375, 11550) (1977, 12041) (7102, 10436) (1369, 10631)

;

run;

data _null_;

if _n_ eq1 then do;

if 0 then set have;

declare hash ha(dataset:'have');

declare hiter hi('ha');

ha.definekey('height','weight');

ha.definedata('height','weight');

ha.definedone();

length obs _height _weight person _person __height __weight 8;

declare hash h(ordered:'Y');

declare hiter i('h');

h.definekey('obs');

h.definedata('_height','_weight','_person');

h.definedone();

end;

set have end=last;  retainmax 0;

obs=1; _person=1; _height=height; _weight=weight; h.add();

do while(i.next()=0);

max=max(max,_person); person=_person;__height=_height;__weight=_weight;

do while(hi.next()=0);

  if _height lt height and _weight lt weight then do;

     obs+1;_person+1;_height=height;_weight=weight;

     h.add();_person=person;_height=__height;_weight=__weight;

        end;

end;

end;

h.clear();

if last then putlog 'The largest possible number is : ' max  ;

run;

You will get color code.

Ksharp

art297
Opal | Level 21

KSharp, Correction: you get an HTML file that most either can't or won't bother to decipher!

Ksharp
Super User

Wow. So fast! I don't complete my post yet!

Ksharp
Super User

Art is right. Ctrl + c Ctrl + v from WORD to SAS Forum and keep code colour.

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 15 replies
  • 1430 views
  • 1 like
  • 6 in conversation