# PetscViewerASCIIGetStdout
Creates a `PETSCVIEWERASCII` `PetscViewer` shared by all processors in a communicator. Error returning version of `PETSC_VIEWER_STDOUT_()` 
## Synopsis
```
#include "petscviewer.h"   
PetscErrorCode PetscViewerASCIIGetStdout(MPI_Comm comm, PetscViewer *viewer)
```
Collective


## Input Parameter

- ***comm -*** the MPI communicator to share the `PetscViewer`





## Note
This should be used in all PETSc source code instead of `PETSC_VIEWER_STDOUT_()`


## See Also
 [](sec_viewers), `PETSC_VIEWER_DRAW_()`, `PetscViewerASCIIOpen()`, `PETSC_VIEWER_STDERR_`, `PETSC_VIEWER_STDOUT_WORLD`,
`PETSC_VIEWER_STDOUT_SELF`

## Level
beginner

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/sys/classes/viewer/impls/ascii/vcreatea.c.html#PetscViewerASCIIGetStdout">src/sys/classes/viewer/impls/ascii/vcreatea.c</A>

## Examples
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/snes/tutorials/ex6.c.html">src/snes/tutorials/ex6.c.html</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ts/tutorials/ex14.c.html">src/ts/tutorials/ex14.c.html</A><BR>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/sys/classes/viewer/impls/ascii/vcreatea.c)


[Index of all Viewer routines](index.md)  
[Table of Contents for all manual pages](/docs/manualpages/index.md)  
[Index of all manual pages](/docs/manualpages/singleindex.md)  
