# How to write data into regedit in slicer?

**URL:** <https://discourse.slicer.org/t/how-to-write-data-into-regedit-in-slicer/27736>\
**Category:** Development\
**Created:** [February 10, 2023, 6:14am UTC](https://discourse.slicer.org/t/how-to-write-data-into-regedit-in-slicer/27736 "2023-02-10T06:14:13Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jay1987](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/jay1987/32/16183_2.png) [@jay1987](https://discourse.slicer.org/u/jay1987)\
**Post date:** [February 10, 2023, 6:14am UTC](https://discourse.slicer.org/t/how-to-write-data-into-regedit-in-slicer/27736/1 "2023-02-10T06:14:13Z")

</div>

i have made a simple application use 3dslicer , and wants to write some data into regedit  
but write data into regedit in win10 need administrator privileges  
i have tryed some code in netword and in chatgpt,it doesn’t work  
dear community ,does anyone knows how to write data into regedit in slicer or how to obtain administrator privileges in slicer?

---

<div class="post-metadata">

**Author:** ![cpinter](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/cpinter/32/7995_2.png) [@cpinter](https://discourse.slicer.org/u/cpinter)\
**Post date:** [February 10, 2023, 9:57am UTC](https://discourse.slicer.org/t/how-to-write-data-into-regedit-in-slicer/27736/2 "2023-02-10T09:57:29Z")

</div>

I suggest you use the ini file (see `QSettings`) to store configuration specific information.

---

<div class="post-metadata">

**Author:** ![jay1987](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/jay1987/32/16183_2.png) [@jay1987](https://discourse.slicer.org/u/jay1987)\
**Post date:** [February 10, 2023, 10:37am UTC](https://discourse.slicer.org/t/how-to-write-data-into-regedit-in-slicer/27736/3 "2023-02-10T10:37:02Z")

</div>

i agree with you pinter  
if i can’t find solution to write to the regedit, i will use the solution to wirte into QSetting
