|
Hi
does anyone have any sample code for firing up outlook 97 (and say sending an email)
from vc6.0 using #import msoutl8.olb and mso97.dll
rather than using the class wizard to add _all_ those classes ?
as i dont seem to be able to make it work
can someone suggest something? (other than updating to office 2000)
regards
Bryce
|
|
|
|
|
Can you use MAPI? There is some code here[^] that I have used to send email with OE, but I assume that if Outlook was set up as your MAPI client that it would use that instead.
"Quand tu sèmes ta haine
tu récoltes la Kalachnikov Love"
-Kalachnikov Love, Alpha Blondy
|
|
|
|
|
nope, can't guarentee they have it seup that way
and need to show the new email window etc
cheers for the thought though
Bryce
|
|
|
|
|
Hi,
I do a thumbnail app and use the standard Listview. My thumbs are 100x100 (that's 40 kb each at 32 bit, which they are). I have tried to load a directory with over 330 images (about 13 mb), but the ImageList_Add function fails... I can't even figure out at which item, because (256 MB RAM/700 Mhz) I can't walk the code (it hangs the computer), when trying to write to a string and display it via messagebox, it hangs, all I can do is a messagebox saying "error", otherwise, in hangs the computer (mouse is moving, but not changing, nothing clickable, no keyboard). So, my question: is this normal or is there fault somewhere on my side (can the imagelist take any number of data?) Any workarounds (I got some ideas already, but would need a lot of code rewritting).
PS: I have to mention it works fine for ie. 30-40 files and that I try to do my best freeing the resources and that I've set the number of items to be exactly the number of files in the directory.
|
|
|
|
|
if there's a limit, it's at least 773 items
i have an app that shows 100x100 thumbnails in a list control and i was able to add 773 of them before i got bored. (Win2K, 512MB, performance meter showed very little memory usage)
-c
Conservative:
One who admires radicals centuries after they're dead.
-- Leo C. Rosten
|
|
|
|
|
A technique I used was to keep each bitmap separately and only have an imagelist with one entry. Then I switched the listview to owner data. When the control requests the text for each item I replace the bitmap within the imagelist. It works, trust me.
Joel Lucsy (jjlucsy@ameritech.net)
|
|
|
|
|
|
98... could you tell me more? It's sort of cruical thing for me right now... or where to get info.
Thanks for the other replies, maybe I could try the ownerdata thing ...
|
|
|
|
|
Btw. I cannot find the owner data style anywhere (nor searching the MSDN gives any suitable results). How can I do that? I've seen it somewhere before, but couldn't find it now
|
|
|
|
|
It's not a style. Each of the common controls that handles multiple items lets you associate a 32 bit value with each item, called the 'ownerdata' for the item. Generally, this is a pointer to a data structure within the application that contains more information about the item. For an example, look up the LVITEM structure in MSDN, for list-view items.
Gary R. Wheeler
|
|
|
|
|
GDI in Win 9x still has lots of 16-bit limitations since it is 16-bit code (necessary to retain Win16 compatibility). Thus it has lots of limits like 64K heaps, 16K max window handles, 32K max items in a list box, etc. When you load up hundreds of bitmaps, you eventually exhaust all the GDI resources. And due to the 16-bit limitations, you hit that limit rather quickly. You can monitor the GDI resources with the System Resource Meter (I think that's the name).
The solution is just to not keep all those bitmaps in memory at once.
--Mike--
Just released - RightClick-Encrypt v1.3 - Adds fast & easy file encryption to Explorer
My really out-of-date homepage
Sonork-100.19012 Acid_Helm
|
|
|
|
|
I created a menu resource IDR_MYCONTEXT, and its got a submenu and a subsubmenu (nothing weird). I did and got the messagebox and a subsequent crash!
void CTrain1View::OnContextMenu(CWnd* pWnd, CPoint point)
{
CMenu menuPopup;
if( rcTHBImage1.PtInRect(point))
{
AfxMessageBox("in");
menuPopup.LoadMenu(IDR_MYCONTEXT);
menuPopup.GetSubMenu(0)->TrackPopupMenu(TPM_RIGHTALIGN, point.x, point.y,this);
}
However this works(but I dont get the menu I want of course!)
<pre> CMenu* pMenuTrackPopup;
pMenuTrackPopup = ((AfxGetMainWnd())->GetMenu())->GetSubMenu(0);
pMenuTrackPopup->TrackPopupMenu(TPM_RIGHt,point.x, point.y,
AfxGetMainWnd(),
NULL);
}
I am doing something wrong! What though?
Thanks,
ns
|
|
|
|
|
Did u check if the LoadMenu is returning TRUE? TrackPopupMenu?
Papa
Murex Co.
while (TRUE)
Papa.WillLove ( Bebe ) ;
|
|
|
|
|
This is so bizarre. I made a new menu resource and (identical!) this one worked with no problem so I got rid of the other.
Thanks,
ns
|
|
|
|
|
Very cool!
Papa
Murex Co.
while (TRUE)
Papa.WillLove ( Bebe ) ;
|
|
|
|
|
One last try to see if anyone knows how to deal with this. I'm trying to use this function using VC.Net with MFC, but theres a big problem, parameter 2 is never recognised by the compiler Its defined as an enum in afxinet.h but it won't accept any of these values
Has anyone any idea of how to get this working because its driving me loopy I'm needing it so I can use commands other than the basic ones wininet offers such as LIST and PASV.
Thanks
|
|
|
|
|
How does one add a new field or delete an existing one from a database on the fly? I am using ADO with _recordsetPtr etc.
Thanks,
ns
|
|
|
|
|
U just have to send the correct SQL to the DataBase :
To delete LastName Field from Persons:
DELETE FROM Person WHERE LastName = 'Rasmussen'
To insert into table Persons a lastname and an adress:
INSERT INTO Persons (LastName, Address)
VALUES ('Rasmussen', 'Storgt 67')
Papa
Murex Co.
while (TRUE)
Papa.WillLove ( Bebe ) ;
|
|
|
|
|
What I meant is, I want to add or remove an entire column, not just the values for a particular record. So the field vanishes for all the records, or appears for all the records. Sorry I wasnt clear...
thanks,
ns
|
|
|
|
|
Then what u need is to send this SQL:
ALTER TABLE table_name
DROP COLUMN column_name
And that is that!
Papa
Murex Co.
while (TRUE)
Papa.WillLove ( Bebe ) ;
|
|
|
|
|
in order to add a column:
ALTER TABLE table_name
ADD column_name datatype
eg:
To add a column named "City" in the "Person" table:
ALTER TABLE Person ADD City varchar(30)
Papa
Murex Co.
while (TRUE)
Papa.WillLove ( Bebe ) ;
|
|
|
|
|
Truly aopreciate it. Hopefully my execute statement wont choke. For example, I cant get past a crash when i do an insert into in an execute statement. Its really frustrating! I pConn->Execute or PCommand->Execute or even pRecordset.OPen(pCommand,...) All three crash. SO hopefully your sql wont crash. ANy ideas why?
If you are into SQL and db, can you point me to some Working code for addnew or insert into? Theres tons of stuff out there - nothing works. AT best addnew() works, says recordcount is increased, but no records added to the db are visisble. The rs is lockoptimistic and adkeyset. It can edit just fine, but not add..
Thanks,
ns
|
|
|
|
|
I have create application with RichEdit and AutoURLs detection. Application work fine on Windows 2000, but under Windows NT links not works... Why?
Pavel Sokolov,
CEZEO software,
LanTalk Network,
http://www.cezeo.com
http://www.lantalk.net
|
|
|
|
|
Are you using RichEdit 2.0 (riched20.dll) on the NT machine?
"Quand tu sèmes ta haine
tu récoltes la Kalachnikov Love"
-Kalachnikov Love, Alpha Blondy
|
|
|
|
|