# listings frame for multiple page code [closed]

My code is really long. And I really want to use the frame Shadowbox in my code. But the problem is since it is going over a single page, the box is actually completing at the end of the code ....which makes the box look ugly...Is there any way, I can use Shadowbox but at the end of every page it will show a complete box (rather then incomplete portion until the end) This is my lstset

\lstset{ %
rulesepcolor=\color{black},
backgroundcolor=\color{white},
basicstyle=\footnotesize\ttfamily,
breaklines=true,
captionpos=b,
escapeinside={\%*}{*)},
keywordstyle=\color{blue},
stringstyle=\color{red},
numberstyle=\tiny,
numbersep=5pt,
tabsize=2,
extendedchars=true,
showspaces=false,
showtabs=false,
xleftmargin=17pt,
framexleftmargin=17pt,
framexrightmargin=5pt,
framexbottommargin=2pt,
showstringspaces=false,


}

-

## closed as off-topic by Jubobs, Peter Jansson, Claudio Fiandrino, egreg, WernerFeb 28 '14 at 17:34

• This question does not fall within the scope of TeX, LaTeX or related typesetting systems as defined in the help center.
If this question can be reworded to fit the rules in the help center, please edit the question.

Welcome to TeX.SX! Please make your code compilable (if possible), or at least complete it with \documentclass{...}, the required \usepackage's, \begin{document}, and \end{document}. That may seem tedious to you, but think of the extra work it represents for TeX.SX users willing to give you a hand. Help them help you: remove that one hurdle between you and a solution to your problem. –  Jubobs Feb 27 '14 at 11:07
This is not an answer to your question, just a comment: are you sure you want a complete frame around only part of a listing? That may lead your readers to believe that what's in that frame is the complete listing, especially if they're reading your document on a screen and can't see that the listing is continued on the next page. –  Jubobs Feb 27 '14 at 11:15
Voters, note that this is not possible with listings alone, but Harish Kumar has a solution involving tcolorbox also. Let's reopen this question so he can answer it, or so it can be closed as a "dupe" as opposed to "off-topic". –  Jubobs Apr 11 '14 at 7:10