Page 3 of 6 FirstFirst 12345 ... LastLast
Showing results 41 to 60 of 106

Thread: C++ Questions

  1. #41
    Senior Member

    Crusader
    Dyndrilliac's Avatar
    Join Date
    Jun 2005
    Location
    Jacksonville, FL, USA
    Posts
    3,618

    Default

    The .NET Framework is similar to Java's API Framework. It's basically a windows-universal language. It's designed to be OO, and RAD capable. C++.NET and VB.NET are the only .NET languages that can access both the .NET Framework, and the Win32 API.

    The Win32 API ("I" as in "eye", Application Programming Interface) is available on all Windows Operating systems. However, some features available on the NT/Vista platform are unavailable on legacy systems (DOS, Windows 3.x, Win9X/Me). To find out more information about anything related to a Microsoft product, goto MSDN. There's a link for it in the Guide thread, linked in my sig.

    Assembled binary modules (*.exe, *.dll, *.lib) and their handling systems are written with machine code. Assembler languages are compiled into machine code.

    You can program game hacks in Assembler.
    The Ultimate Guide Thread
    Quote Originally Posted by Ethernet Networking Bible
    Thou shalt switch where thy can, and route where thy must.

  2. #42

    Default

    -What is .NET useful for?
    -Will Windows XP programs run on Vista?
    -I was talking about writeing a program using pure machine code, no ASM knowledge whatsoever. This is possible, right?

  3. #43
    Senior Member

    Crusader
    Dyndrilliac's Avatar
    Join Date
    Jun 2005
    Location
    Jacksonville, FL, USA
    Posts
    3,618

    Default

    .NET can do just about everything. Although, it is primarily for RAD using strict OO paradigms (Commercial applications of all sorts). Although, system drivers/games/gamehacks are best left to a compiled language with access to the core API of your OS.

    Yes, Vista will support legacy software. However, this forum is inappropriate for this topic.

    No. Writing software straight by scratch using a Hex-editor or other unicode data reader is impossible. If you were a software developement God, you might be able to make a HelloWorld application after years of painstaking work converting the Assembly code you know nothing about into Hex and transcribing it into a file using the Portable Executable format. And, when you get done with that project, you'll run the program and after days of debugging lines of hex you'd come to the realization that your code is using the wrong byte order for your machines architecture and you'll have to start all over again.

    Please use google before posting in the forums. The questions which you ask could be answered by a simple Google query.
    The Ultimate Guide Thread
    Quote Originally Posted by Ethernet Networking Bible
    Thou shalt switch where thy can, and route where thy must.

  4. #44
    Geeky Azn d00d
    Enlightened
    Loser777's Avatar
    Join Date
    Oct 2005
    Location
    California
    Posts
    2,931

    Default

    Just a quickie... I've started learning C++ and when compiling my first few programs with bloodshed... The program will execute... but it closes immediately after it runs: ex: I will have it print some text... but the window will close right after execution...(I know it isn't a program error because if I include code at the end for user input, the windows stays open and the program functions correctly)-The program will then close after recieving input. Anyone know a way around this?
    It's been a pretty long time since I've been here

  5. #45
    Senior Member

    Crusader
    Dyndrilliac's Avatar
    Join Date
    Jun 2005
    Location
    Jacksonville, FL, USA
    Posts
    3,618

    Default

    Sleep(unsigned long), getch(void), system("pause").

    Those all work. It's better to use a control loop instead of having to force a pause though.
    The Ultimate Guide Thread
    Quote Originally Posted by Ethernet Networking Bible
    Thou shalt switch where thy can, and route where thy must.

  6. #46

    Default

    cin.get() and getchar() put at the end of the program will also work.

  7. #47
    Senior Member

    Crusader
    Dyndrilliac's Avatar
    Join Date
    Jun 2005
    Location
    Jacksonville, FL, USA
    Posts
    3,618

    Default

    But were those functions designed with that functionality? No. It's a bad idea to use functions to do things that they were not designed to do.
    The Ultimate Guide Thread
    Quote Originally Posted by Ethernet Networking Bible
    Thou shalt switch where thy can, and route where thy must.

  8. #48
    Geeky Azn d00d
    Enlightened
    Loser777's Avatar
    Join Date
    Oct 2005
    Location
    California
    Posts
    2,931

    Default

    Quote Originally Posted by Dyndrilliac View Post
    Sleep(unsigned long), getch(void), system("pause").

    Those all work. It's better to use a control loop instead of having to force a pause though.
    Ok... but I found out that this was caused by a return 0; statement... So dumb.
    It's been a pretty long time since I've been here

  9. #49
    Senior Member

    Crusader
    Dyndrilliac's Avatar
    Join Date
    Jun 2005
    Location
    Jacksonville, FL, USA
    Posts
    3,618

    Default

    Thats absurd. Every function has to return, otherwise the basepointer gets corrupted.
    The Ultimate Guide Thread
    Quote Originally Posted by Ethernet Networking Bible
    Thou shalt switch where thy can, and route where thy must.

  10. #50
    Geeky Azn d00d
    Enlightened
    Loser777's Avatar
    Join Date
    Oct 2005
    Location
    California
    Posts
    2,931

    Default

    Quote Originally Posted by Dyndrilliac View Post
    Thats absurd. Every function has to return, otherwise the basepointer gets corrupted.
    No, a return 0; at the end of the program...
    It's been a pretty long time since I've been here

  11. #51
    Senior Member

    Crusader
    Dyndrilliac's Avatar
    Join Date
    Jun 2005
    Location
    Jacksonville, FL, USA
    Posts
    3,618

    Default

    You fool, you know nothing. Every program MUST have a method(function,proc) that serves as the entry point for the program. This is usually Main() or the like. Every method returns a value. Period. End of discussion. However, most languages allow you to create void methods or sub-routines which don't require you to specify a value, and return null automatically, with compiler automated basepointers and stack frames and the like.

    As I said, the return statement is irrelevant to your issue. Whoever told you that should be shot. You have two options: Forced pauses and control loops.

    Control loops represent the usual methods for multi-threaded applications and event driven code (the best kind). Forced pauses are the usual methods for crappy JMP-based unmodular badly written code. The choice is clear.
    The Ultimate Guide Thread
    Quote Originally Posted by Ethernet Networking Bible
    Thou shalt switch where thy can, and route where thy must.

  12. #52
    Geeky Azn d00d
    Enlightened
    Loser777's Avatar
    Join Date
    Oct 2005
    Location
    California
    Posts
    2,931

    Default

    Quote Originally Posted by Dyndrilliac View Post
    You fool, you know nothing. Every program MUST have a method(function,proc) that serves as the entry point for the program. This is usually Main() or the like. Every method returns a value. Period. End of discussion. However, most languages allow you to create void methods or sub-routines which don't require you to specify a value, and return null automatically, with compiler automated basepointers and stack frames and the like.

    As I said, the return statement is irrelevant to your issue. Whoever told you that should be shot. You have two options: Forced pauses and control loops.

    Control loops represent the usual methods for multi-threaded applications and event driven code (the best kind). Forced pauses are the usual methods for crappy JMP-based unmodular badly written code. The choice is clear.
    Eh.. I know nothing.. that is true... I just said I was starting to learn. -eidt taking out return 0 didn't fix it.. I guess I will try the loop then.
    It's been a pretty long time since I've been here

  13. #53
    Senior Member

    Crusader
    Dyndrilliac's Avatar
    Join Date
    Jun 2005
    Location
    Jacksonville, FL, USA
    Posts
    3,618

    Default

    Next time don't contradict me unless you have a guarentee that you are right. I wont hesitate to argue over a topic that I am intimately familiar with.
    The Ultimate Guide Thread
    Quote Originally Posted by Ethernet Networking Bible
    Thou shalt switch where thy can, and route where thy must.

  14. #54
    Retired Staff Member

    Zealot
    Palomino's Avatar
    Join Date
    Jul 2004
    Location
    NSW, Australia
    Posts
    754

    Default

    Quote Originally Posted by Dyndrilliac View Post
    C++.NET and VB.NET are the only .NET languages that can access both the .NET Framework, and the Win32 API.
    Hrm, I'm quite sure you can use attributes in all .net langs to access functions in dlls, including win32 api (the .net core even nicely marshals arguments and return types)
    That being said, managed c++ and c# are the only langs which can use pointers natively(c# via the unsafe keyword)
    "Cryptography is a pointless science. It does not matter how securely a message is encrypted, there are always ways of getting around it. It is all just a question of effort, unscrupulousness and bribes. On this note, I want to conclude my book. I hope you had fun reading it." - Klaus Schmeh
    ((λ (x) (x x)) (λ (x) (x x)))

  15. #55
    Senior Member

    Crusader
    Dyndrilliac's Avatar
    Join Date
    Jun 2005
    Location
    Jacksonville, FL, USA
    Posts
    3,618

    Default

    C# and VB.NET both support calling Win32 API functions, but they force the programmer to define every function prototype that they plan to call individually, while in C++.NET you can simply include the Windows API header and mark it as unmanaged code. However, Unlike VB.NET and C++.NET, C# requires data marshalling, an understanding of different calling conventions and how they effect the stack, etc, etc, etc.

    Therefore, I consider C# to not truly interface with the Win32 API. VB really doesn't either, but it's better than how C# does it.
    The Ultimate Guide Thread
    Quote Originally Posted by Ethernet Networking Bible
    Thou shalt switch where thy can, and route where thy must.

  16. #56

    Deviant
    kyleshome's Avatar
    Join Date
    Jun 2005
    Location
    in a small mailbox in space some where
    Posts
    59

    Default

    Quote Originally Posted by Dyndrilliac View Post
    Functions do not require arguments. That aspect is not unique to the main() sub-routine.
    oh, i learned that in some old c++ book, i'm kinda new to C++ programing

  17. #57

    Default

    i got a question for ya. when i compile a program it sometimes says (the error is in bold italic and underlined) and i have a brace (}) at the end.

    Compiler: Default compiler
    Building Makefile: "C:\Dev-Cpp\Makefile.win"
    Executing make...
    make.exe -f "C:\Dev-Cpp\Makefile.win" all
    g++.exe -c "First Project/main.cpp" -o "First Project/main.o" -I"C:/Dev-Cpp/include" -I"C:/Dev-Cpp/include"

    First Project/main.cpp: In function `int main(int, char **)':
    First Project/main.cpp:134: parse error at end of input

    make.exe: *** ["First] Error 1

    Execution terminated
    :worthless::worthless:

  18. #58

    Default

    I looked around a bit, and can't find anything...

    Now people are telling me to forget C++ entirely and learn C#. Should I do this?

  19. #59

    Default

    no. stick with C++ its a highly used language. its also easy to make powerful programs with C++.
    :worthless::worthless:

  20. #60

    Default

    How can I use C++ to make Windows Applications then? I've been told MFC is outdated.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Questions about all these hacks.
    By d0pe in forum Starcraft/Brood War
    Replies: 12
    Last Post: 04-02-2005, 09:34 PM
  2. Google Adsense Questions
    By Marine6592 in forum General Chat
    Replies: 4
    Last Post: 04-01-2005, 06:25 AM
  3. Questions about Damnation and inhale
    By Teddy in forum Starcraft/Brood War
    Replies: 13
    Last Post: 12-29-2004, 12:37 PM
  4. Blackllama Questions
    By llafnwod in forum Flame Board
    Replies: 33
    Last Post: 12-05-2004, 03:37 PM
  5. Questions on hacking
    By x2570 in forum Starcraft/Brood War
    Replies: 4
    Last Post: 10-07-2004, 03:47 PM

Posting Rules

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •