TurboC and windows.h library

Posted on 2004-09-13
Last Modified: 2010-04-15
Hello everyone,

I wrote a little program that makes a banner like linux banner command using TurboC 2.01, since I want to convert long filenames to short filenames, where I can find the windows.h library to add in the TurboC to use the GetShortPathName API function?

Or even is there a 32bit version of the 16bit instruction:

ch1 = (char far *)0xFFA6000EL + (ch * 8) + 1

so I could compile it with DJGPP obviously finding a windows.h library since I don't have it in the DJGPP include directory?

Ciao, Luigi
Question by:npuleio
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
  • 3
  • 2
LVL 45

Accepted Solution

sunnycoder earned 250 total points
ID: 12042233
I do not think it is possible ... you cannot link 16 bit code to 32 bit library

Author Comment

ID: 12042326
OK sunnycoder,

then since I'm doing something like the Unix banner command, and I've found the bitmap argument as in the instruction I said in the previous post, do you know maybe how it's treated the bitmap character in 32bit mode so I could try to "convert" the 16bit code in 32bit code then compiling it with DJGPP instead of TurboC?

Ciao, Luigi
LVL 45

Expert Comment

ID: 12042644
Hi npuleio,

I do not know how windows treats the bitmap argument.

I am bit confused on this one but as far as I can recollect, Unix banner did not involve bitmaps. There have been questions on replicating the banner command functionality and the easiest way I remember is to read input char by char and have predefined ASCII patterns for each character entered. Not so elegant but works.

If you wish, I can reopen the question and you can wait for some windows Expert to comment on this.


Author Comment

ID: 12042889
I don't think it does need to reopen... from your suggest about prefefined ascii patterns I'm just writing some code and in that way I guess it'll work for sure....
Thanks a lot anyway :-)
Ciao, Luigi
LVL 45

Expert Comment

ID: 12042928
Hi Luigi,

In that case, I would request you to revise the grade. Please take time to read this link

Grade can be revised by posting a 0 point request in Community Support


Featured Post

Independent Software Vendors: 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

An Outlet in Cocoa is a persistent reference to a GUI control; it connects a property (a variable) to a control.  For example, it is common to create an Outlet for the text field GUI control and change the text that appears in this field via that Ou…
Summary: This tutorial covers some basics of pointer, pointer arithmetic and function pointer. What is a pointer: A pointer is a variable which holds an address. This address might be address of another variable/address of devices/address of fu…
Video by: Grant
The goal of this video is to provide viewers with basic examples to understand and use while-loops in the C programming language.
The goal of this video is to provide viewers with basic examples to understand and use conditional statements in the C programming language.

630 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