Share via

Can I batch create sections?

Anonymous
2012-06-22T11:20:13+00:00

I'd like to use OneNote to create portfolios for each of my students' work. I want each student to have a section, but I am a secondary teacher and have about 100 students, plus I take all of them for two different subjects which I want to split up. So I really don't want to have to create each section individually. 

Is it possible to get a list of students (in Excel, csv, text file or other format) and have onenote automatically create the sections?

Or can you think of another solution rather than having each student have a section that might work better?

Thanks

Michal Rousset

Gisborne Secondary College

Gisborne, Victoria, Australia

Microsoft 365 and Office | OneNote | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

Anonymous
2012-06-22T17:02:19+00:00

A simple one-liner:

for /f %%g in (students.txt) do (copy template.one %%g.one)

  1. Store this line in xyz.bat file using notepad
  2. students.txt is a notepad file with one line per student containing its last name
  3. template.one is the template Onenote section
  4. run xyz.bat in a CMD window

The result are x sections (*.one files), named <studentx>.one

I'm really no expert in scripting, but I have tested it ;-)

It works only with all files in the same directory because I omitted any paths.

Bernd

Was this answer helpful?

1 person found this answer helpful.
0 comments No comments

Answer accepted by question author

Anonymous
2012-06-22T14:26:09+00:00

Not natively but it seems like something that might be scriptable. Sections are individual .ONE files. So you'd just need to create a base .ONE file, then have something that copies that .ONE file, gives it a name from your list of students (probably in .CSV), then repeats that process over and over iterating through the list until it gets to the bottom.

Was this answer helpful?

0 comments No comments

3 additional answers

Sort by: Most helpful
  1. Anonymous
    2012-06-23T13:17:35+00:00

    "Importing" into a notebook or a section group by script is easy.

    A notebook or section group is nothing else than a folder in the Windows file system.

    A notebook folder by default is a folder under "Documents\Onenote Notebooks".

    A section group is a more or less deep nested folder within a notebook's folder.

    Bernd

    Was this answer helpful?

    0 comments No comments
  2. Anonymous
    2012-06-23T06:07:56+00:00

    Thanks. That's what I've done and it worked great.

    Was this answer helpful?

    0 comments No comments
  3. Anonymous
    2012-06-23T06:07:14+00:00

    Thanks. That has created the sections perfectly. 

    Is there an easy way to then import them into a notebook? I've managed to do it, but it involves opening them all and then individually dragging each one to the section group.

    I'm new to onenote, but fairly experienced with computers generally, so I'm sorry if this is a stupid question.

    Thanks,

    Michal Rousset

    Was this answer helpful?

    0 comments No comments