|
Correct. I was speaking in the general case, because if strncpy(...) is going to be used in this particular constructor, it is going to be used elsewhere as well, and knowing the limitations of the function are still important.
Peace!
-=- James If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong! Avoid driving a vehicle taller than you and remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road! DeleteFXPFiles & CheckFavorites (Please rate this post!)
|
|
|
|
|
A struct and a class are exactly the same, except for the default member access (public and private, respectively). So you can write a constructor for Stru_A just as you would if it were a class.
|
|
|
|
|
Hi,
I've got a combobox that I'm populating values in this order:
AlphaEntry
6020
Now, when the combobox displays, it reverses the value like this:
6020
AlphaEntry
What gives?
I should add, these names are the text filenames of binary files loaded at runtime. I'm NOT setting these values at design time.
|
|
|
|
|
You have to remove the CBS_SORT style (it is a default value, at design time).
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
|
|
|
|
|
Hrm, how can I crawl out of here without anyone seeing me?
|
|
|
|
|
Don't worry about...
Such moments happen to everybody and usually you expect to find things as you leave them.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
|
|
|
|
|
there's a CComboBox style(CBS_SORT) option when creating the combobox, be certain that it's not there when you create it.
|
|
|
|
|
Maximilien wrote: be certain that it's not there when you create it.
Actually it is the default on Visual Studio resource editor.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
|
|
|
|
|
Like2Byte wrote: 6020
AlphaEntry
What gives?
6 has an ASCII value of 54, while A has an ASCII value of 65. That's why 6020 precedes AlphaEntry.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Yeah, this I *do* know.
|
|
|
|
|
Hi everyone,
does exist a event or something like this that informs that the Frame is now maximized.
Because during the Maximization of the Frame, more than one OnSize-Event occurs.
Now i need a indice that the maximization is over and i can perform my actions...
Does any one have an idea?
Big thanks for your help
|
|
|
|
|
have a look to GetWindowPlacement .
Hope that helps.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
|
|
|
|
|
It has each times (3x) the same value (SW_SHOWMAXIMIZED)
nervertheless thanks
|
|
|
|
|
In a pinch, I would set a short (25ms or so) timer each time the OnSize/Maximize event fires, resetting it and recreating it for each event, and when the last event comes in, the timer will then fire.
Just a Q&D solution...
Peace!
-=- James If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong! Avoid driving a vehicle taller than you and remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road! DeleteFXPFiles & CheckFavorites (Please rate this post!)
|
|
|
|
|
I've also think about it, with a timer/delay
If it's really the last possibility, so i must realise it in this way.
So, thanks to you too
|
|
|
|
|
How do you discovered that OnSize happens many times?
I made an attempt on my dialog, seeing it (the handler wrote to log file its parameters) only once.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
|
|
|
|
|
With breakpoints or Messagebox that report a "I'm in OnSize"
And if the debug pauses, i can see that the Size-Messages are coming from the system, not from a self-written function.
2 On-Size-Event of the Frame executes also a OnSize on the View
And a 3-time on the Frame ( without a OnSize on the view )
Each OnSize on the View, a grid will be redimensioned and rows added/removed relative to the height of
the view. Propably the Size-Messages are coming from the Grid.SetWindowPos
I'm the only person that programms on MFC at the office, so i must ask each question here
And to change from Visual C# to MFC is a hard way where everybody has a lot of questions
I even don't know if my style of MFC-Programming is correct
|
|
|
|
|
baerten wrote: With breakpoints or Messagebox that report a "I'm in OnSize"
This is wrong way to track messages. Use log as suggested in earlier reply.
|
|
|
|
|
Ok, i inserted a logfile to the handler, the same procedure ...
more than 1 OnSize-Event for maximizing
Thanks nevertheless at all
|
|
|
|
|
Hi guys, there is an easy way from C++ to make the same as when in a web page you click on a button an a New Mail (from outlook express) appears with a preselected adress on it?
Do you know an example of this?
Thanks and Merry Christmas.
|
|
|
|
|
doctorpi wrote: Hi guys, there is an easy way from C++ to make the same as when in a web page you click on a button an a New Mail (from outlook express) appears with a preselected adress on it?
ShellExecute(hWnd, "open", "mailto:doctor@pi.com", ...);
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Thanks a lot.
mailto doesn't admit attachments?
|
|
|
|
|
|
Hello, everyone.
You may consider this question odd, but it is what I'm thinking of, should I learn C++ after C#?
I'm self-taught C# developer. During the last two years I made lots of work learning and using C#. Mainly, I played a role of ordinary team player or worked alone.
Sometimes I had performance issues and somebody of C++ guys helped me to workaround. (Envy was my feeling at the moments)
Now, my experience with C# is broad and strong. I try to get a job of senior developer, but unfortunately very often the requirements are C++\C#, and If you do not have native C++(not CLI) skills, you are out of the board.
I think they want native C++ just in case, even if projects really go under dot net.
Is it worth to learn C++ after C# ? If You have the same, could you share your experience?
Does it mean evolution of prof. skills or whim?
I've started C++, and after C# it seems to me very tough, especially class templates and pointers (together ). I suffer from low productivity as compared with C#.
Thank You.
Alex
|
|
|
|
|
C++ and C# are different things. C# is easier to understand with a C++ background (personal opinion though).
It is always worth learning a new langage, if you have time to spend (otherwise it is a waste, do not expect to understand C++ in less than a week) and a clear target as for why you would do it (which you have since you are targeting senior developer jobs where this is a requirement). Then go for it.
On the other way, I do not exactely see why senior developer would need to know both C++ and C#, unless for "porting" activities. I do not really see the win in being good at C++ for programming in C#.
~RaGE();
I think words like 'destiny' are a way of trying to find order where none exists. - Christian Graus
Do not feed the troll ! - Common proverb
|
|
|
|