Click here to Skip to main content
15,889,992 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: OnHScroll --- further question Pin
Ravi Bhavnani20-Oct-03 10:07
professionalRavi Bhavnani20-Oct-03 10:07 
GeneralRe: OnHScroll --- further question Pin
Rafael Fernández López20-Oct-03 6:34
Rafael Fernández López20-Oct-03 6:34 
Generalaccelerators and mdi Pin
godzooky20-Oct-03 4:35
godzooky20-Oct-03 4:35 
GeneralRe: accelerators and mdi Pin
Ravi Bhavnani20-Oct-03 6:16
professionalRavi Bhavnani20-Oct-03 6:16 
GeneralRe: accelerators and mdi Pin
godzooky20-Oct-03 7:06
godzooky20-Oct-03 7:06 
GeneralRe: accelerators and mdi Pin
Ravi Bhavnani20-Oct-03 7:12
professionalRavi Bhavnani20-Oct-03 7:12 
GeneralRe: accelerators and mdi Pin
godzooky21-Oct-03 2:31
godzooky21-Oct-03 2:31 
GeneralHelp w/ MSI access in VC++ Pin
badsmonkey20-Oct-03 4:24
badsmonkey20-Oct-03 4:24 
Hi all,
Hoping for a little help with accessing portions of an .msi database from within C++ code. There are functions to access the various tables in the MFC, but for some reason I can not get them to work. So far my code is just a test that declares and MSIHANDLE and attempts to call MsiOpenDatabase. It looks like this:
#include <atlbase.h>
#include <msiquery.h>
#include <fstream>
#include <iostream>
#include <iomanip>
#include <string>
#include <vector>

using namespace std;

int main (int argc, char **argv){

LPCSTR dbPath = "\\SRV1.msi";
LPCSTR dpPerm = "MSIDBOPEN_READONLY";
PMSIHANDLE m_h;

MsiOpenDatabase(dbPath, dpPerm, &m_h);
...


For some reason, this perpetually throws LNK2001 errors (specifically _MsiOpenDatabaseA@12 and _MsiCloseHandle@4). As I'm only using MFC and ATL classes, I'm confused. Any suggestions?
GeneralRe: Help w/ MSI access in VC++ Pin
Michael P Butler20-Oct-03 4:42
Michael P Butler20-Oct-03 4:42 
GeneralRe: Help w/ MSI access in VC++ Pin
badsmonkey20-Oct-03 5:18
badsmonkey20-Oct-03 5:18 
GeneralTextArea like in Word Pin
huub20-Oct-03 4:20
huub20-Oct-03 4:20 
GeneralCMDIChildWnd and close-all functionality q. Pin
Maximilien20-Oct-03 3:35
Maximilien20-Oct-03 3:35 
GeneralUNICODE Pin
sinanswedani20-Oct-03 3:13
sinanswedani20-Oct-03 3:13 
GeneralRe: UNICODE Pin
E2120-Oct-03 3:46
E2120-Oct-03 3:46 
GeneralRe: UNICODE Pin
sinanswedani20-Oct-03 4:08
sinanswedani20-Oct-03 4:08 
GeneralRe: UNICODE Pin
E2120-Oct-03 21:52
E2120-Oct-03 21:52 
GeneralRe: how to burn CD Pin
Dominik Reichl20-Oct-03 2:31
Dominik Reichl20-Oct-03 2:31 
GeneralRe: how to burn CD Pin
Rafael Fernández López20-Oct-03 5:46
Rafael Fernández López20-Oct-03 5:46 
GeneralFunction Pin
Anonymous20-Oct-03 2:12
Anonymous20-Oct-03 2:12 
GeneralRe: Function Pin
Alexander M.,20-Oct-03 2:38
Alexander M.,20-Oct-03 2:38 
GeneralFunction Pin
Anonymous20-Oct-03 2:11
Anonymous20-Oct-03 2:11 
GeneralCListCtrl Icon mode Pin
MaxiGroovy20-Oct-03 1:49
MaxiGroovy20-Oct-03 1:49 
GeneralRe: CListCtrl Icon mode Pin
Rafael Fernández López20-Oct-03 2:07
Rafael Fernández López20-Oct-03 2:07 
GeneralRe: CListCtrl Icon mode Pin
MaxiGroovy20-Oct-03 2:15
MaxiGroovy20-Oct-03 2:15 
GeneralRe: CListCtrl Icon mode Pin
Rafael Fernández López20-Oct-03 2:21
Rafael Fernández López20-Oct-03 2:21 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.