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
Solved

TBitmap and compiler errors

Posted on 2000-03-11
2
214 Views
Last Modified: 2010-04-04
I'm creating a TBitmap

var Bitmap: TBitmap;
begin
  Bitmap : =TBitmap.Create;
  etc etc
theproblem is that here a get a compiler error of 'Object or class type required'.
Any ideas why? I used the same piece of code in another app with no problems.

cheers
Chris

0
Comment
Question by:xpher
2 Comments
 
LVL 17

Accepted Solution

by:
inthe earned 50 total points
ID: 2608336
hehe hi xpher you can blame microsoft for this one .

see these 2 uses clauses:
uses
  Graphics,Windows,Messages, SysUtils...

uses
  Windows,Graphics, Messages, SysUtils...

the second is how yours should be.
tbitmap is also declared in windows.pas as microsift added a tbitmap to the windows and as it is declared in first uses clause after the graphics.tbitmap it is used instead .
therefore the error.

Regards Barry
0
 
LVL 1

Author Comment

by:xpher
ID: 2608372
Thanks for swift response.
I had Graphics, SysUtils, Windows
everything aok now.

cheers
Chris :))
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Strange code, can use it, but i cant figure out what it does. 3 66
Reconfigure Delphi Install? 2 60
SUM 2 INTEGER ARRAYS INTO 1 10 108
Convert MS Word document to a PDF file 9 90
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

839 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