views:

168

answers:

1

when i try to compile my application in delphi prism, i got these errors

C:\Users\Burak\Documents\Visual Studio 2008\Projects\Project1\WindowsApplication1\WindowsApplication1\Main.pas(6,3) : Error : (PE17) Namespace "Windows" does not exist or has no public types C:\Users\Burak\Documents\Visual Studio 2008\Projects\Project1\WindowsApplication1\WindowsApplication1\Main.pas(7,3) : Error : (PE17) Namespace "Tlhelp32" does not exist or has no public types

am i doing wrong?

uses Windows, Tlhelp32, System.Drawing, System.Collections, System.Collections.Generic, System.Linq, System.Windows.Forms, System.Windows, System.ComponentModel;

i use 2009 delphi prism, small answers can solve my problem (also i think my problem is stupid, but i can not use CreateRemoteThread, and WriteProcessMemory w/o it).

Best Regards, Burak TAMTURK

+5  A: 

The units (namespaces in .net) Windows and Tlhelp32 are not part of Delphi Prism (.Net), they exist only in Delphi Win32, the first thing you must do, to compile your project is to remove these namespaces in the header of your code. Then you can use PInvoke (Platform Invocation Services) to calling Win32 functions and other unmanaged APIs from managed code (.Net).

I recommend you see these links

Bye.

RRUZ