Miscellaneous > Programming & Networking

Fucking Confusing++

(1/5) > >>

Kintaro:
I cant get this program to work, i commented on the source more then enough so you should understand it...

Main.cpp

--- Code: ---
--- End code ---

flap:
if (cmdi == "exit")

cmdi is a pointer to a string, so its value will actually just be an address of location in memory. You need to use strcmp to compare the actual contents of the string with "exit":

if (strcmp(cmdi, "exit") == 0)

The Auditor:
I found the problem..
" Microsoft Dos XP Source Code"

I think that sums it up.. LOL

... Sorry.

The Auditor

Kintaro:
lol, it will be just another work of art when im finished.

Kintaro:
Still just exits  :(  does anyone know why <x11 fiddles in vi>...


Im an idiot, sorry i had while exitlevel == 0 because im a complete freekin retard. (Its always a stupidity bug in my programs)

 :D  (Working (except for ver))

....

Ahhh got it... Nother stupidity problem (Gee Ex Eleven must have been really on the pills when posting that)...

Anyway how do you make everything in the cmdi string lower case after input

BASIC EQUIV:

cmdi$ = lcase$(cmdi$)


Thanks in advance!

Navigation

[0] Message Index

[#] Next page

Go to full version