I want that a default field to be placed, that user may not able to enter value and it must have a default value in that box.
As suggested by Arjay you should use resource editor if you are not using express edition.
And for setting some default text to edit box use ::SetWindowText api.
And for disable user to edit that you can disable the edit box by ::EnableWindow(hEdit, FALSE)
well guys I am newbie in MVC, so I am in learning process.
as far as you both suggested, I appreciate your concern.
But I am in puzzle, my friend has given me this task as challenge [bcz I accepted it :S]
and I dont know what you just mentioned:
And for setting some default text to edit box use ::SetWindowText api.
And for disable user to edit that you can disable the edit box by ::EnableWindow(hEdit, FALSE)
PLEASE ELABORATE IT LIKE A TUTOR!
btw, I got resource editor, having dialogue edit screen on here, but dont know how to do that!
well guys I am newbie in MVC, so I am in learning process.
as far as you both suggested, I appreciate your concern.
But I am in puzzle, my friend has given me this task as challenge [bcz I accepted it :S]
and I dont know what you just mentioned:
PLEASE ELABORATE IT LIKE A TUTOR!
btw, I got resource editor, having dialogue edit screen on here, but dont know how to do that!
This board will help you when you're stuck with specific problems. It's not intended to take the place of a class or tutorial. The bookstore is full of books that will explain the fundamentals. Work through one of them and get a basic understanding then post back. You can't possibly learn to program by asking such basic questions as how to use the resource editor, nor is it reasonable of you to expect somebody to write such a tutorial when so many of them already exist.
I didn't say don't post. I said don't expect somebody to write a tutorial for you. If you really want to learn, the best thing to do is work through a book. That's sound advice, and substantially more useful than just telling you not to post. Seems like your expectations are a little off is all.
I didn't say don't post. I said don't expect somebody to write a tutorial for you. If you really want to learn, the best thing to do is work through a book. That's sound advice, and substantially more useful than just telling you not to post. Seems like your expectations are a little off is all.
GCDEF is right on - it's not about 'not posting', it's about approaching the learning in the most efficient manner.
If we thought that helping you every little step of the way was going to get it done, many of us would do it. The fact is that at the beginning of learning a language, you need to put the time in to learn the basics. Short of taking a class, no one can really help with that. If you can't take a class the next best thing is to find an online tutorial and start working through it.
As GCDEF has already mentioned, as you encounter issues when working through the tutorial feel free to post specific questions.
well if this is the case, then you guys might help in below situation!
I am trying to give a default value for a program to run, for this I have changed the edit control field into static control field in resource editor.
but when I run the program, it shows the default field as read only but not showing the actucal value that I have given.
I think I am putting the caption value to this, NOT the actual value!
if this is correct, then help me atleast NOW!!!
STOP SHOUTING DEMANDS!!!! That isn't going to help.
Part of the problem is you don't even have the terminology down to explain yourself properly. What does "default value for the program to run" mean? What does "putting the caption to this" mean? What does " default field as read only but not showing the actucal value that I have given" mean? Shows it where?
well if this is the case, then you guys might help in below situation!
I am trying to give a default value for a program to run, for this I have changed the edit control field into static control field in resource editor.
but when I run the program, it shows the default field as read only but not showing the actucal value that I have given.
I think I am putting the caption value to this, NOT the actual value!
if this is correct, then help me atleast NOW!!!
In MFC (not MVC as mentioned earlier), what you want to do is to create a value variable by right clicking on the edit or static control in the resource editor and choose "Add Variable". Under Category:, choose 'Value'. For variable type, choose 'CString'. Give the variable a name and press OK. In OnInitDialog, set the variable that you created to the string that you desire.
In picture, you will find BEFORE and AFTER difference!
Now I am trying to put WWW.EXAMPLE.COM for ID#1005 in that whatever you call that thing, field, area, input box, control box... which is not visible in AFTER picture!
I am not here to determine myself!
Thank you so much ARJAY for that you understood my language!
the thing is that I am not a programmer like you people, I am webdeveloper and I have a project to complete, in which making of this program is attached, which just logins user and shows his account for a perticular domain, thats all!
I have made 90% of the program by the help of google! rest of % is currently on this forum!
regret to state here but here I found some people, who want others to be like them!
So, if I understand you correctly, you want the phrase "www.example.com" to appear in the grayed-out (read-only) edit box labeled "Domain". Is that correct?
Have you tried setting initial text for any of the other edit boxes on the dialog? Have you tried removing the ES_READONLY style?
I don't know anything about how to fix your problem. I've just found that sometimes it helps me to try to do the same thing in slightly different ways until I find one that works.
Also, could you please tell us what compiler and development environment you're using? That is, are you using Microsoft Visual Studio 2005? 2008? 2010? Something else entirely?
* The Best Reasons to Target Windows 8
Learn some of the best reasons why you should seriously consider bringing your Android mobile development expertise to bear on the Windows 8 platform.