|
dec means decimal, see stl ref
|
|
|
|
|
I posted this yesterday but it sank under the various other requests ...so reposted this again :
hi !
I was testing out skinmagic demo for one of my apps,and came accross a few problems ..maybe experienced users can help me out on this.
problem 1 :
when i used irregular shaped dialog windows, the edges showed up as having a faint magenta lines ( i used magenta as my transparent color ).I made the image using photoshop 24 bit bmp,without any drop shadow.Can anyone tell me how to get rid of these edges?in the examples i saw dialog boxes with more complicated edges than mine but those didn't have a problem, and i am unable to find out the reason for this.Can anyone exolain why this happens ?
problem 2: i had a pulldown menu in my app, and when i skin it , the pulldown menu dissapears ! the popup menu (right click ) stays though...i mean it;s properly invoked on right click, but not the pulldown menu.
problem 3: As i said before i am using an irregular shaped dialog box in my main window.after skinning , the messageboxes are also assuming the same shape, which i do not one.i want my mnessageboxes to be plainer.Would specifying a control ID for the framedialog or the shapedialog help ?How can use a diff shape for my messagebox than my other dialog boxes?
I would be glad if anyone can solve my doubts.Thanks to all the contributirs in advance
Regards
Kane
"Some guys hack just to get themselves a girlfriend.What a pathetic reason, huh ?"
|
|
|
|
|
I'm afraid I've never heard of Skinmagic but why don't you contact its developers and surely they can help with these basic issues.
Neville Franks, Author of ED for Windows www.getsoft.com and coming soon: Surfulater www.surfulater.com
|
|
|
|
|
Hi..Checkout this...
Problem 1:-----------------------
Solution 1: Please position mask at right positon. your image & mask are not overlap exactly.that's not matter which tool you used to create background..as I always use painbrush.
Problem2:--------
Solution 2: this is your coding problem..please check again.
Problem 3:-----------
Solution 3: You sud use your own bug tracking system.. How? Make a Dialog and place static text on that. check error & show & use that dialog. One other way you can customize this by storing bitmap(and mask) setting in file or database. & while starting application check that file or database & use bitmap and mask according to that..
OK! Bye...
Sumit Kapoor
---Sumit Kapoor---
|
|
|
|
|
Hi all,
I would like to write a program that allows me to password protect applications such as Word and I.E. My, vision is that when one of these apps is launched my app would open first and ask for the password and then either continue or kill the app. Would you have any ideas to point me in the right direction?
Thanks in advance for your help,
bacon
|
|
|
|
|
i did soemthing like this using API hooks.study Ivo Ivanov's API hooking revealed for more info.
Hope it helps
Regards
Kane
"Some guys hack just to get themselves a girlfriend.What a pathetic reason, huh ?"
|
|
|
|
|
what i would do, is look for windows with those classname and titles of the windows you wish to protect, (you can use Spy++ to get them)
then hide them using the Showwindow() function
and bring up your password dialog
if they enter the right password show the window/s again using ShowWindow()
|
|
|
|
|
Anonymous wrote:
...when one of these apps is launched my app would open first...
You might see about modifying the HKEY_CLASSES_ROOT\exefile\shell\open\command registry key. Change the (Default) value to myprog.exe "%1" %* and see if that works.
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
A big thank you to everyone!
--bacon
|
|
|
|
|
Dear Friend,
My application works fine in Release mode but it gives an error or displays an abort dialog when I close window in Debug mode.
Please write to me the reason behind this.
Thanking you in advance....
Billar
|
|
|
|
|
maybe it;s giving an assertion error.then is shud give a message like "assertion failed in file so and so in line so and so " .Open up the file and read up that line.Maybe you have done something illegal....
Regards
kane
"Some guys hack just to get themselves a girlfriend.What a pathetic reason, huh? "
|
|
|
|
|
Billar wrote:
Please write to me the reason behind this.
*laughter*
Probably because you have a bug. Without a description of any kind, however, it's quite difficult to know what the problem might be...
|
|
|
|
|
Johan Rosengren wrote:
*laughter*
Probably because you have a bug. Without a description of any kind, however, it's quite difficult to know what the problem might be...
It seems to be a worrying trend that some folks think that just because a program doesn't crash it "works fine". He should consider himself lucky the problem shows itself in a debug build and not just the other way around.;)
Neville Franks, Author of ED for Windows www.getsoft.com and coming soon: Surfulater www.surfulater.com
|
|
|
|
|
See if this article helps.
"When I was born I was so surprised that I didn't talk for a year and a half." - Gracie Allen
|
|
|
|
|
DEar Friends,
I got the solution. Actually the problem was in the attached lib file. After linking the another or seperate .lib file seperately in Release/Debug mode, problem get solved.
Anyway thanks for your kind co-operation.
Bye
Billar
|
|
|
|
|
dears:
In the following function both Visual C++ 6 and (Insure++ software that detecting memory leaks and bugs) pointing that there are a memory leak in this statement in this function
Since
*CWorkAreaWnd derived from CWnd.
*CDrawObject Derived from CObject and it is the base class for all objects(Shapes here).
* and CDrawObject has m_ObjTracker member function of Type CRectTracker.
code:--------------------------------------------------------------------------------
void CWorkAreaWnd:rawTracker(CDrawObject *pDrawObject , POINT point )
{
/*
** Create Tracker for the selected object.
*/
CPoint n = point ;
CDrawEditor32App * pApp = (CDrawEditor32App*)AfxGetApp();
CDrawEditor32Doc *pDoc = pView->GetDocument();
CRect rect ,objectRect = pDrawObject->getObjectRect();
if (pDrawObject->m_ObjTracker)
{
pDrawObject->m_ObjTracker = NULL;
delete pDrawObject->m_ObjTracker;
}
//////////////////////////////////////////////////////////////////////////////////
pDrawObject->m_ObjTracker = (CTrackerObj *)new CTrackerObj(objectRect,CRectTracker::dottedLine |CRectTracker::resizeInside |CRectTracker::resizeOutside );
//Here compiler and Insure indicate memory leak
/////////////////////////////////////////////////////////////////////////////////
if ((pDrawObject->m_ObjTracker))
{
if(!bArrowKey && !pDoc->pDrawClass->bMultiSelection)
pDrawObject->m_ObjTracker->Track(this, point, TRUE );
else
pDoc->m_Change = TRUE;
pDrawObject->m_ObjTracker->m_rect.NormalizeRect();
CRect TakerRect = pDrawObject->m_ObjTracker->m_rect;
if(!objectRect.EqualRect(TakerRect))
{
rect = pDrawObject->CalculateDimensionRect(TakerRect);
pDrawObject->setObjectRect(rect);
}
}
}
--------------------------------------------------------------------------------
but the problem if i add this at the end of the Fucntion
-------------------------------------------------------
code:
delete pDrawObject->m_ObjTracker;
-------------------------------------------------------------
the program will crash when draw something in screen .
where is the right place to perform free memory in this case?
and why crashing occured since i free memory before the scope of the fucntion end up.
Thanks
|
|
|
|
|
You might get the crash if you don't set pDrawObject->m_ObjTracker to NULL at the end. You will most probably have forgotten to add a delete in the destructor as well
You can, however, make the DrawObject class manage its own memory. Add a function CreateTracker instead of allocating memory in the calling function. In CreateTracker, delete the old tracker if it exists and create a new one with new . Make sure to delete the tracker in the DrawObject destructor.
You are making a maintenance nightmare for yourself by allocating part of a class outside the class, naughty, naughty, naughty *slap on wrist*
|
|
|
|
|
dear:
I got ur point and u r completely right, it is a big nightmare to locate var in calling fucntion, I'm changing the code as u said.
Thanks
|
|
|
|
|
Anyone know how to write a getProcessor ID and getProcessor String?
"Naked we come and bruised we go."
- James Douglas Morrison
Best Wishes,
ez_way
|
|
|
|
|
Take a look at this
regards
modified 12-Sep-18 21:01pm.
|
|
|
|
|
Great answer that you very much1
"Naked we come and bruised we go."
- James Douglas Morrison
Best Wishes,
ez_way
|
|
|
|
|
Hi, I have created a simple tetris game for a school project alogn with some firends. I currently am having a dilema. I have two problems. One has to do with the topic of this message; I am trying to write the score of the game when ever the score of the current game is higher than the score in the file. So if I played and got 1000 points then died it woudl write 1000 to a file (points.txt), and if you played after and got over 1000 it would override my score with yours, but if you got less it wouldnt... Afterwards I want to read the file and output the score within on the score as "highscore: ___". So how do I do this? Source require please... visual is new to me...I'm used to dev c++. I am lookign for a simple way of reading and writing (like adding a .h and calling on one of its functions to read or write). I know abotu fstream but I cant seem to get it to work..
P.S) the second this I was having problems with is I am lookign for a pause function....but that can wait.
Thanks in advanced
Glen Buchholz
|
|
|
|
|
>> I know abotu fstream but I cant seem to get it to work..
Your in a school C++ course and no one can show you how to get fstream working? What school is it?
unsigned long score = 0L;
std::ofstream os("sample.txt");
score = 1000;
os << score;
os.close();
std::ifstream is("sample.txt");
is >> score;
is.close();
>. I am lookign for a pause function
::Sleep( 5000); // sleep for 5 seconds
"No matter where you go, there your are." - Buckaroo Banzai
-pete
|
|
|
|
|
Thanx, so much.
Got it working perfectly
P.S) Its a high school and we do things in Dev C++... which we had fstream workign in...vc++ is a bit different...
|
|
|
|
|
All resources of my application is designed in 1024 * 768 pixels resolution ,
after changing the resolution in to standard 800 * 600, some of the screen is beyond the visible area. i want to change my application in a manner that that must work in any resolution ( i found some applications do this very nicely ).
is there any code to do this?
and one more thing, how can i get the current resolution of screen and how can i change that by code?
Thankyou
I want to change Myself..Can u help me?
|
|
|
|