library

If you have questions about any aspect of QBasic programming, or would like to help fellow programmers solve their problems, check out this board!

Moderators: Pete, Mods

Post Reply
User avatar
Seb McClouth
Veteran
Posts: 342
Joined: Wed Nov 09, 2005 7:47 am
Location: Inside the Matrix...
Contact:

library

Post by Seb McClouth »

While compiling to a library I have the following code:

Code: Select all

'$include:'lib.qbi' 'contains the declares

FUNCTION OpenFile(FileName AS STRING)
OPEN FileName FOR OUTPUT AS #1
END FUNCTION
While doing the compile I get a 'Duplicate definition', for no reason 'cause there is no duplicate. Any suggestions?

I've loaded qb 7.1 with qbx /l

grtz
QBinux is a Linux distribution with the aim of integrating the work of the vast community of free software developers at Pete's QBASIC Site in order to create a modern, performant, safe and easy to use system for system administrators and desktop users.
Bulldog
Newbie
Posts: 7
Joined: Wed Aug 09, 2006 9:30 am

Post by Bulldog »

do you by chance have your function declared as a different type in your include (ie.) declare function OpenFile%(FileName as string)

if so you need the % or whatever type declaration is being used in the include on the end of the function name.
User avatar
Seb McClouth
Veteran
Posts: 342
Joined: Wed Nov 09, 2005 7:47 am
Location: Inside the Matrix...
Contact:

Post by Seb McClouth »

Everything is without $, %, etc... double checked... I've thrown it away and started all over... if it happens again, I'll post it...
QBinux is a Linux distribution with the aim of integrating the work of the vast community of free software developers at Pete's QBASIC Site in order to create a modern, performant, safe and easy to use system for system administrators and desktop users.
Post Reply