|
thanks Russell, i will try it as your suggestion!
|
|
|
|
|
good luck
Russell
|
|
|
|
|
I want to add picture in mydialog box for wallpaper as is in the case of Webshots. Anyone tell me which control to use along with the code and functions.
Please help me.
Thanks In advance.
Dhiraj
Dhiraj Kumar Saini
|
|
|
|
|
draw it during CDialog::OnEraseBkgnd
Russell
|
|
|
|
|
Have a look at this site[^], just search for the dialog component on the window.
Regards,
The only programmers that are better that C programmers are those who code in 1's and 0's
Programm3r
My Blog: ^_^
|
|
|
|
|
Load your image with CImage class or LoadImage function and then use of WM_ERASEBKGND event.
|
|
|
|
|
Does he need to search on the www.functionx.com while we have www.codeproject.com?;)
|
|
|
|
|
its not clear can you just send me the code
Please and let me tell you i am using Picture Box control and it is mfc application and not win32.
Thanks
Dhiraj kumar Saini
|
|
|
|
|
As has been said, have a look in the dialog section here on codeproject - you'll find many articles on the subject. If browsing the website and looking at pictures on articles is too hard for you, then it's not fair to expect others to put in more effort.
Iain.
|
|
|
|
|
If you are using a control like CStatic see this code
CImage m_Image;
m_Image.Load(yourimage);
m_Control.SetBitmap(m_Image.Detach());
|
|
|
|
|
I am using MFC and not ATL so CImage is undeclared identifier.
Dhiraj
|
|
|
|
|
So you can use of OleLoadPicture and for use of this function see articles about it on the codeproject.
|
|
|
|
|
I am using a list control in my dialog box whose id is IDC_LIST1 and now i want that oninitdialog function the width of the columns should be fixed and
then we have to insert a checkbox into the column,
Please help me.
Thanks in advance.
Dhiraj
Dhiraj Kumar Saini
-- modified at 6:29 Monday 17th September, 2007
|
|
|
|
|
look at this...
http://www.codeproject.com/listctrl/ReportControl.asp
Sreedhar DV
[Real success is having courage to meet failure without being defeated.]
|
|
|
|
|
|
|
To get inlining to work you generally need to implement the function in the header file. i.e. no separate declaration and definition, all in one like:-
in file.h
<br />
inline double foo()<br />
{<br />
}<br />
Note that there are numerous reasons why the MS C++ Compiler might refuse to inline or auto inline functions without being asked not all of which are even publicly documented. There is no way to gaurantee inlining even using __force_inline the compiler can still ignore the instruction. Also inlining tends to disappear in Debug builds as compared with Release so it's difficult to prove whether it's happening or not wihtout examining Release code at the assembly level. Any kind of instrumentation or leaving debug information in is quite likely to alter the compiler's inlining decisions anyway. Microsoft's take is basically truct the compiler and don't worry about it.
Nothing is exactly what it seems but everything with seems can be unpicked.
|
|
|
|
|
Matthew Faithfull wrote: all in one
you are right!
I need to check!
Matthew Faithfull wrote: __force_inline
I was also looking to __fastcall ...
I have a lot of small functions that are there only to let the code be more readable...but I need at the same time high performances.
Many of them are some simple wrappers to other functions, inline looks necessary.
Thanks for your time;)
Russell
|
|
|
|
|
Russell` wrote: Many of them are some simple wrappers to other functions, inline looks necessary.
if you really want them to be inlined, you can always use simple #define macros.
|
|
|
|
|
it is true!
Thanks;)
Russell
|
|
|
|
|
I use inline only in the header part of a function. Often I see code where inline-functions are completely in the header implemented.
"inline" is also an optimization option. If optimization is important it is better to proof the quality of code, for instance function calls in loops (!!!), temporary objects ...
Greetings from Germany
|
|
|
|
|
AFAIK, inline is only a compiler hint. The compiler can decide to everride the inline.
see this at msdn[^]
|
|
|
|
|
Russell` wrote: I like to use inline as often as possible
Just be sure to read this excellent article[^] before that.
|
|
|
|
|
I created dialog bar in CHtmlView SDI application by clicking rebar application.
But whatever buttons I placed on that bar remain disabled. Even if I tried using
only style WM_VISIBLE in precreate window. Or m_dialogbar.EnableWindow(true);
or GetDlgItem->(IDC_BUTTON1)->EnableWindow(true); . The buttons remain disabled.
How to use it. I just want editbox URL to be navigated on button click,and simple back ,front buttons.
|| ART OF LIVING ||
|
|
|
|
|
I think that you need to add ON_UPDATE_COMMAND_UI and/or ON_COMMAND message map entries for the command IDs for the controls on the dialog bar, same as you would normally do for a toolbar or for menu items.
See if adding an ON_COMMMAND entry for IDC_BUTTON1 helps.
Peace!
-=- James Please rate this message - let me know if I helped or not!<HR> 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! See DeleteFXPFiles
|
|
|
|