# SNESShellGetContext
Returns the user-provided context associated with a `SNESSHELL` 
## Synopsis
```
#include "petscsnes.h"   
PetscErrorCode SNESShellGetContext(SNES snes, void *ctx)
```
Not Collective


## Input Parameter

- ***snes -*** should have been created with `SNESSetType`(snes,`SNESSHELL`);



## Output Parameter

- ***ctx -*** the user provided context





## See Also
 `SNESSHELL`, `SNESCreateShell()`, `SNESShellSetContext()`

## Level
advanced

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/snes/impls/shell/snesshell.c.html#SNESShellGetContext">src/snes/impls/shell/snesshell.c</A>

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


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/snes/impls/shell/snesshell.c)


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