|
Anonymous wrote:
as we are around 700 members in this group,
its very high traffic every day 8-10 mails.
OMG! How do your servers cope?!
Lets be honest, isn't it amazing how many truly stupid people you meet during the course of the day. Carry around a pad and pencil, you'll have twenty or thirty names by the end of the day - George Carlin
Awasu 1.2.1 [^]: A free RSS reader with support for Code Project.
|
|
|
|
|
Thanks but no thanks
CodeProject is a million times better
|
|
|
|
|
hello everybody,
i like to develop a parser which should parse the user given inputs..
exampl,
----------------------------
# code
ln 123,232,23,223;
mycircle 233,343,12;
Textout "text",23,23,"2";
# end
when i run the program, the user pinputted codes should be mapped with the vc+++ Line,Circle,Textout routines with app.parameters provided by the user.
suggest me an idea to solve this..
with regards,
Mahes
|
|
|
|
|
take a look and read further:
http://www.antlr.org/
¡El diablo está en mis pantalones! ¡Mire, mire!
Real Mentats use only 100% pure, unfooled around with Sapho Juice(tm)!
SELECT * FROM User WHERE Clue > 0
0 rows returned
|
|
|
|
|
Hello everyone,
I've got quite some problems with programming a Context Menu Handler in
Visual C++ (6.0, SP5) under Windows 2000.
I am German and an apprentice, which means I am spending half the time in school and half the time in the company that hired me as an apprentice.
I am studying to become an application developer.
Until now, I only wrote basic C and some more advanced Java Code. A few
days ago, I received a new project:
I should create a context menu entry (submenu with 2 or more menu items). Selecting one of these entries should start the corresponding application.
I read several "Context Menu"-Pages until I found out that, in order to have a sub-menu, I would have to write a COM-DLL, a "context menu handler".
Reading on that topic in the MSDN did not help me much, as I have not programmed (in the?!) COM yet.
I then stumbled upon Michael Dunns "The Complete Idiot's Guide To Writing Shell Extensions" and downloaded his example projects.
Well, it did not work. The example projects were compiled (0 errors, 0 warnings), registered (regsvr32 dllname -> Registration Successful) and written into the registry (shellex->ContextMenuHandlers), mostly as scripted in the RGS-File of the project.
I tried several of the example projects, none worked. The context menu - even though the handler is registered for the filetype - does not change or give the desired new options.
I am a local administrator, but I even wrote the GUIDs to the APPROVED section as described in M. Dunn's first chapter. Well, they still dont work, and I am pretty much *censored* since I can not get it to work.
I do have absolutely no idea what causes the failure, I did not change any of the example projects.
Can someone please help me?
Greetings from Germany
Sebastian
|
|
|
|
|
I create a mfc mdi app without doc/view.I meet a question.
I declare a int point member in cchildframe.
when I new(int) it in CChildFrame::OnCreate() or in Constructor,it does well.I free it in destructor like this
{
if(p)
{
delete p;
TRACE(_T("delete p\n"))
}
}
but if I new it in CChildFrame::PreCreateWindow(),it reports
detected memory leaks,instead I observer the trace message,I think I have delete it,but why error yet generated.I hope somebody can explain it to me.thanks
|
|
|
|
|
Memory leak means that there are non-freed memory after the app has ended. I think that the only reason is, that the framework calls PreCreateWindow more than once. Anyway, the PreCreateWindow is designed mainly to set the window class and you shouldn't initialize anything there
Robert-Antonio
"I launched Norton Commander and saw, drive C: on the left, drive C: on the right...Damn, why I need two drives C:???So I formatted one..."
|
|
|
|
|
I am very new in visual C++ some body can tell me how I can change the font size. For me I just want are simple change the font size like click button 1 and then come out the word on editbox is Times New Roman and size is 16.
Thank you.
|
|
|
|
|
|
hi all...
I have question...
How can i have a multi column list box in a dialog ???
Any help is appreciated
thanks
saleem
|
|
|
|
|
Read up on LBS_USETABSTOPS and LB_SETTABSTOPS .
--
Dad, how strange it is that the pig can speak. *thoughtful pause* It must have lost its "oink". (my 3-year old daughter Moa, while watching Babe)
Human beings, who are almost unique in having the ability to learn from the experience of others, are also remarkable for their apparent disinclination to do so. (Douglas Adams)
|
|
|
|
|
do this :
sockaddr_in ReceiverAddr;
ReceiverAddr.sin_addr.s_addr = ADDR_ANY;
TOXCCT alias Nicolas C.
|
|
|
|
|
Okay....let's say I want to give the recipient IP address as "172.20.144.50". How do I include this statement in the program?
The program is as follows:
#include <winsock2.h>
#include <stdio.h>
void main(int argc, char **argv)
{
WSADATA wsaData;
SOCKET SendingSocket;
SOCKADDR_IN ReceiverAddr;
int Port = 5150;
int Ret;
if (argc <= 1)
{
printf("USAGE: udpsender <receiver ip="" address="">.\n");
return;
}
// Initialize Winsock version 2.2
if ((Ret = WSAStartup(MAKEWORD(2,2), &wsaData)) != 0)
{
// NOTE: Since Winsock failed to load we cannot use WSAGetLastError
// to determine the error code as is normally done when a Winsock
// API fails. We have to report the return status of the function.
printf("ERROR: WSAStartup failed with error %d\n", Ret);
return;
}
// Create a new socket to receive datagrams on.
if ((SendingSocket = socket(AF_INET, SOCK_DGRAM, IPPROTO_UDP))
== INVALID_SOCKET)
{
printf("ERROR: socket failed with error %d\n", WSAGetLastError());
WSACleanup();
return;
}
// Setup a SOCKADDR_IN structure that will identify who we
// will send datagrams to. For demonstration purposes, let's
// assume our receiver's IP address is 136.149.3.29 and waits
// for datagrams on port 5150. Obviously you will want to prompt
// the user for an IP address and port number and fill these
// fields in with the data from the user.
ReceiverAddr.sin_family = AF_INET;
ReceiverAddr.sin_port = htons(Port);
ReceiverAddr.sin_addr.s_addr = inet_addr(argv[1]);
|
|
|
|
|
you said it... if the address is given through the command line, that's this :
ReceiverAddr.sin_addr.s_addr = inet_addr(argv[1]);
assuming the IP is a correct adress...
TOXCCT alias Nicolas C.
|
|
|
|
|
I want to tell the program the receipient IP address....if not the program will not work.....it will execute till the printf statement " USAGE: udpsender <receiver ip="" address="">."
I have yet to modify the program with the IP address I want it to be.....
The rest of the statement won't be executed....
Also I need to put in the receipient IP address 172.20.145.45 so that I can transfer data from one PC to the other PC.....
I cannot just assume the IP is correct....
|
|
|
|
|
Actually i am developing a class in which it will take any com object and will be able to set and get the properties. Now i have taken the clsid of the component. Now how can i get its properties as GetIdsofNames function of IDispatch takes names. Please Guide me briefly with a little example or tell me some article
Thanx in advance
Regards
minamkhan
Inam
|
|
|
|
|
I am writing a program that interfaces with Flight Sim 2002 and 2004. I am writing this in .NET VC++ 7. I have one 100ms timer, and I am currently testing the program with only one funtion call. Every 100ms if a few variables are met the program accelerates the aircraft (writes a new velocity value to FS). That's the theory... in reality it only writes about once every 2-3 seconds or so. How can I make the program run faster, at a higher cpu priority, or whatever?
James Meade
vLT(jg) vUSN
vOPSOFF VAQ-140
|
|
|
|
|
Is the timer actually firing every 100ms? I'm not sure of the answer but if the timer is at fault you may try using a mm timer instead of the standard WM_TIMER..
Rob
Whoever said nothing's impossible never tried slamming a revolving door!
|
|
|
|
|
The timer fires fine when it is the only program running. When it has to share processor space with Flight Sim it fires UBER slow. It isn't flight sim or my pc because other add ons and program seem to respond normally. It has to be the default priority .NET assigns the program, which has to be LOW.
James Meade
vLT(jg) vUSN
vOPSOFF VAQ-140
|
|
|
|
|
The mm timer doesn't rely on Window Messages, I believe it's more hardware orented. Being that the system is busy with the Sim program windows may be dropping the WM_TIMER messages... I would consider looking into using the mm timer instead.. I have some used it in app's where the timer portion is critical..
You can find samples here on cp and on codeguru.. If you have any problems i can post some of my code..
(only bad thing is my examples are in VC++ 6.0 not .NET)
Rob
Whoever said nothing's impossible never tried slamming a revolving door!
|
|
|
|
|
Anyone can tell me when I already insert the PrinterPort.h and PrinterPort.cpp in the project.If I want to use the CONTROL PORT as my output similar with DATA PORT how I write the code as it can function like DATA PORT?
Thank You
|
|
|
|
|
Long back i had used some api to convert the file size in bytes in terms of KB,MB, etc
does any one remember that api.
Thanx in advance.
Regards,
Toughest Steel Comes From Hottest Furnance
|
|
|
|
|
//Replace NULL with a pointer to a variable that holds the high-order size
//if the file is larger than can be represented by a DWORD
DWORD bSize;
DWORD kSize;
DWORD mSize;
bSize = GetFileSize(hMyFile, NULL);
kSize = bSize/1024;
mSize = kSize/1024;
Sorry; couldn't find anything else.
Heard in Bullhead City - "You haven't lost your girl - you've just lost your turn..." [sigh] So true...
|
|
|
|
|
humm, thanx any way for replying actualy this is not what i was looking for,
suppose x = 1025
then there is a function which gives the following ouput
CString t = somefunction(x); //t = "1 KB"
any way i made that function myself that does that.
Toughest Steel Comes From Hottest Furnance
|
|
|
|
|
StrFormatByteSize. Defined in shlwapi.h and requires linking to shlwapi.lib.
Wenn ist das Nunstück git und Slotermeyer? Ja! Beierhund das oder die Flipperwaldt gersput!
|
|
|
|