|
lctrncs wrote: Thanks again. I hope you enjoy your "greetings seasons." Take the rest of the year off.
You're welcome! I wish I could take the rest of the year off but I am about to release my own
product (yeah, I said that last year at this time, and the year before...) which is 5 years
in the making. I have to get it out...this living as a "starving artist" thing is getting old.
At least I have the drums to beat out my aggressions
Anyway, I may have missed the point of what you were trying to achieve. If it's protecting
content then I would make the doc/view editors read-only and encrypt the content files so they
can't be edited outside of your application. There's always a solution (I refuse to ever be
convinced otherwise).
Best of luck (or "break a leg"?) on your writing projects!
Mark Salsbery
|
|
|
|
|
Drums!?
My little band needs a drummer badly. Do you like Pink Floyd? Do you live anywhere near Colorado?
When you get close with your product, send me a version and I will happily test it for you. I once turned down a full time job teaching college for a six-week gigue testing network protocol analyzers for HP. I stayed a year and a half, then came back as a full consultant. Those were the days! Testing is specialty of mine and since you have been so helpful, I would gladly punish your software for you. Bwaahahahahhaaaa!
If you send me your email address through that web site I sent you to, we can both avoid public postings.
Best of luck.
Groff
PS: Thanks for the heads up on the download error. I experienced the same thing and learned that the problem occurs when the complete file does not download. It is about 5.5 meg, so it is probably easy to try to start early. I will probably put up a little warning page in my "free time." GS
"For a successful technology, reality must take precedence over public relations, for nature cannot be fooled." Richard Feynman, Minority Report to the Official Report on the Space Shuttle Challenger Crash
|
|
|
|
|
BOOL CStudyPartnerDoc::OnSaveDocument(LPCTSTR lpszPathName)
{
StudyPartnerDocFile.SeekToBegin();
... should be
BOOL CStudyPartnerDoc::OnSaveDocument(LPCTSTR lpszPathName)
{
StudyPartnerDocFile.SetLength(0LL);
StudyPartnerDocFile.SeekToBegin();
...
|
|
|
|
|
I downloaded the free demo...is that the right one?
I get the following error in a messagebox:
<exe path="">\Setup.ini
Invalid Database.
The Installation will be cancelled.
|
|
|
|
|
The Win32 CreateFile function's dwShareMode parameter can be use to control this without the need to mutexes. Passing in a value of 0 should do the trick.
Steve
|
|
|
|
|
Thank you for responding.
Won't this collide with my existing code for opening files?
"For a successful technology, reality must take precedence over public relations, for nature cannot be fooled." Richard Feynman, Minority Report to the Official Report on the Space Shuttle Challenger Crash
|
|
|
|
|
Thank you for the nice clue.
Including a CreateFile function passing a dwSharedMode 0 in my OnOpenDocument allows me to open a file when I use the lpszPathName of OnOpenDocument as the first argument in the CreateFile function.
If I then try to open the file a second time using a different instance of my app, a "sharing violation" message appears.
If I try to save the first instance of the file using the first instance of my app, a First Chance Exception occurs that passes "access denied" back to the program.
I have tried various file attributes, but am probably doing something more basic wrong.
Any suggestions?
"For a successful technology, reality must take precedence over public relations, for nature cannot be fooled." Richard Feynman, Minority Report to the Official Report on the Space Shuttle Challenger Crash
|
|
|
|
|
lctrncs wrote: If I try to save the first instance of the file using the first instance of my app, a First Chance Exception occurs that passes "access denied" back to the program.
Try to find out where this exception is coming from. First you need to find out the kind of exception (first chance is not an exception type; it just means the debugger is being given the change to process to exception before the application gets its turn). Once you know that you need to setup your debugger to break on this exception so you can see where it’s coming from. On MSVC 6 this is done via the “Debug”->”Exceptions…” menu item which is accessible while an application is being debugged. Try to set this option as late as possible before you trigger the fault.
Steve
|
|
|
|
|
Please,
is there anybody who can show me how can I put a group box control over the tab control, and to have a caption of the group box to be transparent, not gray. I don't use MFC, I use ATL so I am working with the SendDlgItemMessage, but it doesn't matter, as everything boils down to messages anyways. I use manifest files, so controls are XP-like.
Thank you.
|
|
|
|
|
A group box control without a caption. Isn't that just a rectangle?
And what does "over the tab control" mean? On Top (Z order)? Please don't make up new technical terms, there are enough already.
led mike
|
|
|
|
|
No, it is not that. A group box has a caption, but I don't want a gray background for it.
|
|
|
|
|
So you are saying if you put a group box in a standard white window the caption has a gray background? That's nasty. I see Michael Dunn has given you the answer. Give him a 5 for that.
led mike
|
|
|
|
|
Remember, led mike, you can give a man a gift certificate for a filet-o-fish and he'll eat for a
day. Get a man a job at McDonalds and he'll have an employee discount for life.
I think that's how the saying goes...
|
|
|
|
|
led mike
|
|
|
|
|
You cold resize/reposition the tab control to fit in the group box.
Making the groupbox text transparent is tough. Ownerdraw may help but it seems easier to just
draw a frame and the text.
I don't use ATL, I use MFC so I can't provide an example.
Mark
|
|
|
|
|
Yeah....this is why more and more businesses are dumping Visual C++...this is something that C# or VB programmers are not even thinking about, they just put it on the window and concentrate on the more important business logic.
|
|
|
|
|
Yeah, I can only dream of using those fancy new Windows controls they have in C# and VB.
|
|
|
|
|
Yeah non-software companies usually use VB for their internal programming and software companies usually do not use VB for their products.
Microsoft could have provided for VC the conveniences they provided for VB but they just did not.
Many things are easier in VB but when we need to do things that VB is not designed to do then VB is more difficult.
|
|
|
|
|
That is fine, but we could just have at least the basic functionality, not to bother with the transparency of static controls, for goodness sake.
Sarajevo, Bosnia
|
|
|
|
|
Set the Transparent style bit on the group box (WS_EX_TRANSPARENT ).
|
|
|
|
|
If only they had implemented it in the text part of the control. What's interesting is the part
inside the box is transparent with or without that style set
|
|
|
|
|
Yeah, the group box has weird behavior when themes are on in XP (maybe Vista too? not sure about that)
|
|
|
|
|
I truly believe that with Vista we'll encounter a whole new set of problems with even the most common controls.
Sarajevo, Bosnia
|
|
|
|
|
Thanks for your help, Mike, but it doesn't work.
Simply selecting a Transparent property from the property control ( I use Visual Studio .Net 2005, but the application is Visual C++ with ATL 8 ) would add a WS_EX_TRANSPARENT bit to the group box (I checked the .rc file and it is like that). However, even though the group box does draw transparently, the caption bar of the group box still has an ugly gray background behind the black color text. I just don't know how to get rid of it.
|
|
|
|
|
Hi
I have a Picture Controls (IDC_STATIC) on a DIALOG
and I wish to Transparent the corners of the
Picture in the Control
but when i use the
SetWindowRgn ( HWND hWnd, HRGN hRgn, BOOL bRedraw );
nothing happen.
maybe because it a STATIC winds ?
any suggestion ?
|
|
|
|