|
|
P2p Chat Using Visual C | ||
Discussion by khalilov with 0 Replies.
Last Update: November 14, 2011, 11:36 am | |||
At the beginning I was going to make my P2P chat project using pure C/C++ (black console). But we were informed that we can use visual C. So I have a question
#include "stdafx.h"
#include "Form1.h"
using namespace adad;
[STAThreadAttribute]
int main(array<System::String ^> ^args)
{
// Enabling Windows XP visual effects before any controls are created
Application::EnableVisualStyles();
Application::SetCompatibleTextRenderingDefault(false);
// Create the main window and run it
Application::Run(gcnew Form1());
Form1 a;
return 0;
}
How do I make Form1 a appear? putting it in the Application::Run command gives the following error
Also an advice, I haven't used visual before so what best type would suit a P2P chat (similar to IRC) project? I am going with Windows Forms Application.
My basic idea is:
Main page:
Username/Password/Login button/Signup button
Sub pages:
Login successful / Registration forum etc...
Key pages:
Listing all active accounts and active chats. When you click on chat/account you start chatting ( a special form for chatting is shown)
Is such a thing possible in one application?
Note: This is a big project, so I can't use any 3rd party or any premade libraries that provide with the functions for visual P2P chat, I have to make everything. And so far, it's going well 8)
CODE
// adad.cpp : main project file.#include "stdafx.h"
#include "Form1.h"
using namespace adad;
[STAThreadAttribute]
int main(array<System::String ^> ^args)
{
// Enabling Windows XP visual effects before any controls are created
Application::EnableVisualStyles();
Application::SetCompatibleTextRenderingDefault(false);
// Create the main window and run it
Application::Run(gcnew Form1());
Form1 a;
return 0;
}
How do I make Form1 a appear? putting it in the Application::Run command gives the following error
CODE
Error 1 error C2665: 'System::Windows::Forms::Application::Run' : none of the 3 overloads could convert all the argument types c:\Users\pc\Documents\Visual Studio 2005\Projects\adad\adad\adad.cpp 18Also an advice, I haven't used visual before so what best type would suit a P2P chat (similar to IRC) project? I am going with Windows Forms Application.
My basic idea is:
Main page:
Username/Password/Login button/Signup button
Sub pages:
Login successful / Registration forum etc...
Key pages:
Listing all active accounts and active chats. When you click on chat/account you start chatting ( a special form for chatting is shown)
Is such a thing possible in one application?
Note: This is a big project, so I can't use any 3rd party or any premade libraries that provide with the functions for visual P2P chat, I have to make everything. And so far, it's going well 8)
Mon Nov 14, 2011 Reply New Discussion
Weird Socket Error (2)
|
(5) Writing My First C Program
|
Index




