GeneralEnable and Diable contents

LaTeX specific issues not fitting into one of the other forums of this category.
Post Reply
Umaraman
Posts: 1
Joined: Mon Apr 08, 2013 2:37 pm

Enable and Diable contents

Post by Umaraman »

Hi,
I would like to enable and disable contents inside \chapter \section commands depends on the command line arguments.
for example

Code: Select all

\chapter <chapterName1> [arg1==true][arg2==false]
\chapter <chapterName2> [arg1==true][arg2==true][arg3==false]
\section <sectionName1> [arg1==true][arg3==true]
If I pass arg1 and arg3 as True then My output should contain
chapterName1
sectionName1

How can I do this?
Thanks in advance.

Umaraman
Last edited by cgnieder on Mon Apr 08, 2013 7:03 pm, edited 1 time in total.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

cgnieder
Site Moderator
Posts: 2000
Joined: Sat Apr 16, 2011 7:27 pm

Enable and Diable contents

Post by cgnieder »

Hi Umaraman,

Welcome to the LaTeX community!

Can you please elaborate on this a bit? What are arg1 etc supposed to do? Do you already have some code or do we need to start from scratch? Are you using a certain document class and want to retain its definition for the headings? Or are you planning a custom class and are writing the headings yourself from scratch?

Regards
site moderator & package author
User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

Enable and Diable contents

Post by Johannes_B »

Or maybe you just don't want to compile all your code all the time? If this should be the case, then you should take a look at the include und includeonly commands.


Best Regards
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
Post Reply