|
|
KarstenK wrote: Anybody wont do your work
Greetings from Germany
I found those two consecutive lines to be funny.
Many are stubborn in pursuit of the path they have chosen, few in pursuit of the goal - Friedrich Nietzsche
.·´¯`·->Rajesh<-·´¯`·.
[Microsoft MVP - Visual C++]
|
|
|
|
|
|
You can also use of MCI functions.
|
|
|
|
|
Hi..
I have to run/display an html file in a default browser how can i achive this. plz can anyone help me..
|
|
|
|
|
If you open a file with ShellExecute()[^], it will be opened by the default program associated with it. The file can also be a HTML file.
Many are stubborn in pursuit of the path they have chosen, few in pursuit of the goal - Friedrich Nietzsche
.·´¯`·->Rajesh<-·´¯`·.
[Microsoft MVP - Visual C++]
|
|
|
|
|
Hi all,
I have created a System DSN successfully with the help of odbcconf.exe ,
Create with this ::
odbcconf.exe /a {CONFIGSYSDSN ""Microsoft Access Driver (*.mdb)"" ""DSN=SFDB;DBQ=C:\test.mdb;"" Description=PRI_SD_ODBC}"
now please tell me how can i remove this programaticaly.
Please help me for this .
Thanks in advance.
IN A DAY, WHEN YOU DON'T COME ACROSS ANY PROBLEMS - YOU CAN BE SURE THAT YOU ARE TRAVELLING IN A WRONG PATH
modified on Wednesday, August 20, 2008 3:49 AM
|
|
|
|
|
Use SQLConfigDataSource() with ODBC_REMOVE_DSN.
Many are stubborn in pursuit of the path they have chosen, few in pursuit of the goal - Friedrich Nietzsche
.·´¯`·->Rajesh<-·´¯`·.
[Microsoft MVP - Visual C++]
|
|
|
|
|
Hi,
I am usinf the CRegKey class of ATL but when I am compiling it is showing the error
error C2039: 'QueryStringValue' : is not a member of 'CRegKey'
C:\Program Files\Microsoft Visual Studio\VC98\ATL\INCLUDE\atlbase.h(4714) : see declaration of 'CRegKey'
Can anybody tell me whats the problem.
Thanks in advance.
Dhiraj Kumar Saini
|
|
|
|
|
It seems you forgot to include header file.
|
|
|
|
|
Not the case. Here's the error message again:
C:\Program Files\Microsoft Visual Studio\VC98\ATL\INCLUDE\atlbase.h(4714) : see declaration of 'CRegKey'
It's clear from the error message that the correct header was included.
Steve
|
|
|
|
|
Hi,
Can you tell me which header file to use.
Dhiraj Kumar Saini
|
|
|
|
|
You're already including the correct header. See here[^].
Steve
|
|
|
|
|
Do you check that this function really exists in CRegKey? May be you are using incorrect case somewhere or the function is not really there in the CRegKey. Or could also be the case of a missing header file.
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
modified on Wednesday, August 20, 2008 3:44 AM
|
|
|
|
|
Again and again, you're using the MFC version with ships with Visual Studio 6 and pretending it has the same features of later versions. Can you see QueryStringValue method in this documentation page [^]?
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]
|
|
|
|
|
There is no such method (at least there isn't in MSVC6, which you seem to be using). Here's the definition (which you could have easily found yourself):
class CRegKey
{
public:
CRegKey();
~CRegKey();
public:
operator HKEY() const;
HKEY m_hKey;
public:
LONG SetValue(DWORD dwValue, LPCTSTR lpszValueName);
LONG QueryValue(DWORD& dwValue, LPCTSTR lpszValueName);
LONG QueryValue(LPTSTR szValue, LPCTSTR lpszValueName, DWORD* pdwCount);
LONG SetValue(LPCTSTR lpszValue, LPCTSTR lpszValueName = NULL);
LONG SetKeyValue(LPCTSTR lpszKeyName, LPCTSTR lpszValue, LPCTSTR lpszValueName = NULL);
static LONG WINAPI SetValue(HKEY hKeyParent, LPCTSTR lpszKeyName,
LPCTSTR lpszValue, LPCTSTR lpszValueName = NULL);
LONG Create(HKEY hKeyParent, LPCTSTR lpszKeyName,
LPTSTR lpszClass = REG_NONE, DWORD dwOptions = REG_OPTION_NON_VOLATILE,
REGSAM samDesired = KEY_ALL_ACCESS,
LPSECURITY_ATTRIBUTES lpSecAttr = NULL,
LPDWORD lpdwDisposition = NULL);
LONG Open(HKEY hKeyParent, LPCTSTR lpszKeyName,
REGSAM samDesired = KEY_ALL_ACCESS);
LONG Close();
HKEY Detach();
void Attach(HKEY hKey);
LONG DeleteSubKey(LPCTSTR lpszSubKey);
LONG RecurseDeleteKey(LPCTSTR lpszKey);
LONG DeleteValue(LPCTSTR lpszValue);
};
Steve
|
|
|
|
|
How to post a message from MainFrm to the dialog , psl adv
|
|
|
|
|
Please, don't repeat your questions. Everybody saw your question the first time, no need to post it twice: this is considered rude behavior.
|
|
|
|
|
I am sorry, I thought the secound part in my prevoius post is not answerted
I am sorry again
|
|
|
|
|
Hi all,
i have a application(Exe) which will load 2 dlls A.dll and B.dll, A.dll will create a map table(STL Map object) i have to use this map object in B.dll how should i do this ?
Using pragma Data section or using Memory map files ?
Thanks in advance
|
|
|
|
|
|
This is quite a complicated thing and there are may ways to do it and many pitfalls. If your not sure how to do this (and perhaps even if you are) perhaps it's best to use an existing library such as Boost.Interprocess[^].
Steve
|
|
|
|
|
Vijjuuuuuuuuu........... wrote: Using pragma Data section or using Memory map files ?
If both A.dll and B.dll are in same process, you dont need to share it using #pragma . Just declare the variable as global and export it in the A.dll.
Also you please note the below two points
1. Sharing the data segments using #pragma is used to share a data in a dll across multiple process. Not between two dlls in same process or multiple process.
2. You will not be able to share a map using shared section, because the map will be holding pointers to many dynamically allocated memories, which is valid only in corresponding process. Trying to access it from another process result in access vialotion.
|
|
|
|
|
Thank you very much for you reply naveen and thanks for your note
|
|
|
|
|
I want to pass parameter to dialog,
so that I need them during InitDialog()
and also I wnat to post a messsage from MainFrm to the dialog, when the dialog is active.
Pls advice
|
|
|
|