forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Which files to include to access windows API ?

 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> General
View previous topic :: View next topic  
Author Message
ursuselasticus



Joined: 26 Mar 2005
Posts: 71

PostPosted: Sun Feb 11, 2007 7:01 pm    Post subject: Which files to include to access windows API ? Reply with quote

Hi,

what do I need to access windows API from Salford FTN95 ?

I found

win32api.ins - stdcall statements to call the c/c++ API functions
win32prm.ins - parameters for the API routines

What I am missing is the type declarations which would be included in windows.h (but as far as I can see not in a FTN95 readable file).

Any ideas ?

Norbert
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7916
Location: Salford, UK

PostPosted: Sun Feb 11, 2007 7:52 pm    Post subject: Reply with quote

See Win32 Platform->Mixed Language Programming->Data types->Basic data types

and

Win32 Platform->ClearWin+->Using the Windows API

in FTN95.chm
Back to top
View user's profile Send private message AIM Address
ursuselasticus



Joined: 26 Mar 2005
Posts: 71

PostPosted: Sun Feb 11, 2007 8:48 pm    Post subject: Reply with quote

Thanks Paul,

but these articles do not provide an answer, at least I fail to recognise it.

Some API functions require data structures, declarations of which are included in header files.

Example:

typedef struct 16 tagWNDCLASS
{
UINT style;
LONG ( WIN *lpfnWndProc)();
win_int cbClsExtra;
win_int cbWndExtra;
HINSTANCE hInstance;
HICON hIcon;
HCURSOR hCursor;
HBRUSH hbrBackground;
LPCSTR lpszMenuName;
LPCSTR lpszClassName;
} WNDCLASS;


As we need the same derived types to operate API, my question is, if there are includefiles, modules or whatever that may be introduced into my project to declare all these ? Or am I required to define each and every struct that I will need for myself ??

Norbert

Norbert
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7916
Location: Salford, UK

PostPosted: Sun Feb 11, 2007 9:55 pm    Post subject: Reply with quote

You must define them yourself. Sometimes this can be difficult. The subject is mentioned in the help file (use of LOC and CORE4 etc). Don't forget to use the SEQUENCE attribute.
Back to top
View user's profile Send private message AIM Address
ursuselasticus



Joined: 26 Mar 2005
Posts: 71

PostPosted: Mon Feb 12, 2007 8:41 pm    Post subject: Reply with quote

Thanks Paul.

Norbert
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> General All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group