|
Hi,
I am using QEMU (cpu emulator) to run ISO(linux) on my windows OS.
I created setup and installed. Question us this when I run from program file, program plays audio, but when I run from desktop shortcut, program does not play audio.
What might be the problem. Please suggest me.
|
|
|
|
|
Please anybody suggest me?
|
|
|
|
|
I think you are asking this at the wrong forum, rather try some QEMU related sites, maybe start at their own[^] site. This forum is for C/C++/MFC related questions.
Just a guess though, the problem might be caused because QEMU looks for some files in the current directory when starting up, which is, if you run it by doubleclicking the exe in its install-folder, the folder that contains the exe, but if you run it thorough a link, the current folder will be the location of the link and so QEMU doesn't find its files. This is -as i said- just a guess, i think if you right click on the link on your desktop and select "properties", you can set the working folder for the executable, try changing this to the folder where the exe is located. Maybe it helps, if not, then look for a QEMU-dedicated forum. Good luck.> The problem with computers is that they do what you tell them to do and not what you want them to do. <
> Sometimes you just have to hate coding to do it well. <
|
|
|
|
|
Thanks for reply..
I want to know with respect to a general MFC application..what might be the cause?
|
|
|
|
|
Well, one cause might be what i already mentioned, aside of that it is hard to say anything about it without knowing any details... > The problem with computers is that they do what you tell them to do and not what you want them to do. <
> Sometimes you just have to hate coding to do it well. <
|
|
|
|
|
Hi,
Is it possible to do AES-128 bit encryption/decryption in Windows XP/2003 using CryptoAPI?
If yes, then how should I create the key for encryption and how do I share the key among other users to decrypt the content?
Are there any digital certificates involved?
I saw the CSP registry entry HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Cryptography\Defaults\Provider\Microsoft Enhanced RSA and AES Cryptographic Provider (Prototype). Why a suffix "(Prototype)"?
What all are the possible methods to create and share the key?
Links to examples and other detailed documents will be useful.
Thanks in advancecheers
Varghese Paul
|
|
|
|
|
Cryptography is far too big a subject ot be covered in a tech forum like this. The answer to your main question may be found here[^]. Follow the links from this page for full description and many samples. txtspeak is the realm of 9 year old children, not developers. Christian Graus
|
|
|
|
|
Richard MacCutchan wrote: Cryptography is far too big a subject ot be covered in a tech forum like this.
Hi Richard,
He only asked for samples and links and not ask someone to cover the whole thing here.
I must add that he was my ex-team lead and is an extremely talented developer (it looks like he may not have worked on cryptography though). Just thought I'd let you know.
“Follow your bliss.” – Joseph Campbell
|
|
|
|
|
Rajesh,
OK, comments accepted, although I did post a link that anyone could have found through Google/MSDN. As to his talents, it is impossible from his question (as with most posters) to judge his ablities abilities and/or experience.
[edit]you can judge my keyboard abilities by the number of spelling mistakes[/edit]txtspeak is the realm of 9 year old children, not developers. Christian Graus
|
|
|
|
|
In MFC-MDI, I create Dailog in MFC-MDI Maiframe, but tell me is error.
In MFC-Dailog, create Dailog is No problem ;
Help Help Help ;
|
|
|
|
|
Please post the (relevant) code.
Please post the error message.
Please read the forum guidelines.
Please...
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 find error because I Create AboutDailog and i show this dailog;
but AboutDailog code same of system create CAboutDlg :
----------AboutDailog.h---------------------
class AboutDailog : public CDialog
{
DECLARE_DYNAMIC(AboutDailog)
public:
AboutDailog();
virtual ~AboutDailog();
protected:
DECLARE_MESSAGE_MAP()
public:
afx_msg void OnFileAbout();
};
----------AboutDailog.cpp---------------------
// AboutDailog.cpp : 实现文件
//
#include "stdafx.h"
#include "MyControlTest.h"
#include "AboutDailog.h"
// AboutDailog
IMPLEMENT_DYNAMIC(AboutDailog, CWnd)
AboutDailog::AboutDailog()
{
}
AboutDailog::~AboutDailog()
{
}
BEGIN_MESSAGE_MAP(AboutDailog, CWnd)
ON_COMMAND(ID_FILE_ABOUT, &AboutDailog::OnFileAbout)
END_MESSAGE_MAP()
// AboutDailog 消息处理程序
void AboutDailog::OnFileAbout()
{
// TODO: 在此添加命令处理程序代码
AboutDailog aboutDlg;
aboutDlg.DoModal();
}
----------CAboutDlg.h---------------------
class CAboutDlg : public CDialog
{
public:
CAboutDlg();
// 对话框数据
enum { IDD = IDD_ABOUTBOX };
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV 支持
// 实现
protected:
DECLARE_MESSAGE_MAP()
};
----------CAboutDlg.cpp---------------------
CAboutDlg::CAboutDlg() : CDialog(CAboutDlg::IDD)
{
}
void CAboutDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
}
BEGIN_MESSAGE_MAP(CAboutDlg, CDialog)
END_MESSAGE_MAP()
// 用于运行对话框的应用程序命令
void CMyControlTestApp::OnAppAbout()
{
CAboutDlg aboutDlg;
aboutDlg.DoModal();
/*AboutDailog aboutDlg;
aboutDlg.DoModal();*/
}
|
|
|
|
|
Patrick Tang wrote: but AboutDailog code same of system create CAboutDlg
One constructor does not use any resource template ID... Check your definition of Irrationality[ ^]
1 - Avicenna
5 - Hubbard
3 - Own definition
|
|
|
|
|
Patrick Tang wrote: ...but tell me is error.
Are you keeping this error a secret or can you be bothered to share it with us?"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Man who follows car will be exhausted." - Confucius
|
|
|
|
|
I can't believe I'm struggling as much as I am over this, but basically, I have
signed char cCoffee[16];
and I need to turn it into CString.
I've tried all the obvious:
CString strString 1 = cCoffee;
CString strString2(cCoffee);
CString strString3;
CopyMemory(strString3.GetBuffer(), cCoffee, sizeof(unsigned char)*16);
strString3.ReleaseBuffer();
I still can't get it to work...
I don't have a say in how cCoffee is declared, so please don't suggest things like "use _T("string")".
I'm using Unicode.
Any help greatly appreciated.
|
|
|
|
|
PaulowniaK wrote: I still can't get it to work...
Please describe it concretely Check your definition of Irrationality[ ^]
1 - Avicenna
5 - Hubbard
3 - Own definition
|
|
|
|
|
Apologies.
My VS2005 doesn't speak English, so I'll just list the compiler error for each attempt I made:
CString strString1 = cCoffee;
results in error C2440
CString strString2(cCoffee);
results in error C2664
CString strString3;
CopyMemory(strString3.GetBuffer(), cCoffee, sizeof(signed char)*16);
strString3.ReleaseBuffer();
compiles OK but has a runtime error
"Expression: nLength <= GetData()->nAllocLength" etc
|
|
|
|
|
What error does come if you write:
CString cszTest((char*) cCoffee);
please ? Check your definition of Irrationality[ ^]
1 - Avicenna
5 - Hubbard
3 - Own definition
|
|
|
|
|
Ooops, I seemed to have missed this message.
No error, actually!
I hope it is fully solved, but I need to check something else...
|
|
|
|
|
Yes, you can use the CString to convert any char* directly Check your definition of Irrationality[ ^]
1 - Avicenna
5 - Hubbard
3 - Own definition
|
|
|
|
|
Cool, but I found the reverse problem as well.
I'm loading up cCoffee from a CString as well and messed that up so only the first character was copied:
CopyMemory(cCoffee, strOriginal.GetBuffer(), strOriginal.GetLength());
I understand this is wrong, but I don't know how to fix it.
Please help!
(Basically, I'm going from CString -> signed char* -> CString. Probably not a nice thing to do, but I'm stuck with it for the time being...)
|
|
|
|
|
You could use the macro T2A to "go back" Check your definition of Irrationality[ ^]
1 - Avicenna
5 - Hubbard
3 - Own definition
|
|
|
|
|
I get error C2065 if I do
CString strOriginal;
cCoffee = T2A(strOriginal);
|
|
|
|
|
#include <AtlConv.h>
{
...
USES_CONVERSION;
char* pchTempResult = T2A(cszYourString);
strncpy(cCoffee, pchTempResult, _countof(cCoffee));
...
} Check your definition of Irrationality[ ^]
1 - Avicenna
5 - Hubbard
3 - Own definition
|
|
|
|
|
Thanks.
Nearly, but not quite, I still have error C2664.
The problem seems to be strncpy .
It complains about not being able to turn signed char* into char* .
But I used CopyMemory instead and it worked!!
Thanks a million!!
|
|
|
|