|
Hi
How to change row height in owner draw CListCtrl
which has Report View ?
--
NodeX
|
|
|
|
|
WM_MEASUREITEM probably...
Cheers!
"An expert is someone who has made all the mistakes in his or her field" - Niels Bohr
|
|
|
|
|
HockeyDude wrote:
WM_MEASUREITEM probably...
I try it, but this event never occured.
NodeX
|
|
|
|
|
To receive that message, it has to be owner drawn. Which also means you have to implement the WM_DRAWITEM and other messages.
Tim Smith
I know what you're thinking punk, you're thinking did he spell check this document? Well, to tell you the truth I kinda forgot myself in all this excitement. But being this here's CodeProject, the most powerful forums in the world and would blow your head clean off, you've got to ask yourself one question, Do I feel lucky? Well do ya punk?
|
|
|
|
|
Hi !
I am Ergin. I've been building a database program using CFormView. Now I need to get rid of the scroll bars but I can't. I mean I don't want it to be resizable or scrollable (I want fixed). I couldn't do that.
And as a second one I have a CTabCtrl inside and when I put a picture behind it , it ends up in the middle of the CTabCtrl. I think Tab is a hollow control. How can I correct this ??
If you answer I will be very pleased. Tomorrow I have to show the program off but still I couldn't finish it.
byeeee
|
|
|
|
|
Anonymous wrote:
Now I need to get rid of the scroll bars but I can't.
check windows style in MSDN.you have to add code in your create function of mainframe
Mazy
"So,so you think you can tell,
Heaven from Hell,
Blue skies from pain,...
How I wish,how I wish you were here." Wish You Were Here-Pink Floyd-1975
|
|
|
|
|
If the scroll bars are appearing automatically, it is likely that your dialog resource is larger than the default frame client area size.
Add a handler for the WM_GETMINMAXINFO in the CMainFrame class. You can then specify the min and max size for your windows.
<br />
void CMainFrame::OnGetMinMaxInfo(MINMAXINFO FAR* lpMMI) <br />
{<br />
lpMMI->ptMaxSize.x = 700;<br />
lpMMI->ptMaxSize.y = 500;<br />
lpMMI->ptMaxTrackSize.x = 700;<br />
lpMMI->ptMaxTrackSize.y = 500;<br />
lpMMI->ptMinTrackSize.x = 700;<br />
lpMMI->ptMinTrackSize.y = 500;<br />
CFrameWnd::OnGetMinMaxInfo(lpMMI);<br />
}<br />
Michael
|
|
|
|
|
A quick way to remove the scroll bars is in the OnSize handler for the form view is to call:
SetScaleToFitSize(cx, cy) ;
You may also need to r-size any controls to porperly fit on the form.
As for the bitmap appearing in the middle of you tab control, check the tab order of the control in the resource editor (CTrl+D) and make sure that he bitmap is before the tab control to get he correct plot order.
Roger Allen
Sonork 100.10016
If I'm not breathing, I'm either dead or holding my breath.
A fool jabbers, while a wise man listens. But is he so wise to listen to the fool?
|
|
|
|
|
Hi,
I just created an app using VC++ and I think it needs a little spice so, I want to include graphics in my app, how can I put an image in the background (not 16 colors, 256+) like in msn messenger. I would like an image and I could put my controls on top of it. Actually when I do that today, my bitmap takes the whole place and all the controls are under it. And also, I want to make my image fit the entire application canvas.
Help me if you can please.
// JS Paquet
cout << "Thank you all" << endl;
|
|
|
|
|
If you want to use GDI+ check this
Mazy
"So,so you think you can tell,
Heaven from Hell,
Blue skies from pain,...
How I wish,how I wish you were here." Wish You Were Here-Pink Floyd-1975
|
|
|
|
|
Use stretchBlt, and paint the image in the WM_ERASEBKGND message.
|
|
|
|
|
I have tried "SetMargin", but it seems for print process?
I'm amumu, and you?
|
|
|
|
|
First of all, my equipment:
************************************Win2k Server******************************
Name: iras
Workgroup: HTBL
Domain for Windows: htlpinkafeld.at
Domain for Netware: htbl\
User: testuser@htlpinkafeld.at (in htlpinkafeld.at\edvoschueler)
No Password!! (only for testing)
******************************************************************************
***********************************Win2kProf (Workstation)********************
Programming Language: Microsoft Visual C++ 6.0
MSDN: April 2001
Workstation is in the same network like win2k server (of course!)
******************************************************************************
First step:
BINDING TO AN USER (testuser@htlpinkafeld.at)
I read that i should use the function
HRESULT ADsOpenObject(
LPWSTR lpszPathName,
LPWSTR lpszUserName,
LPWSTR lpszPassword,
DWORD dwReserved,
REFIID riid,
VOID FAR * FAR *ppObject
);
To do so, i had to import the following:
Header: Adshlp.h
Library: ActiveDS.Lib
PROBLEM:
The 5th parameter takes values which are neither in Adshlp.h nor in ActiveDs.Lib. So!! I found out that the needed stuff is in another lib called
"ADSIID.lib". BUT some declarations are redefined in ADSIID.lib! Because the program needs this lib to work right i even can't let it be. Then i found out that this sometimes happens, god knows why!, and that i should insert the prefix "/force:multiple" into the menu project\settings\Link\"Project Options". I did so and the result was a list like the following, please don't scare:
Generating Code...
Linking...
LINK : warning LNK4075: ignoring /EDITANDCONTINUE due to /INCREMENTAL:NO specification
uuid.lib(guids.obj) : warning LNK4006: _DBGUID_SQL already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBGUID_DEFAULT already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBGUID_DBSQL already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBPROPSET_VIEW already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBPROPSET_PROPERTIESINERROR already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBPROPSET_DBINITALL already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBPROPSET_SESSIONALL already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBPROPSET_SESSION already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBPROPSET_ROWSETALL already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBPROPSET_DATASOURCEINFOALL already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBPROPSET_DATASOURCEALL already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBPROPSET_TABLE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBPROPSET_ROWSET already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBPROPSET_INDEX already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBPROPSET_DBINIT already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBPROPSET_DATASOURCEINFO already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBPROPSET_DATASOURCE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBPROPSET_COLUMN already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _PSGUID_QUERY already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOL_SPECIALCOL already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOL_SELFCOLUMNS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_PROCEDURE_COLUMNS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_PRIMARY_KEYS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_FOREIGN_KEYS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_PROCEDURE_PARAMETERS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_VIEW_TABLE_USAGE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_VIEW_COLUMN_USAGE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_VIEWS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_PROVIDER_TYPES already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_TRANSLATIONS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_TABLES already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_STATISTICS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_SQL_LANGUAGES already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_SCHEMATA already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_PROCEDURES already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_USAGE_PRIVILEGES already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_TABLE_PRIVILEGES already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_COLUMN_PRIVILEGES already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_INDEXES already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_COLUMN_DOMAIN_USAGE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_TABLE_CONSTRAINTS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_REFERENTIAL_CONSTRAINTS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_KEY_COLUMN_USAGE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_CONSTRAINT_TABLE_USAGE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_CONSTRAINT_COLUMN_USAGE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_CHECK_CONSTRAINTS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_COLUMNS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_COLLATIONS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_CHARACTER_SETS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_CATALOGS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_ASSERTIONS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _MDSCHEMA_MEMBERS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _MDSCHEMA_PROPERTIES already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _MDSCHEMA_MEASURES already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _MDSCHEMA_LEVELS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _MDSCHEMA_HIERARCHIES already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _MDSCHEMA_DIMENSIONS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _MDSCHEMA_CUBES already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBGUID_MDX already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _MDGUID_MDX already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBSCHEMA_TABLES_INFO already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_MAYSORT already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_CLSID already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_COLUMNSIZE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_OCTETLENGTH already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_NUMERICPRECISIONRADIX already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_DATETIMEPRECISION already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_DOMAINSCHEMA already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_DOMAINCATALOG already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_TYPEINFO already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_PROPID already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_GUID already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_BASESCHEMANAME already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_BASECATALOGNAME already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_ISUNIQUE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_ISSEARCHABLE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_ISCASESENSITIVE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_ISAUTOINCREMENT already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_HASDEFAULT already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_DOMAINNAME already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_DEFAULTVALUE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_COMPUTEMODE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_COLLATINGSEQUENCE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_BASETABLENAME already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_BASECOLUMNNAME already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_FLAGS already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_SCALE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_PRECISION already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_TYPE already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_NUMBER already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_NAME already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DBCOLUMN_IDNAME already defined in ADSIID.lib(guid.obj); second definition ignored
uuid.lib(guids.obj) : warning LNK4006: _DB_NULLID already defined in ADSIID.lib(guid.obj); second definition ignored
Debug/Authenticate.exe : warning LNK4088: image being generated due to /FORCE option; image may not run
Authenticate.exe - 0 error(s), 96 warning(s)
But it works; at the first glance!
I thought i can't go on; but wrong!
I dont't know how the first three parameters of the function
HRESULT ADsOpenObject(
LPWSTR lpszPathName,
LPWSTR lpszUserName,
LPWSTR lpszPassword,
DWORD dwReserved,
REFIID riid,
VOID FAR * FAR *ppObject
);
should look like! I have already watched the MSDN but the information in there isn't enough for me! Please help me!!!
|
|
|
|
|
Hey Guys
I have a function in a dll i call with rundll32.exe when i double click a file and i was wondering how i get the filename of the file that has been double clicked.
Cheers
Peter
|
|
|
|
|
Check:
CFile::GetFileName
Mazy
"So,so you think you can tell,
Heaven from Hell,
Blue skies from pain,...
How I wish,how I wish you were here." Wish You Were Here-Pink Floyd-1975
|
|
|
|
|
|
Yeah Thats exactly it
Thanks
|
|
|
|
|
I'm trying to make a little dialog to let the user search for a text string in a CEdit control on my main app's dialog. Like in Word or Notepad those kind of search windows. Does anyone have an idea on how to do this because i tried something myself and it didn't work at all (one of the reasons is that the CEdit::SetSel(...) didn't appear to work.)
Thanks
Kuniva
--------------------------------------------
God gave man a penis and a brain but not enough blood to make both of 'em work at the same time.
|
|
|
|
|
Kuniva wrote:
i tried something myself and it didn't work at all
It's better to mention what did you do
Kuniva wrote:
search for a text string in a CEdit control
Why don't you change it to RichEdit control,
it has more feature for text.
Mazy
"So,so you think you can tell,
Heaven from Hell,
Blue skies from pain,...
How I wish,how I wish you were here." Wish You Were Here-Pink Floyd-1975
|
|
|
|
|
Hi,
I have a .icm file.I would like to retreive the contents of the tag whose signature is "desc".
Any idea?
Neha
|
|
|
|
|
I jus opened a few icm files. They are not text files. They contain binary data and the postition of the description kept changing file to file, so did the file size. I suggest that you do a search to figure out the icm internal structure.
Nish
It's seven o'clock
On the dot
I'm in my drop top
Cruisin' the streets - Oh yeah
I got a real pretty, pretty little thing that's waiting for me
|
|
|
|
|
I have some code for this that I d/led online somewhere, but it's at work. I'll post the link when I get back to the office on Monday.
Yeah I know, get a VPN right? Oops!
Jeremy L. Falcon
"The One Who Said, 'The One Who Said...'"
|
|
|
|
|
|
I have a need to do the following item and could use some help setting it up. I have a basic MFC application running that includes a prebuilt MFC dialog derived class for allowing the user to input data. this all works fine. I need, however, to allow the user to create their own MFC based dialog box, and then allow them to call that dialog box at runtime without the primary application being aware of the dialogs design. So what I have done is this...
in main app, when i select menu item 'test' it looks for a dll named 'testing.dll', and if it finds it, then it loads the dll, finds a function called Create() and attempts to run it. this works fine.
in the create() function, it is a simple test for now.
char gString[255] = "";
void Create()
{
CMyDialog d;
if (d,DoModal() == IDOK)
strcpy(gString,"everything worked fine");
}
all of the exporting works fine, it does loading the dll, finding the create function, retrieving the gString variable etc... the only thing that doesnt work as expected, is in the DoModal() call of the dialog class. the dialogbox appears, and then the entire program crashes. This doesnt happen if i create a simple dialog box that is not CDialog derived.
Am I missing something on MFC? is there an issue with trversing a dll boundary with the MFC.
thanks in advance for any info.
|
|
|
|
|
Anonymous wrote:
CMyDialog d;
if (d,DoModal() == IDOK)
strcpy(gString,"everything worked fine");
This won't work.
You have not associated a dialog resource. Without doing that DoModal() will fail.
Nish
It's seven o'clock
On the dot
I'm in my drop top
Cruisin' the streets - Oh yeah
I got a real pretty, pretty little thing that's waiting for me
|
|
|
|