# PetscDeviceContextViewFromOptions
View a `PetscDeviceContext` from options 
## Synopsis
```
#include <petscdevice.h> 
PetscErrorCode PetscDeviceContextViewFromOptions(PetscDeviceContext dctx, PetscObject obj, const char name[])
```

## Input Parameters

- ***dctx -*** The `PetscDeviceContext` to view
- ***obj  -*** Optional `PetscObject` to associate (may be `NULL`)
- ***name -*** The command line option





## See Also
 `PetscDeviceContextView()`, `PetscObjectViewFromOptions()`, `PetscDeviceContextCreate()`

## Level
beginner

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/sys/objects/device/interface/dcontext.cxx.html#PetscDeviceContextViewFromOptions">src/sys/objects/device/interface/dcontext.cxx</A>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/sys/objects/device/interface/dcontext.cxx)


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