|
size and location?
if yes I suggestion use movewindow in the wm_size
|
|
|
|
|
Did you create the buttons at runtime?
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
i also have the simillar problem
but its quite different
Button displayed without misalignment 1024*768 in windows xp of my computer
But it misaligns in windows xp of other computer.
I used skin
can any one help me
JAYARAJ
|
|
|
|
|
J5121982 wrote: i also have the simillar problem
but its quite different
If you have a similar problem, how can it also be quite different?
J5121982 wrote: But it misaligns in windows xp of other computer.
What is the resolution of this computer?
Are you creating the buttons/controls at runtime?
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
I think the buttons are created without movewindow(no runtime)
so if resol from 800 to 1024 then location buttons isnt good
|
|
|
|
|
DavidCrow wrote: If you have a similar problem, how can it also be quite different?
Regards,
Nish
|
|
|
|
|
I created the buttons using the resource editor ie dropping the button on the dialog..
|
|
|
|
|
If you placed a button 5 DLUs from the top-left corner of the dialog, it will remain at that position regardless of the screen's resolution. If it's not, you are doing something else.
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
DavidCrow wrote: 5 DLUs
What is DLU
The position of the buttons with respect to the dialog hasnt changed but the dialog is so big tat it doesnt fit in the screen and so the buttons are not visible.
DavidCrow wrote: you are doing something else
I have not done anything
-- modified at 13:38 Tuesday 7th March, 2006
|
|
|
|
|
nripun wrote: What is DLU
Dialog coordinates are measured in DiaLog Units, or Dialog Box Unit. It is device independent. They allow the dialog box and its controls to be sized correctly when the development and target machines are different.
nripun wrote: The position of the buttons with respect to the dialog hasnt changed but the dialog is so big tat it doesnt fit in the screen and so the buttons are not visible.
That's a different problem altogether. You can't expect a dialog designed for 1024x768 to fit on a 640x480 monitor. You need to design for the least common denominator.
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
Is there a way to check and change the monitor resolution from the VC++ program.
I needed a big dialog to previwe 4 camera feeds on the dialog box each occupying a display area of 352x288 and with adequate spacing between each display area. the dialog has a few buttons also. So i cant fit all of these in a dialog if the monitor 800x600 resolution.
So when i run the application in a diff machine i can check the resolution and fix it.
|
|
|
|
|
nripun wrote: Is there a way to...change the monitor resolution from the VC++ program.
See ChangeDisplaySettings() .
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
Can you send me an example that I run it an HTML file run .
tnks
|
|
|
|
|
ShellExecute(NULL,"open","yourHTMLFilePath.html",NULL,NULL,SW_SHOWNORMAL);
Nibu thomas
Software Developer
|
|
|
|
|
|
man ! do you look at your answers[^] when asking for something ?!
[edit]
ah I see, you deleted your post after my second reply to make people think I'm dumb ?
but you failed...
[/edit]
-- modified at 7:52 Tuesday 7th March, 2006
|
|
|
|
|
how to get the current system IP address?
JAYARAJ
|
|
|
|
|
|
i got it thanks
CString CIP::GetIP()
{
CString strIp;
//Init winsock
WSADATA wsaData;
int nErrorCode = WSAStartup(MAKEWORD(1,1), &wsaData);
if (nErrorCode != 0) {
//Cannot initialize winsock
return _T("");
}
char strHostName[81];
if (gethostname(strHostName, 80)==0)
{
hostent *pHost = gethostbyname(strHostName);
if (pHost->h_addrtype == AF_INET)
{
in_addr **ppip=(in_addr**)pHost->h_addr_list;
//Enumarate all addresses
while (*ppip)
{
in_addr ip=**ppip;
strIp = CString(inet_ntoa(ip));
ppip++;
if (strIp!=_T("")) {
break;
}
}
}
}
return strIp;
}
JAYARAJ
|
|
|
|
|
Hi,
Im using the CTime to calculate the date when adding number of days. The
strange thing is that when I add 58 and 59 days to the same date it returns
the same date. Here is the small code:
void DateCalc(int Days)
{
int Date=1;
int Month=9;
int Year1,Month1,Day1;
CTime Check( 2006, Month,Date,0,0,0);
Check+=CTimeSpan( Days,0,0,0);
Year1=Check.GetYear();
Month1=Check.GetMonth();
Day1=Check.GetDay();
TRACE("Year %d Month %d Date %d\n",Year1,Month1,Day1);
}
... function(...)
{
DateCalc(58); //add 58 days to 1/9/2006
DateCalc(59); //add 59 days to 1/9/2006
Both TRACE(..) functions within DateCalc(..) displays :
Year 2006 Month 10 Date 29
Year 2006 Month 10 Date 29
Anyone explain this?
Neil
|
|
|
|
|
Just try COleDateTime instead of CTime .
Nibu thomas
Software Developer
|
|
|
|
|
How do I add number of days to date? I tried the below, but didnt allow me to dd days to it.
int Month=9;
int Date=1;
COleDateTime Check( 2006, Month,Date,0,0,0);
Check+=CTimeSpan( 58,0,0,0);
Neil
|
|
|
|
|
NeilDevlin wrote: Check+=CTimeSpan( 58,0,0,0);
Check+=COleDateTimeSpan( 58,0,0,0);
"Let us be thankful for the fools. But for them the rest of us could not succeed." - Mark Twain
"There is no death, only a change of worlds." - Native American Proverb
|
|
|
|
|
That worked, thanks..
Neil
|
|
|
|
|
<wild guess>
British Summer Time ends on 29 Oct. My guess is that the CTime class is doing some BST/GMT stuff behind your back. I'd check the hour value of the Check variable, to see if that's changing.
</wild guess>
|
|
|
|