|
I didn't really look at all your data because it is too much to go through but installing Service Pack 5 is the best advice that I can give you at the moment. I have had serious problems before I installed it and this topic has been discussed here before. Everyone has had weird problems that were fixed by installing SP5.
Spero che SP5 solvera il tuo problemo! Buona fortuna!
// Afterall, I realized that even my comment lines have bugs
When one cannot invent, one must at least improve (in bed).-My latest fortune cookie
|
|
|
|
|
I have an application with about 20 toolbar buttons. Normally, all buttons are showing in one screen. But if I change the Windows font to a much larger font, the buttons to the right are cut off. Is there a way I can scroll to the left and right on the tollbar to see all the buttons?
Eilzabeth
|
|
|
|
|
The little-used pager control will do this. If you remember IE 4, it used a pager control on its toolbars, instead of the current method of showing a chevron.
--Mike--
"So where does that leave us? Well, it leaves us right back where we started, only more confused than before." -- Matt Gullett
Ericahist | Homepage | RightClick-Encrypt | 1ClickPicGrabber
|
|
|
|
|
Michael, can you be more specific? I don't get your hint.
Eilzabeth
|
|
|
|
|
|
Now I have initialized the control at the InitInstance event:
-------------------------
BOOL CMyApp::InitInstance()
{
//initialize page control object
LPINITCOMMONCONTROLSEX lpInitCtrls = new INITCOMMONCONTROLSEX;
lpInitCtrls->dwICC =ICC_PAGESCROLLER_CLASS;
InitCommonControlsEx(lpInitCtrls);
-------------------------
I have also created the pager control:
------------------------------
int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct)
{
//create the pager control
if (!CreateWindow(WC_PAGESCROLLER,NULL,PGS_HORZ|WS_CHILD, CW_USEDEFAULT, NULL, CW_USEDEFAULT, NULL, NULL,NULL,NULL,NULL))
return -1;
-----------------------------
Now how do I assigned the pager control to the application toolbar m_wndToolBar?
Eilzabeth
|
|
|
|
|
is there any way to use the Cwnd timer in dll withaout creating
new window ? if there is no way than how can i use the timer in thread in
dll
|
|
|
|
|
One solution is a timer queue timer.
Kuphryn
|
|
|
|
|
The ::SetTimer() function can be used to force a callback to a specified function rather than sending a message to a window. For example:
void CALLBACK MyTimerProc(HWND hWnd, UINT nMsg, UINT_PTR idEvent, DWORD dwTime)
{
// Do something
}
UINT nID = ::SetTimer( NULL, 0, 1000, MyTimerProc );
This will call MyTimerProc after 1000ms. The first parameter is NULL, meaning that no window is associated with this timer.
Dave
http://www.cloudsofheaven.org
|
|
|
|
|
hello @all,
i have to write a program which generates randomized letters, e.g. from A to D (variable letters and with a variable length). the string could look like:
CString str="AAACCDDDDDBBBBCDABBBDDDD....";
can anybody help me?
thank you very much!!!
sunny
|
|
|
|
|
char GetRandomLetter( void )
{
char cLetter;
cLetter = (rand() % 26) + 'A';
return cLetter;
}
CString str;
for (int x = 0; x < some_length; x++)
{
char c = GetRandomLetter();
str += c;
}
|
|
|
|
|
thanks for reply.
the program works, but i don't know why!
DavidCrow wrote:
cLetter = (rand() % 26) + 'A';
why does this works?
thank you very much!
sunny
|
|
|
|
|
rand() gives you a number between 0 and RAND_MAX. Modulo that with 26 gives you a number between 0 and 25. Add 'A' to that gives you one of the 26 letters of the alphabet. Make sense?
|
|
|
|
|
One solution is to generate a number and then convert it to a char.
string text;
unsigned int randNum = 0;
for (unsigned int i = 0; i < nTextSize; ++i)
{
randNum = static_cast<unsigned int="">((((static_cast<double>(rand())) / (static_cast<double>(RAND_MAX + 1))) * 94 + 33));
sName += static_cast<char>(randNum);
}
Kuphryn
|
|
|
|
|
Hi! I'm not exactly new to MFC but i haven't really dealt with internet programming. I was wondering how i could create an internet chat program. I found stuff on network chat programs but nothing on internet chat programs. Could i use a web server?
-- Steve
|
|
|
|
|
One solution is winsock.
Kuphryn
|
|
|
|
|
What's the scope of your quest?
Is this a "for fun" kinda "i want to talk to my friends" thing?
If you're doing a "for fun" programming, the easiest way to do this, is to create a peer-to-peer application. Where each client speaks directly to the other client via the net -- TCP or UDP (winsock). This involves writing one piece of software, the software is a UI, and a networking endpoint.
If you want to write a serious chat program, that ya gotta go the "client/server" route. Where you actually end up writing 2 different pieces of software: a client(UI and winsock connection to server) and a server which manages the chat, and makes sure text is routed to each connected client.
Client/Server is by far the better route. Peer-to-Peer seems simple until you want to do something fancy -- like create a chat room with more than one other person in it. Or for more advanced -- sending video to more than one other person....
Good luck in your chat adventure.
I've seen source code out there for simple peer-to-peer chat programs based in java....
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~<br />
Peter Weyzen<br />
Staff Engineer<br />
<A HREF="http://www.santacruznetworks.com">Santa Cruz Networks</A>
|
|
|
|
|
i don't have the ability to do a client/server chat, so i'm going to try peer-to-peer. What i don't get is how to connect the 2 computers though the internet. i can't find anything on it.
-- Steve
|
|
|
|
|
In VC6 Have a look at the ChatSrvr and Chatter sample programs.
Alternatively you could look at an internet article on CodeProject [^]
If you can keep you head when all about you
Are losing theirs and blaming it on you;
If you can dream - and not make dreams your master;
If you can think - and not make thoughts you aim;
Yours is the Earth and everything that's in it.
Rudyard Kipling
|
|
|
|
|
Hi Folks!
I want to write a program that should be able to determine how many instances of the (same) program are currently running and what are they doing. Based upon this, it should decide whether to work immediately or to pause until the other instances are finished and continue after that.
How would you do that?
Best Regards,
Christian Richardt
Those who know don't talk.
Those who talk don't know.
|
|
|
|
|
Maybe CSemaphore can be what you're looking for.
Joaquín M López Muñoz
Telefónica, Investigación y Desarrollo
|
|
|
|
|
Hi! I am really confused!
I am using the DHTML edit control and it is making some kind of newline in the html code which I dont want because I want to put infront of and after each line some chars and with that mysterious newline it puts the chars to be placed at the end of the line after a newline ! Are there any other newlines than '\n' and '\r\n' ???
Thank you for your answers in advance!
|
|
|
|
|
Scolinks wrote:
Are there any other newlines than '\n' and '\r\n' ???
No, that's it.
|
|
|
|
|
<br> ?
|
|
|
|
|
Is there any good tutorial or some sample project with source codes?
|
|
|
|