|
its working but its work is line the setfileattribute api i mean i only hide the folders which is visible when we click on show hidden files.
Regards.
Tasleem Arif
|
|
|
|
|
Use
COleDispatchDriver FileObject;
COleException oleException;
if ( !FileObject:CreateDispatch( _T("Scripting.FileSystemObject"),&oleException ) )
return;
and then InvokeHelper...
Hope this helps...
-- modified at 8:14 Monday 4th December, 2006
|
|
|
|
|
BadJerry wrote:
COleDispatchDriver FileObject;
COleException oleException;
if ( !FileObject:CreateDispatch( _T("Scripting.FileSystemObject"),&oleException ) )
i wasted two hour finding that function.. but failed.. so i try to implement that by Vc++ way .. i.e. importing scrrun.dll!
<div class='ForumSig'>"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers, Alok Gupta VC Forum Q&A :- I/ IV Support CRY- Child Relief and you </div>
|
|
|
|
|
hi, if i use MFC AppWizard to create the workspace of dialog application, it will create :
title.cpp
ReadMe.txt
title.clw
title.cpp
title.dsp
title.dsw
title.h
title.plg
title.rc
StdAfx.cpp
title.rc2
titleDlg.cpp
titleDlg.h
however, may i know whether i can create another source file ,for example, titleCtrl.cpp by using appwizard to generate the basic file.
if i click new->source file, it will just create an empty .cpp file
Thanks for any reply
|
|
|
|
|
cyn8 wrote: generate the basic file.
if i click new->source file, it will just create an empty .cpp file
Thanks for any re
exactly what do you want?
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and you
|
|
|
|
|
actually i wan to create a .cpp file to the project. Is it possible to create an additional .cpp file with the basic code and working just like when i use the mfc wizard exe.
Can i do it by creating a new class for custom control?
i'm using a dialog based application.
|
|
|
|
|
you can do it by clicking new->source file and then you create an empty .cpp file
but you must include the file StdAfx.h if you want to go on.
is it right?
just do it
|
|
|
|
|
actually i wan to create a .cpp file to the project. Is it possible to create an additional .cpp file with the basic code and working just like when i use the mfc wizard exe.
Can i do it by creating a new class for custom control?
i'm using a dialog based application.
|
|
|
|
|
The appwizard can set up a class associated with a dialog template for you. Beyond that, I'm not sure what you're hoping for, the wizard can't do much more for you, as there's not much more boiler plate code to be had.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
You can use AppWizard to create an empty .cpp file, or you can use ClassWizard (Ctrl+W) to create a class derived from some other class. Either way, the file is added to the project.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
I have overridden the OnPaint() API in a dialog based application to give the dialog box a rounded rect shape using CRgn.
<br />
CRect rect;<br />
GetClientRect(&rect);<br />
CRgn rgn;<br />
<br />
rgn.CreateRoundRectRgn(0, 0, rect.Width(), rect.Height(), 30, 30);<br />
<br />
SetWindowRgn((HRGN)rgn.GetSafeWnd(), TRUE);<br />
After that I have painted the inside of the Rgn giving it a gradient background as explained in one of the articles by Mr. Nishant.(using bitblt())
Now I want to draw a boundary to this rounded rectangle.
I tried FrameRgn() API but the gradient painting drew over the boundary.
I also tried FrameRect() API after gradient painting, selecting the NULL_BRUSH. But all I got was a black Rounded Rectangle.
How do I draw a boundary to the Rounded Rectangle without sacrificing my gradient background?
Cutebug
|
|
|
|
|
|
Naveen R wrote: try
RoundRect().
RoundRect() fills the area with the currently selected brush.
Thus I would lose the gradient background.
Cutebug
|
|
|
|
|
why dont u first draw the frame and then fill the rgn?
nave
|
|
|
|
|
Ok I draw the frame first.
Then, for filling the region with gradient background, I am considering the pixels from 0 to rect.width() (For Width) and from 0 to rect.Height() (For Height).
Since this is a rounded rectangle, I don't know how to deal with the curved portion of the region so as not to paint over the boundary.
How do I accomplish this?
Cutebug
|
|
|
|
|
did u try selecting null brush as Mark Salsbery said?
nave
|
|
|
|
|
cutebug wrote: RoundRect() fills the area with the currently selected brush.
Thus I would lose the gradient background.
What about selecting a NULL brush?
|
|
|
|
|
ho ...left this point
nave
|
|
|
|
|
Using of NULL_BRUSH provides no help and the entire region is filled by BLACK.
Cutebug
|
|
|
|
|
cutebug wrote: Using of NULL_BRUSH provides no help and the entire region is filled by BLACK.
Hmm... that sounds like an RGB(0,0,0) brush, not a GetStockObject(NULL_BRUSH) brush.
|
|
|
|
|
It worked with SelectStockObject(NULL_BRUSH).
Thanks a lot.
Cutebug
|
|
|
|
|
hi i m exactly looking for what u have done.
Actually i want to apply gradient background to my dialogs and make it rounded rectangle and create a frame. i have seen nish article but i didn't understand where to put the code. i didn't find any onerasebackground message. can u plz post ur code or plz send it to indupuriraj@yahoo.co.in
thnx in advance.
|
|
|
|
|
How can i add support of different languages to my application?
|
|
|
|
|
kiranin wrote:
How can i add support of different languages to my application?
MultiLanguage[^]
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and you
|
|
|
|
|
I've got a list of names in a combo box, which have to be sorted right. What I'm trying to do is insert a name into the middle of the list without overwriting an existing name or screwing up the order of the list. What's the best way to do that? Should I open up a gap by shifting the names after the position I'm inserting at to the right, and then use InsertString to put the name in? Or is there a more efficent way of doing it? I can't use the built in sorting than comes with the CComboBox class since I need more control than it can provide.
|
|
|
|