Solved

retrieve bios date using delphi

Posted on 2015-02-17
3
451 Views
Last Modified: 2015-02-17
Hi,

I use Delphi 6.
Under WinXP I used following code to retrieve bios information

Function GetBIosInfo: string;
var
BiosDate, BiosName, BiosVersion, BiosNum: String;
begin
try
    BiosDate:=string(pchar(ptr($ffff5)));
    BiosName:=string(pchar(ptr($ffa68)));
    BiosVersion:=string(pchar(ptr($fe061)));
    BiosNum:=string(pchar(ptr($fec71)));
    Result := BiosDate; //BiosName, BiosVersion etc
except
    Result := 'no result';
end;
end;

Moved to Win 7 I noticed that there is no result. Code withing try is not ecexuted.

I also noticed answerID=1215430. Trying it was ineffective too, giving a compiling error in the line
  Selector := AllocSelector(DSeg);  // undeclared identifier: AllocSelector
(Might be more compiling errors in later laines)

Could you please propose something?

Best regards
Nikiforos
0
Comment
Question by:nikif
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 34

Accepted Solution

by:
ste5an earned 300 total points
ID: 40613951
I'm surprised that this really worked on all machines. Did this really work on NT windows? Cause the only direct available BIOS I know where addressable in DOS.

Newer computers don't have a BIOS anymore, they have UEFI. So you should explain why you want to interact with the hardware.

Maybe this is what you're looking for: ...read the ROM-BIOS?
0
 
LVL 19

Assisted Solution

by:MerijnB
MerijnB earned 200 total points
ID: 40613998
I agree with ste5an, besides, this is tricky stuff and might be different for different bioses and operating systems.

I would either use something commercial like:
http://www.mitec.cz/msics.html

Or try to get this info through WMI:
https://msdn.microsoft.com/en-us/library/aa394077%28v=vs.85%29.aspx
http://delphi.xcjc.net/viewthread.php?tid=46207
http://stackoverflow.com/questions/9939725/get-bios-uuid-from-c-or-delphi-from-win32
0
 

Author Closing Comment

by:nikif
ID: 40614307
Thank you both. I really ignored the status of new machines. I recently went to Win7, so I tried to have some of my applications in the the W7 environment
nikif
0

Featured Post

MS Dynamics Made Instantly Simpler

Make Your Microsoft Dynamics Investment Count  & Drastically Decrease Training Time by Providing Intuitive Step-By-Step WalkThru Tutorials.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Windows 10 Creator Update has just been released and I have it working very well on my laptop. Read below for issues, fixes and ideas.
Compliance and data security require steps be taken to prevent unauthorized users from copying data.  Here's one method to prevent data theft via USB drives (and writable optical media).
The Task Scheduler is a powerful tool that is built into Windows. It allows you to schedule tasks (actions) on a recurring basis, such as hourly, daily, weekly, monthly, at log on, at startup, on idle, etc. This video Micro Tutorial is a brief intro…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
Suggested Courses

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question