|
For some reason, I am not able to find any code (c++) on how to print from a Windows Form that has a richTextBox and a print button. Does any one point me in the right direction for some constructor code to input in the following:
private: System::Void button4_Click(System::Object * sender, System::EventArgs * e)
{
}
private: System::Void printDocument1_PrintPage(System::Object * sender, System::Drawing::Printing::PrintPageEventArgs * e)
{
}
RRL
|
|
|
|
|
I am learning Visual C++ .NET from a book. I made a dialogue and I don't know how to get the combo box list data values (i.e. Food, Clothes, Toys) to display. I put the values (Food;Clothes;Toys) in the data portion of the properties tab, and even made the relevant function (i.e. OnBnClick...), but I don't know how to get the list to display. Any help would be appreciated.
Thanks.
|
|
|
|
|
did you make the listbox big enough to dropdown while running it?
-prakash
|
|
|
|
|
Guys,
I'm getting the following error message when I try compile...
myHeader.h : error C3861: '_tcslen': identifier not found, even with argument-dependent lookup
I tried adding all the .h files that define this function, still not working , any thoughts ideas? am I suppose to include any LIB files?
The following is a list of files that I tried to include....
#include <string.h>
#include <string.h>
#include <mbstring.h>
#include <stdlib.h>
#include <strsafe.h>
-Cindy
|
|
|
|
|
oops I missed out the list of files
strsafe.h
string.h
mbstring.h
stdlib.h
Can someone pls tell me what I'm doing wrong????? Thanks
-Cindy
|
|
|
|
|
|
Hi
How can I access the bitmap pixel data DIRECTLY?
I dont want to use the GetBitmapBits and SetBitmapBits functions because they copy memory to another location.
I want to determine where the pixel data of a CBitmap Object are, and having a pointer on them and change them directly without having to "copy from" and "copy to" every time.
Thanx All
|
|
|
|
|
Mohammad A Gdeisat wrote:
How can I access the bitmap pixel data DIRECTLY?
you might try using a DIBSection, which can act like an HBITMAP, but is actually a normal DIB - you can access the pixels by normal pointer arithmetic, etc.
Cleek | Image Toolkits | Thumbnail maker
|
|
|
|
|
|
By knowing the BMP file format, you can get access to any part of it.
http://www.wotsit.org/
"One must learn from the bite of the fire to leave it alone." - Native American Proverb
|
|
|
|
|
Hey can anybody tell me how to get 'RecycleBin's' path thru API or anyway but programatically ????
do let me know.
Regards,
Supriya Tonape
|
|
|
|
|
CString sRecyclepath;
SHGetSpecialFolderPath(this->GetSafeHwnd(), sRecyclePath, CSIDL_BITBUCKET, FALSE);
------- sig starts
"I've heard some drivers saying, 'We're going too fast here...'. If you're not here to race, go the hell home - don't come here and grumble about going too fast. Why don't you tie a kerosene rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt
"...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
Thank U John, Though I m not using MFC but I will try using that API.
thanks for the help
Regards
Supriya Tonape
|
|
|
|
|
If older platforms are an issue, you might want to consider using SHGetFolderPath() , which is a superset of SHGetSpecialFolderPath() .
"One must learn from the bite of the fire to leave it alone." - Native American Proverb
|
|
|
|
|
OK thank U
Best Regards,
Supriya Tonape
|
|
|
|
|
Does this work? Surely you have to allocate a buffer to pass to SHGetSpecialFolderPath? Wouldn't you have to call GetBufferSetLength and ReleaseBuffer either side of the call to SHGetSpecialFolderPath?
|
|
|
|
|
Graham Bradshaw wrote:
Does this work?
Not as it is currently presented.
Graham Bradshaw wrote:
Surely you have to allocate a buffer to pass to SHGetSpecialFolderPath? Wouldn't you have to call GetBufferSetLength and ReleaseBuffer either side of the call to SHGetSpecialFolderPath?
Correct.
"One must learn from the bite of the fire to leave it alone." - Native American Proverb
|
|
|
|
|
Relax, I was just steering him in a direction...
------- sig starts
"I've heard some drivers saying, 'We're going too fast here...'. If you're not here to race, go the hell home - don't come here and grumble about going too fast. Why don't you tie a kerosene rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt
"...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
I think it is her, not him
|
|
|
|
|
Yup, I understand that n thanks!
Supriya Tonape
|
|
|
|
|
No it doesnt work
bye
Supriya
|
|
|
|
|
Um. I don't know of an API but on my system (Windows XP SP2) the Recycle Bin is at C:\Recycled. (I think this is a real folder, not a shell folder, because I can access it through Command Prompt.) There must be a GetShellFolder API or something like that, or you could probably find it in the Registry somewheres.
|
|
|
|
|
That's right, it's not him but her
Well,I cant use that API (SHGetSpecialFolderPath) as it says 'If a virtual folder is specified, this function will fail' n RecycleBin is the virtual folder...Actaully not even folder, it's a file....I will look into it. Thanks to U all for giving the direction.
Bye
Supriya Tonape
-- modified at 2:48 Saturday 8th October, 2005
|
|
|
|
|
The following code:
int i = 0;
cout << i++ << i;
why does it output 00?
|
|
|
|
|
because i++ is the post-incrementation, which mean that the incrementation is done at the end of the expression (here cout << i++ << i; ).
by opposite,
cout << ++i << i; would have outputed 11 and
cout << i << ++i; would have outputed 01 .
is that all clear ?
TOXCCT >>> GEII power [toxcct][VisualCalc]
|
|
|
|