When I create a new ASP.NET 4.5 web application MVC in Visual Studio, it starts with a introduction template.

The relavant parts are:

**Views/Home/About.cshtml**

```
@{
    ViewBag.Title = "About";
}
<h2>@ViewBag.Title.</h2>
...

```

**Views/Shared/\_Layout.cshtml**

```
<!DOCTYPE html>
<html>
<head>
    <title>@ViewBag.Title - My ASP.NET Application</title>
...
    @RenderBody()
...

```

**Views/\_ViewStart.cshtml**

```
@{
    Layout = "~/Views/Shared/_Layout.cshtml";
}

```

If I understand right, and assuming the About page is opened in the browser:

* The **\_ViewStart.cshtml** is called first, and it says there is a layout **\_Layout.cshtml** to be called.
* It renders the **\_Layout.cshtml**, until the call **@RenderBody()** is reached, on that point he will render the **About.cshtml**. When that ends, he will render the rest of the **\_Layout.cshtml**.

But here is my doubt, if the **\_Layout.cshtml** starts first, how does it print on the `<title>` the variable `@ViewBag.Title`, which is assigned only in **About.cshtml**?