I’m trying to create a Dataview table in Obsidian that includes task checkboxes, the file name, and the folder in which each task is written. My goal is to see not only the task text but also whether the task is completed, alongside the file and folder information.
Things I have tried
Here is my best attempt so far, which successfully displays the file name, folder name, and task text, but unfortunately, the checkboxes are missing:
table file.folder as "Folder", file.tasks.text as "Task"
from "myproject"
Could anyone help me figure out how to include the checkboxes for the tasks as well?
To achieve your goal to list task information like that (without the possibilty to complete tasks), you can do something like the following:
```dataview
TABLE file.folder as "Folder", task.text as Task, task.status as Status, choice(task.status = "x", "🟢", "🔴") as Completed
FROM "myproject"
FLATTEN file.tasks as task
```
Play around with that and see if you can’t get an output you like.
Thank you for the solution! The table looks great and displays the information nicely. However, I was wondering if it is possible to actually complete the tasks directly from the table (i.e., check the checkboxes) within the Dataview table itself. Is there a way to achieve this interactivity, or is it only possible to display the task status without the ability to modify it directly in the table?