BookmarkSubscribeRSS Feed
deleted_user
Not applicable
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
8 REPLIES 8
deleted_user
Not applicable
My Lord,

what happend with my post ???? :))))))))))))
David_SAS
SAS Employee
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
Eric_SAS
SAS Employee
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.
deleted_user
Not applicable
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
Tim_SAS
Barite | Level 11
The NOQUOTELENMAX option will suppress the warning message.
deleted_user
Not applicable
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
deleted_user
Not applicable
Thanks.

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

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
  • 8 replies
  • 868 views
  • 0 likes
  • 4 in conversation