|
I tried the same after removing both the lines pointed by you. Still the main container window is in LTR layout.
What i got from the PSH_RTLREADING documentation and its implementation in my project, is "PSH_RTLREADING" only changes the the caption. What is require by the RTLLayout is change in the whole TITLE bar, Status bar, tabs all these should be in the Right of the screen.
Canption should be displayed in the Right of the Title bar.
However PSH_RTLREADING only changes the caption in RTL. However the position of the caption in the Title bar still reamings in teh left.
|
|
|
|
|
I'm wondering if you might be better using SetProcessDefaultLayout and removing the other explicit RTL options in your app...
I'm afraid my knowledge of the subject is exhausted now
|
|
|
|
|
SetProcessDefaultLayout(LAYOUT_RTL ) is not solving the problem.
|
|
|
|
|
CPropertySheet layout is automaticly change by the OS
|
|
|
|
|
My project is Dialog base and I want to change "Font" of all control on this dialog.
What's the function can support this issue?
|
|
|
|
|
|
Plz....Give me an idea or source code to create a scenary in the client area of the frame window.
|
|
|
|
|
You posted the same question THREE TIMES within 5 minutes. Not a good start for you.
"Well, we're getting "F"'d at work. WPF, WCF, and WWF... WTF?" --John Simmons
|
|
|
|
|
Requesting source code to divide the client area in to 4 quadrants with different gradient patterns.
|
|
|
|
|
Requesting source code to divide the client area in to 4 quadrants with different gradient patterns.(required soon)
modified on Friday, January 9, 2009 7:34 PM
|
|
|
|
|
Hi All,
I had poarted VC++ 6.0 code to VC++ 2008. I am facing a problem with this piece of code.
typedef std::vector<char> Buffer;
void LoadFile(CString filePath, Buffer &data)
{
std::ifstream file(filePath, std::ios::in | std::ios::binary);
if (file.fail()) {
ThrowError(GetLastError(), "", (LPCTSTR)filePath);
}
while (!file.eof()) {
char c;
file.get(c);
data.push_back(c);
}
}
File Data: 212*R:\PRDS\Helptable\HL17.DAT *006*R:\PRDS\Helptable\HL58.DAT
<b>When i open the file instead of * i found a box </b>
When i look at the data vector in VC++ 6.0 the first element is 212, second is "r:\..." so on...
but when i retrieve the data vector in VC++ 2008, i am getting individual characters.
I am thinking on the boxes that he used to seperate the elements in the file.
Any suggestion will help me.
Thanks All
|
|
|
|
|
pratap1980 wrote: first element is 212, second is "r:\..."
First element of what? The vector contains chars, so can't have a string as an element.
pratap1980 wrote: when i retrieve the data vector in VC++ 2008, i am getting individual characters
That's what I'd expect to see in a vector of chars?
|
|
|
|
|
I am still fairly new to MFC, I have been mainly working on embedded/chip level C.
Now I have a MFC application talking to my controller through ActiveX. Certain data retrieived by ActiveX needs to be displayed to MFC user interface. data retrieiving and filltering are successful. I am trying to pass the data to MFC into an Edit control. Edit control received the notice OK. Then I get stuck. The value of the Edit control is NOT updating until the call to ActiveX is returned. As a result, only the last data is displayed. all data sent while ActiveX is running is not shown to User (although Edit control got all data).
MFC Application -> User Interface -> User Click "Retrieve" -> Display certain data to Edit box on User Interface at run-time.
What am I missing?
in .h file:
afx_msg void OnChangeStatus();
in .c file:
void CReceiveSend::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CReceiveSend)
....
DDX_Text(pDX, IDC_STATUS, X_Current_Status);
....
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CReceiveSend, CDialog)
//{{AFX_MSG_MAP(CReceiveSend)
...
ON_EN_CHANGE(IDC_STATUS, OnChangeStatus)
...
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
void CReceiveSend::OnChangeStatus()
{
//transfers values from the member variables to the controls
UpdateData( FALSE );
}
inside ActiveX function call:
int CReceiveSend::XReceive()
{
....
X_Current_Status = some_value;
this->SetDlgItemText(IDC_STATUS, X_Current_Status);
return(0);
}
Thanks
|
|
|
|
|
Got answer to my own question : Use worker thread instead for ActiveX control. It was using User Interface thread before.
|
|
|
|
|
Dear All
I have one project in VC2005.
In has mose run time error.
But I dont know how to use call Stack in VC2005.
In VC2000, a Call Stack item exists
But in VC2005 in "view->Other Windows " there is no Call Stack
Could you please help me for this problem.
Regards
Mahdi
|
|
|
|
|
Menu Debug->Windows->Call Stack (or ALT + 7 ) on my VC++ 2008 Express Edition ...
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
|
You are welcome.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
I have an MFC app that is having some weird issues.
When you start the program and don't move window around it works fine. But as soon as you start moving it around, an exception will occur.
Debugging this in VS, I will get a buffer overrun message or some MFC debug assertion. I'm pretty new to MFC, anyone have any ideas where I should look to fix this?
|
|
|
|
|
Paffinity wrote: I'm pretty new to MFC, anyone have any ideas where I should look to fix this?
Very close to the error message (or as last resort, you may post it here).
You should be precise to get any help.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
Hi,
I am using AfxBeginthread in my application for reading the datas from my hardware via serial ports. after clsoing my GUI, when i try to open once again, am getting error that "exe is running". I have closed my handles related to port in destructor of the class. i suspect the Thread is not closed completely, it occupies the memory, i want to know whats the better way to close or kill the thread.
thanks in advance,
Balaji S
|
|
|
|
|
Use a flag that you set from your main thread.
In your second thread, it looks like:
while (bContinue)
{
}
Once the flag is set to false by your main thread, the loop will finish and the thread function will return, terminating nicely the thread. Of course, how to implement this depends a lot of your current design, this is just the basic principle.
|
|
|
|
|
Hi,
thanks for your reply.
now am doing by that way, after false condition am using "afxendthread" function. is it recommended to use or coming out from the while loop itself enough to close the thread.
thanks
balajsi
|
|
|
|
|
Member 4651741 wrote: now am doing by that way, after false condition am using "afxendthread" function
Never do that. Simply exit the function (but you have to be sure that you exited the function). Never close a thread by calling afxendthread.
|
|
|
|
|
Well, just return from the thread routine. Killing a thread is not recommended really...
> The problem with computers is that they do what you tell them to do and not what you want them to do. <
|
|
|
|