Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6349659
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T21:39:31+00:00 2026-05-24T21:39:31+00:00

I need to execute some additional configuration after installation so I have created a

  • 0

I need to execute some additional configuration after installation so I have created a smoll PostInstall.exe console application which should do the work. I need to get winamp install path from the registry.

This PostInstall.exe works fine if I run it alone. But if I use it in custom action “After Register Product”, I get an error “The system cannot find the file specified” returned from the function

DWORD kres  =  RegOpenKeyExW(HKEY_CURRENT_USER, L"Software\\Winamp",0, KEY_QUERY_VALUE, &hKey);

I am 100% sure that the key exists – I verify it before I launch installation. Also when I run PostInstall.exe manually after installation, it succeeds.

I have tried to set “Deferred Execution” and “Deferred execution in system context” but that
does not help.

Why does RegOpenKeyEx fail in my custom action?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T21:39:33+00:00Added an answer on May 24, 2026 at 9:39 pm

    Make sure that the installation is not being elevated under another user account. This way your custom action process will not be executed for a different user which has a different HKEY_CURRENT_USER hive.

    Also, try getting the current user inside your custom code and determine if it’s the one you expect.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I need to create some windows service which will execute every N period of
I have a simple page that I need to execute some GWO & GATC
I need execute some code before Windows shutdown process each time. So, I want
In an impersonation scenario related to Sharepoint I need to execute some code in
I am working on a bash script where I need to conditionally execute some
I need to execute a select and then update some of the rows in
I have an HTML textbox that contains some SQL code that I need executed.
I need to execute MDX query from command line (MS AS 2005). I have
I need some advice. I have a web page and want to extend it's
I have some additional scripts that I've written outside of my Rails 3.1.x app,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.