|
"What should I do?": Reading about Right Managment in Vista.
=> http://msdn.microsoft.com/en-us/library/aa905330.aspx[^]
You cant write a file where you want, you need to have the write rights. A nice place to write is the User Directory who started the writing process.
Greetings from Germany
|
|
|
|
|
Thank you but I have set all security attributes. I am facing the problem only Os drive of Vista.
Is there any way to skip the security permission?
|
|
|
|
|
There is always a way. Your process needs administrative rights. But thats no good practise.
I guess your not so seasoned in Windows programming, so you got to learn a lot.
Once again: You better read and understand the right managment in Vista.
Greetings from Germany
|
|
|
|
|
MPTP wrote: Is there any way to skip the security permission?
Of course not - that's baked into the OS - if there was a way around security, then writing viruses would be even more common than they already are. Think of it like the locks on your car - is there any easy way around them (yes, you can pick them, but htere's no legitimate way around them).
|
|
|
|
|
MPTP wrote: I have set all security attributes.
No, you haven't.
You need to set folder permissions to allow the desired access by the
appropriate user(s).
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
One other thing you might try - Process Monitor[^] can help you see exactly what your process is doing in terms of file accesses and things - that might give an extra level of detail that you need?
|
|
|
|
|
Exactly what folder are you trying to write to? Short of being an administrator, there are only a few folders that you can write to.
"Love people and use things, not love things and use people." - Unknown
"The brick walls are there for a reason...to stop the people who don't want it badly enough." - Randy Pausch
|
|
|
|
|
i have a dialog based appication. when i click on a button on a dialog(1st dialog), it will open 1 dialog(2nd dialog) and when i click on button on this dialog(2nd dialog) another dialog box(3rd dialog) will get opened and i want to change title of this dialog(3rd dialog).
thanks in advance
|
|
|
|
|
u can use SetWindowText().
|
|
|
|
|
Chandrasekharanp wrote: u can use SetWindowText().
You cannot use SMS language here, please.
It is a crappy thing, but it's life -^ Carlo Pallini
|
|
|
|
|
|
Chandrasekharanp wrote: That was not intentional
Intentional or not intentional, it simply irritates the majority of the 'grown-up' population.
I am not sending an SMS to an old peer of mine, I'm answering a query on an programming board, that hundreds of professionals from around the world read every day. So, I would be very careful on how I present myself here.
This is off-topic and I won't discuss further on this.
It is a crappy thing, but it's life -^ Carlo Pallini
|
|
|
|
|
void CFdView::OnDraw(CDC* pDC)
{
CFdDoc* pDoc = GetDocument();
ASSERT_VALID(pDoc);
// TODO: add draw code for native data here
this->GetDocument()->SetTitle("your title");
}
|
|
|
|
|
u r -> sir, plz plz u don't blame...
It looks like the sms language is appreciated by the OP [^].
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]
modified on Tuesday, December 2, 2008 4:39 AM
|
|
|
|
|
CPallini wrote: It looks like the sms language is appreciated by the OP [^].
Indeed! I will never feel like answering these SMS questions. May be I'll send the reply via an SMS inztd.
It is a crappy thing, but it's life -^ Carlo Pallini
|
|
|
|
|
it is not working coz i will have to refer to child window first.
how can i refer to child window? i hv implmented as:
IRCNewSim* ptr1=NULL;
Markcorr* ptr2=NULL;
ptr1=(IRCNewSim*)AfxGetApp()->m_pMainWnd;
ptr2=(Markcorr*)ptr1->GetActiveWindow();
ptr2->SetWindowText("Tower1 Scanner1");
thanks
|
|
|
|
|
Waht was return value of SetWindowText?
|
|
|
|
|
appl is getting crashed and control is going into Setwindowtext
void CWnd::SetWindowText(LPCTSTR lpszString)
{
ASSERT(::IsWindow(m_hWnd));
if (m_pCtrlSite == NULL)
::SetWindowText(m_hWnd, lpszString);
else
m_pCtrlSite->SetWindowText(lpszString);
}
m_hwnd is showing as NULL
|
|
|
|
|
So I think your problem is of hwnd ptr2.
|
|
|
|
|
ok...
do u hv any other suggetion abt how can i implement this by some other method?
or can u give me some demo of this type of application?
i will b very much greatful to u
|
|
|
|
|
How did you create your child dialog?
|
|
|
|
|
child dialog means after clicking on button i will display 1 more dialog. i want to change title of this dialog at run time.
|
|
|
|
|
Are you wanting to set the window text of the 3rd dialog dynamically? In that case, you could pass it as a parameter to the constructor of the 3rd dialog class and have a string member variable initialized with that value and then call SetWindowText() in InitDialog() . That sounds viable?
It is a crappy thing, but it's life -^ Carlo Pallini
|
|
|
|
|
thanks Rajesh it is working now.
|
|
|
|
|
Anjali Patil wrote: ...i want to change title of this dialog(3rd dialog).
Call SetWindowText() from within its OnInitDialog() method.
"Love people and use things, not love things and use people." - Unknown
"The brick walls are there for a reason...to stop the people who don't want it badly enough." - Randy Pausch
|
|
|
|