|
Can u send me this code ?
My e-mail: solo@dore.miem.edu.ru
|
|
|
|
|
#include <stdio.h>
int i = 7;
//The above i can be accessed using the global namespace
//:: Operator
void main()
{
int i = 10;
{
int i = 15;
{
int i = 17;
printf("%d\n",i);
//How to Access The Remaining i's here in c and c++
}
}
}
//The above variables have to be defined at the above point
|
|
|
|
|
you can't. the global i hides all of the other i's.
use different names.
-c
|
|
|
|
|
In C you can only access the local i within your block of code (equal to 17).
In C++ you can access the local i AND the global i (equal to 7). To access the global i, you'd use the scope resolution operator ( :: ) like this:
printf("%d\n", ::i);
Regards,
Alvaro
|
|
|
|
|
Looking for a c based or at a gasp c++, but prefer c, code to implement a category data structure ie
struct tagCATEGORY {
TCHAR szCategory[CATEGORYSTRINGLEN];
WORD wCategory;
} CATEGORY, FAR * LPCATEGORY;
yada yada ... Any thoughs for implementation code to copy paste and amend, best sorting methods, how to do etc thanks in advance
Andrew
|
|
|
|
|
Does anyone know a way to have colored text for a simple HTML editor in Visual C++? I need it to be colors that can be changed by the user from an options dialog so there should be some easy way to change the colors from the code. The basic framework for my application is going to be the standard text editor from the MFC app wizzard. Can anyone help me? E-Mail me and maby I can explain my problem a little bit better.
Thanks alot,
Jeff
|
|
|
|
|
Check the crystal syntax coloring editor by Andrei for this,
located at
http://www.codeproject.com/editctrl/crysedit.asp
You may also check the codeguru site for a startup html
parser to go with it, may need some modifications...
http://codeguru.earthweb.com/mfc/comments/2006.shtml
Need more? get in touch with the others.
Regards,
Paul.
|
|
|
|
|
There is a very good Open Source project which do that and
many other interesting things:
Scintilla and SciTE by Neil Hodgson, Look at:
http://www.scintilla.org
Hope this help,
Jran-Claude
|
|
|
|
|
hi,
anyone have any example or could tell me on how to implement browser helper objects and connect it to a running instance of IE and then if any url is lik test:// it should cancel the url and notify the app any ideas?
|
|
|
|
|
I'm making a NT-service, monitoring printjobs.
I have a small NTSERVER-WIN98 network. My server acts as a printerserver.
My problem is to retrieve the number of pages in the printjobs.
When I print from NT-server I can get the number through GetJob(), but when I print from WIN98 I cannot retrieve the number of pages (I get '0' each time).
Can somebody please help my out.
|
|
|
|
|
I'm trying a work out how I might redirect the output from a console app to a windows text box in VC++. Similar to when you compile and the output of nmake is shown in a docked window.
Does anyone have any ideas? I thought about using CreatePipe() and it's associated functionality. Is this right?
Many thanks for any help
|
|
|
|
|
Pipes are the easy way to do it. There are many sample codes
in the MSDN to show you how to. You can also take a look at
the following...
http://codeguru.earthweb.com/misc/redirect.shtml
http://codeguru.earthweb.com/misc/RedirectOutputToPipe.shtml
You need further help? get back.
Regards,
Paul.
|
|
|
|
|
I tried drawing a cloud(which can be edited also) using Arc, ArcTo, AngleArc with no fruits. Does anybody know the technique to draw a editable cloud? I know one thing it's just series of arcs, since it has to be with the rectangle and the angle of the arc varies I am finding difficult to find a good algorithm.
Need suggestion urgent!
|
|
|
|
|
A FAQ section for Question often asked in the disussion forum's.
Written for beginners.
I think this would be cool...
|
|
|
|
|
Hi,
i am looking for a listcontrol which enables to have multiline items. I tried to use the
NM_CUSTOMDRAW message according to Mike Dunn's article but i am still having problems
with selecting,editing and positioning the items.
Does anyboby have already done this?
TIA, Chris
|
|
|
|
|
Anyone know where I can get descriptions and/or implementations of classic game algorithms, e.g. checkers, backgammon, poker, pinochle, etc? I'm interested in collecting such algorithms into an open source collection.
Thanks,
Chris Sells
http://www.sellsbrothers.com
|
|
|
|
|
I do remember a book by an author from Princeton Univ. I think the title is "Algorithms in C++" from AW. The book is very abstract. We may have to make something out of it.
George
http://gpoulose.home.att.net/
|
|
|
|
|
I have made a custom CPrintDialog and I want touse it instead of the default one, without manage the whole printing process.
Can I tell MFC to use my dialog just before the beginning of the process?
Thanks, ...
|
|
|
|
|
Hi ,
I'm design and coding an expression Editor for mathematic terms like Microsoft "FormelEditor". Is there anyone, who has the same idea ?
|
|
|
|
|
Has anybody done this (VC++) ?
|
|
|
|
|
Hi,
I was wondering if anyone has a sample framework for a simple
installation application, i.e. a wizard-like dialog with next, previous
finish buttons. The dialogs should be very simple, merely getting some
simple input (strings) from the user. Btw; this is for NT4.0/Win2K.
Thanks,
Sverre Hjelm, eJournal AS
|
|
|
|
|
dear hackers this is for you
i tryed put this question at many programmers servers and sent mail about to microsoft
but noone knows and they ignore it/me
for my language (slovak) is (in all) windows bug in string comparing
(needs add something like vocabulary of exceptions)
so if i really need good sorting solution i can't use f.e. excel but i must
export data and use old good (dos) program
have anyone any idea how to hack/hook to it (into any windows)?
of where to start to find it? can be any com interface? is any spy for it? registry entry?
thanks for ideas
t!
added later because of possible misunderstanding:
i mean national-dependent string comparing possibly used in every windows application
when i try sort texts in excel with slovak language as a windows default language it in some cases not sorts correctly
in my language we have more letter than in english, take a example: a, long-a (line over character), width-a (two dots over character) etc. with another letters, biggest problem is that ch combination is sometimes taken as a one letter (in alphabet table: ... h ch i ...) sometimes as a c and h characters), microsoft it still takes as a ch-letter
i believe it is in any windows system dll but i do not know how to hook to it to improve this
|
|
|
|
|
There are specialized international sort functions that allow sorting of language dependant strings. It helps if you use unicode. Also sorting will be dependent on the underlying charset used. look up the CHARSETINFO struct
|
|
|
|
|
oops, maybe misunderstanding
i do not need how to call system string comparing function(s) but how to improve them
f.e. make in-ms-excel sorting working properly (for my language)
t!
|
|
|
|
|
how i can write a toolbar like Yahoo! Companion to my
intranet .
help ???
|
|
|
|