The SAS Output Delivery System and reporting techniques

Posthtml

Reply
N/A
Posts: 0

Posthtml

Hello SAS programmers.

I am trying to do (using ODS) very simple HTML site. I wrote a code like this:


/*
Data Fakedata;
Length fakevar $ 1;
Label fakevar = '00'X;
Fakevar = ' ';
Run;

Proc Template;
DEFINE STYLE Fish_Style;
STYLE Body / backgroundimage ="C:\Temp\Fishing_Club\Files\Tlo_1.gif" watermark=ON;
STYLE SysTitleAndFooterContainer / background = _undef_;
STYLE Systemtitle / background = _undef_;
STYLE SystemFooter FROM TitlesAndFooters "Controls system footer text." /
PROTECTSPECIALCHARS = OFF
background = _undef_;
END;
Run;


ODS HTML BODY="C:\Temp\Fishing_Club\Fish1.html" Style=Fish_Style;

TITLE1 " ";
TITLE2 COLOR="#FFEB8C" JUSTIFY=CENTER HEIGHT=6 FONT="Castellar" "Fishing Club";

FOOTNOTE1 "
















";
FOOTNOTE2 JUSTIFY=CENTER '^S={preimage="C:\Temp\Fishing_Club\Files\Linia.GIF"}';

Proc Print Data=Fakedata noobs label;
Var Fakevar / style(data) = [just=right
posthtml =
"


height=125 width=100 alt='Boleń ok. 50 cm' >




height=100 width=125 alt='Boleń ok. 50 cm' >




height=100 width=125 alt='Boleń ok. 50 cm' >


"];
Run;

ODS HTML CLOSE;
*/


Unfortunately I have WARNIG:

"WARNING: The quoted string currently being processed has become more than 512 characters long. You may have unbalanced quotation marks"

and I don't now what correct this.

When I put more photos everything every photos are erased from the site.


Any ideas how to correct this bug ???

Regards & thx
N/A
Posts: 0

Re: Posthtml

Posted in reply to deleted_user
My Lord,

what happend with my post ???? Smiley Happy)))))))))))
SAS Employee
Posts: 174

Re: Posthtml

Posted in reply to deleted_user
You can post SAS code as preformatted text by enlosing it in "pre" and "\pre" directives. The directives must be enclosed in square brackets. I don't know how to show you the syntax, because the forum software naturally wants to interpret it.

As an example, here is unpreformatted code:

/*-- This is unpreformatted and uses a proportional font. --*/

proc tabulate data=sashelp.class;
class sex age;
var height;
table sex,age*height*(mean median);
run;

Here is the preformatted version:
[pre]
/*-- This is preformatted and uses a monospace font. --*/

proc tabulate data=sashelp.class;
class sex age;
var height;
table sex,age*height*(mean median);
run;
[/pre]

-- David Kelley, SAS
N/A
Posts: 0

Re: Posthtml

Posted in reply to David_SAS
SAS Employee
Posts: 95

Re: Posthtml

Posted in reply to deleted_user
Those lines are getting rather long. What are you trying to do? Put 3 images and links after every data element in the table?

If it is really that long, you could put it in the tagset and cause it to be put in based on a simpler style attribute value.
N/A
Posts: 0

Re: Posthtml

I want put there 50 small images with links to big size images.
Site working correct, but I have still this WARNING about too long quoted string.

Can you put any example to your solution ?

Thx
Super Contributor
Posts: 394

Re: Posthtml

Posted in reply to deleted_user
The NOQUOTELENMAX option will suppress the warning message.
N/A
Posts: 0

Re: Posthtml

I recognise that I am conservative in most things, and that my degree of conservatism sets me apart a little as a sign of both age and culture, but I tend to ask "why" before I ask "how".

So although I agree with Tim's answer, and would have offered the same response had he not been in a better time zone to respond, I would have offered it with a caveat.

Tim has told you the "how", but my concern is that applying such a setting globally may suppress other instances where you really should know that the string is overly long. The length limitation is potentially irksome, but I have found it useful on occasions where I have not constructed strings correctly.

So I take the view that two options statements are required, one before the step that is known to give a warning which is irrelevant, and one after that step to restore the length check.

Kid regards

David
N/A
Posts: 0

Re: Posthtml

Posted in reply to deleted_user
Thanks.
Ask a Question
Discussion stats
  • 8 replies
  • 169 views
  • 0 likes
  • 4 in conversation