Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

Points for j42

Posted on 2003-03-27
1
Medium Priority
?
136 Views
Last Modified: 2010-04-04
0
Comment
Question by:ginsonic
1 Comment
 
LVL 2

Accepted Solution

by:
j42 earned 200 total points
ID: 8217496
Thank you,

I suppose this looks much better:



procedure SaveState(const menu: TMainMenu);
var
  i: integer;
begin
  for i := 0 to (menu.Items.Count - 1) do
  begin
    menu.Items[i].Tag := Ord(menu.Items[i].Enabled);
  end;
end;

procedure DisableAll(const menu: TMainMenu);
var
  i: integer;
begin
  for i := 0 to (menu.Items.Count - 1) do
  begin
    menu.Items[i].Enabled := False;
  end;
end;

procedure RestoreState(const menu: TMainMenu);
var
  i: integer;
begin
  for i := 0 to (menu.Items.Count - 1) do
  begin
    menu.Items[i].Enabled := boolean(menu.Items[i].Tag);
  end;
end;
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
Introduction Raise your hands if you were as upset with FireMonkey as I was when I discovered that there was no TListview.  I use TListView in almost all of my applications I've written, and I was not going to compromise by resorting to TStringGrid…
This Micro Tutorial will teach you how to add a cinematic look to any film or video out there. There are very few simple steps that you will follow to do so. This will be demonstrated using Adobe Premiere Pro CS6.
The Relationships Diagram is a good way to get an overall view of what a database is keeping track of. It is also where relationships are defined. A relationship specifies how two tables connect to each other. As you build tables in Microsoft Ac…
Suggested Courses

572 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