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

  • SEARCH
  • Home
  • 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 8633367
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T09:28:51+00:00 2026-06-12T09:28:51+00:00

The function I am using contains three parameters where one of which requires a

  • 0

The function I am using contains three parameters where one of which requires a flag (fCreationDisposition):

function MpqOpenArchiveForUpdate(lpFileName: LPCSTR; fCreationDisposition, dwHashTableSize: DWord): THandle; stdcall; external 'lmpqapi.dll';

The documentation states that there are five usable flags. However, when I use any of the flags Delphi tells me that it is an “undeclared identifier”.

Is there anything extra that I must add in order to be able to access the flags without Delphi telling me that it is an “undeclared identifier”?

Note: Under the uses section I have called for the function:

function MpqOpenArchiveForUpdate(lpFileName: LPCSTR; fCreationDisposition, dwHashTableSize: DWord): THandle; stdcall; external 'lmpqapi.dll';

  • 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-06-12T09:28:52+00:00Added an answer on June 12, 2026 at 9:28 am

    You have to define the flags in your code. In Delphi, you have to define everything from scratch, you cannot utilize any pre-made API header files that belong to the DLL, like you can in C/C++. So you have to track down the flag numeric values (since the documentation does not provide them) and declare them in your code, eg:

    // these values are just a guess, you will have
    // to download the API and look them up...
    const
      MOAU_CREATE_NEW = $1;
      MOAU_CREATE_ALWAYS = $2;
      MOAU_OPEN_EXISTING = $4;
      MOAU_OPEN_ALWAYS = $8;
      MOAU_MAINTAIN_LISTFILE = $10;
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Has anybody got an idea of how to create a .Contains(string) function using Linq
How to call function using parameters in powershell with parenthesis. I have as example
I wrote the function using js+jQuery. Here is a link to a jsFiddle which
I have created one multiplication of complex function using prototype in java-script function ComplexNumber(real,imaginary)
We use bookmarkable URLs and GET methods. We have some parameters which contains dates
I am trying to simulate three small datasets, which contains x1 , x2 ,
I have the following function using Excel 2010: Private Function MakeAllSheetsValuesOnly(targetBookName As String) If
I have a function using strtok like this void f1(char *name) { ... char
I want to monitor the copy file function using Delphi. I can do it
How can we apply attributes to class function using AOP in C#? UPDATE: I

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.