--- loncom/interface/lonprintout.pm 2014/04/24 15:31:39 1.642 +++ loncom/interface/lonprintout.pm 2014/09/21 16:26:20 1.643 @@ -1,7 +1,7 @@ # The LearningOnline Network # Printout # -# $Id: lonprintout.pm,v 1.642 2014/04/24 15:31:39 raeburn Exp $ +# $Id: lonprintout.pm,v 1.643 2014/09/21 16:26:20 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -3615,6 +3615,7 @@ sub print_resources { my $current_assignment = ""; my $assignment; my $courseidinfo = &get_course(); + my $possprint = scalar(@{$master_seq}); foreach my $curresline (@{$master_seq}) { if (defined $page_breaks{$curresline}) { @@ -3756,7 +3757,24 @@ sub print_resources { # if ($actually_printed == 0) { - $current_output = &encapsulate_minipage("\\vskip -10mm \nNo incomplete resources\n \\vskip 100 mm { }\n"); + my $message = &mt('No resources to print'); + if (!$possprint) { + if ($perm{'pav'} || $perm{'pfo'}) { + $message = &mt('There are no unhidden resources to print.')."\n\n". + &mt('The most likely reason is one of the following: ')."\n". + '\begin{itemize}'."\n". + '\item '.&mt("The 'Resource hidden from students' parameter is set for the folder being printed.")."\n". + '\item '.&mt("'Hidden' is checked in the Course Editor individually for each resource in the folder being printed.")."\n". + '\end{itemize}'."\n\n". + &mt("Note: to print a bubblesheet exam which you want to hide from students, ". + "use the Course Editor to check the 'Hidden' checkbox for the exam folder itself.")."\n"; + } + } elsif ($print_incomplete) { + $message = &mt('No incomplete resources'); + } + if ($message) { + $current_output = &encapsulate_minipage("\\vskip -10mm \n$message\n \\vskip 100 mm { }\n"); + } if ($remove_latex_header eq "NO") { $current_output = &print_latex_header() . $current_output; } else { 500 Internal Server Error

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator at root@localhost to inform them of the time this error occurred, and the actions you performed just before this error.

More information about this error may be available in the server error log.