Well anybody pls try this:
i will give an address that is 0xB8000
Now u write a function in which we can write a string and define its colour so you write the string in that memory area and increment it, and again write the colour info in that area and increment it..
The prototype of function will be
void print_string(int colour, const char *string);

remember you write the first letter of string and then increment the address by one and again write the colour and increment the address by one and do that until you write all that string in the memnory area that i gave u. ie 0xB8000

Finally if i write "HI" after writing in memoory it will have

0xB8000 | 0xB80001 | 0xB8002 | 0xB8003
H | colour | I | colour

Well anybody pls try this:
i will give an address that is 0xB8000
Now u write a function in which we can write a string and define its colour so you write the string in that memory area and increment it, and again write the colour info in that area and increment it..
The prototype of function will be
void print_string(int colour, const char *string);

remember you write the first letter of string and then increment the address by one and again write the colour and increment the address by one and do that until you write all that string in the memnory area that i gave u. ie 0xB8000

Finally if i write "HI" after writing in memoory it will have

0xB8000 | 0xB80001 | 0xB8002 | 0xB8003
H | colour | I | colour

That's text mode video memory data on IBM PC compatible machines.

Are you asking someone to write the function for you? Post the code you've tried so far, and we can help.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.