Execute command AtEndDocument in a custom class











up vote
0
down vote

favorite












I am studying Count number of figures, tables and citations in report class. I am writing a custom class that would have this implementation built in. I would like to move the commands AtEndDocument from the preamble to the .cls file. The problem is that they do not get executed in case of a simple copy.
Can you help?










share|improve this question


















  • 2




    It would be helpful if you composed a fully compilable MWE including documentclass and the appropriate packages that reproduces the problem. While solving problems can be fun, setting them up is not. Then, those trying to help can simply cut and paste your MWE and get started on solving the problem.
    – Peter Grill
    5 hours ago






  • 1




    Mhhh, AtEndDocument should just work in a .cls file. It certainly worked for me in a short example I just wrote. It would be much easier to answer this question if you could show us an example document and an example .cls file of what you tried, what you expected and how it failed for you.
    – moewe
    5 hours ago










  • @moewe, could it be that I provided AtEndDocument after endinput?
    – Viesturs
    4 hours ago






  • 2




    Well yes, that would definitely be a problem. Everything after endinput is ignored.
    – moewe
    4 hours ago










  • that is why questions should always have example code, the cause of the problem isn't mentioned in the question. tex does not read the text at all on any lines after endinput
    – David Carlisle
    2 hours ago















up vote
0
down vote

favorite












I am studying Count number of figures, tables and citations in report class. I am writing a custom class that would have this implementation built in. I would like to move the commands AtEndDocument from the preamble to the .cls file. The problem is that they do not get executed in case of a simple copy.
Can you help?










share|improve this question


















  • 2




    It would be helpful if you composed a fully compilable MWE including documentclass and the appropriate packages that reproduces the problem. While solving problems can be fun, setting them up is not. Then, those trying to help can simply cut and paste your MWE and get started on solving the problem.
    – Peter Grill
    5 hours ago






  • 1




    Mhhh, AtEndDocument should just work in a .cls file. It certainly worked for me in a short example I just wrote. It would be much easier to answer this question if you could show us an example document and an example .cls file of what you tried, what you expected and how it failed for you.
    – moewe
    5 hours ago










  • @moewe, could it be that I provided AtEndDocument after endinput?
    – Viesturs
    4 hours ago






  • 2




    Well yes, that would definitely be a problem. Everything after endinput is ignored.
    – moewe
    4 hours ago










  • that is why questions should always have example code, the cause of the problem isn't mentioned in the question. tex does not read the text at all on any lines after endinput
    – David Carlisle
    2 hours ago













up vote
0
down vote

favorite









up vote
0
down vote

favorite











I am studying Count number of figures, tables and citations in report class. I am writing a custom class that would have this implementation built in. I would like to move the commands AtEndDocument from the preamble to the .cls file. The problem is that they do not get executed in case of a simple copy.
Can you help?










share|improve this question













I am studying Count number of figures, tables and citations in report class. I am writing a custom class that would have this implementation built in. I would like to move the commands AtEndDocument from the preamble to the .cls file. The problem is that they do not get executed in case of a simple copy.
Can you help?







document-classes






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked 5 hours ago









Viesturs

1,4592922




1,4592922








  • 2




    It would be helpful if you composed a fully compilable MWE including documentclass and the appropriate packages that reproduces the problem. While solving problems can be fun, setting them up is not. Then, those trying to help can simply cut and paste your MWE and get started on solving the problem.
    – Peter Grill
    5 hours ago






  • 1




    Mhhh, AtEndDocument should just work in a .cls file. It certainly worked for me in a short example I just wrote. It would be much easier to answer this question if you could show us an example document and an example .cls file of what you tried, what you expected and how it failed for you.
    – moewe
    5 hours ago










  • @moewe, could it be that I provided AtEndDocument after endinput?
    – Viesturs
    4 hours ago






  • 2




    Well yes, that would definitely be a problem. Everything after endinput is ignored.
    – moewe
    4 hours ago










  • that is why questions should always have example code, the cause of the problem isn't mentioned in the question. tex does not read the text at all on any lines after endinput
    – David Carlisle
    2 hours ago














  • 2




    It would be helpful if you composed a fully compilable MWE including documentclass and the appropriate packages that reproduces the problem. While solving problems can be fun, setting them up is not. Then, those trying to help can simply cut and paste your MWE and get started on solving the problem.
    – Peter Grill
    5 hours ago






  • 1




    Mhhh, AtEndDocument should just work in a .cls file. It certainly worked for me in a short example I just wrote. It would be much easier to answer this question if you could show us an example document and an example .cls file of what you tried, what you expected and how it failed for you.
    – moewe
    5 hours ago










  • @moewe, could it be that I provided AtEndDocument after endinput?
    – Viesturs
    4 hours ago






  • 2




    Well yes, that would definitely be a problem. Everything after endinput is ignored.
    – moewe
    4 hours ago










  • that is why questions should always have example code, the cause of the problem isn't mentioned in the question. tex does not read the text at all on any lines after endinput
    – David Carlisle
    2 hours ago








2




2




It would be helpful if you composed a fully compilable MWE including documentclass and the appropriate packages that reproduces the problem. While solving problems can be fun, setting them up is not. Then, those trying to help can simply cut and paste your MWE and get started on solving the problem.
– Peter Grill
5 hours ago




It would be helpful if you composed a fully compilable MWE including documentclass and the appropriate packages that reproduces the problem. While solving problems can be fun, setting them up is not. Then, those trying to help can simply cut and paste your MWE and get started on solving the problem.
– Peter Grill
5 hours ago




1




1




Mhhh, AtEndDocument should just work in a .cls file. It certainly worked for me in a short example I just wrote. It would be much easier to answer this question if you could show us an example document and an example .cls file of what you tried, what you expected and how it failed for you.
– moewe
5 hours ago




Mhhh, AtEndDocument should just work in a .cls file. It certainly worked for me in a short example I just wrote. It would be much easier to answer this question if you could show us an example document and an example .cls file of what you tried, what you expected and how it failed for you.
– moewe
5 hours ago












@moewe, could it be that I provided AtEndDocument after endinput?
– Viesturs
4 hours ago




@moewe, could it be that I provided AtEndDocument after endinput?
– Viesturs
4 hours ago




2




2




Well yes, that would definitely be a problem. Everything after endinput is ignored.
– moewe
4 hours ago




Well yes, that would definitely be a problem. Everything after endinput is ignored.
– moewe
4 hours ago












that is why questions should always have example code, the cause of the problem isn't mentioned in the question. tex does not read the text at all on any lines after endinput
– David Carlisle
2 hours ago




that is why questions should always have example code, the cause of the problem isn't mentioned in the question. tex does not read the text at all on any lines after endinput
– David Carlisle
2 hours ago















active

oldest

votes











Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "85"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














 

draft saved


draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f461342%2fexecute-command-atenddocument-in-a-custom-class%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown






























active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes
















 

draft saved


draft discarded



















































 


draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f461342%2fexecute-command-atenddocument-in-a-custom-class%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Lallio

Futebolista

Jornalista