Click here to Skip to main content
15,911,786 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Load & read the XML File Pin
Amit Agarrwal3-Apr-06 2:44
Amit Agarrwal3-Apr-06 2:44 
GeneralRe: Load & read the XML File Pin
thatsme_cool3-Apr-06 2:51
thatsme_cool3-Apr-06 2:51 
GeneralRe: Load & read the XML File Pin
Amit Agarrwal3-Apr-06 3:06
Amit Agarrwal3-Apr-06 3:06 
GeneralRe: Load & read the XML File Pin
thatsme_cool3-Apr-06 3:11
thatsme_cool3-Apr-06 3:11 
GeneralRe: Load & read the XML File Pin
Amit Agarrwal3-Apr-06 3:18
Amit Agarrwal3-Apr-06 3:18 
GeneralRe: Load & read the XML File Pin
thatsme_cool3-Apr-06 3:30
thatsme_cool3-Apr-06 3:30 
GeneralRe: Load & read the XML File Pin
thatsme_cool3-Apr-06 3:39
thatsme_cool3-Apr-06 3:39 
GeneralRe: Load & read the XML File Pin
Amit Agarrwal3-Apr-06 18:35
Amit Agarrwal3-Apr-06 18:35 
hi dude
Gud Morning.
how r u?

i have already mailed u i hope u read it. yaar problem solve hi nahi ho rahi hai.jaisa aone kaha th maine waisa hi kiya.....lekin ek confusion hai..

ex:
class YourClass
{
public:
CComBSTR m_bstrFileName;
IXMLDOMDocument* m_pIDomDoc;
OpenXmlFile(...);
GetElement(...)
.....
...
};
now u'll do following
USES_CONVERSION;
m_bstrFileName = "E:\WorkingBigBoss\BigBossApp\books.xml";
GetElement(_T("Username"), bstrVal);
CString strTemp = W2A(bstrVal);
AfxMessageBox(strTemp);

maine is code ko use kiya aur m_bstrFileName aur bstrval ko CCombBStr declare kar diya....is code mein aapne openXMlFile ka function declare to kiya hai..lekin call nahi kiya hai..maine bhi aise hi kiya..ye jo m_bstrFile Name variable hai ye use kaise ho raha hai i mean ye second function se Link kaise ho raha hai.....i hope app meri problem ko samagh gaye ho gaye honge bro.

i'm seding u my updated code too:-
void CMainFrame::OnLoadxmlLoadxmlfile()
{
// TODO: Add your command handler code here
//if(OpenXMLFile("E:\WorkingBigBoss\BigBossApp\books.xml"))
//m_bstrFileName = "E:\WorkingBigBoss\BigBossApp\books.xml";

USES_CONVERSION;
CComBSTR m_bstrFileName;
m_bstrFileName = "E:\WorkingBigBoss\BigBossApp\books.xml";
//OpenXMLFile(m_bstrFileName);

if(GetElement(_T("Username"), bstr))
{
CString strTemp = W2A(bstr);
AfxMessageBox(strTemp);
}

jab main ise run karat hun to ye Run time error deta hai..i don't know why??
i 'll wait for ur reply

gud day
Aavesh





Aavesh
GeneralRe: Load & read the XML File Pin
thatsme_cool3-Apr-06 20:01
thatsme_cool3-Apr-06 20:01 
GeneralRe: Load & read the XML File Pin
Amit Agarrwal3-Apr-06 21:50
Amit Agarrwal3-Apr-06 21:50 
GeneralRe: Load & read the XML File Pin
thatsme_cool3-Apr-06 23:27
thatsme_cool3-Apr-06 23:27 
GeneralRe: Load & read the XML File Pin
thatsme_cool4-Apr-06 0:19
thatsme_cool4-Apr-06 0:19 
GeneralRe: Load & read the XML File Pin
Amit Agarrwal4-Apr-06 0:54
Amit Agarrwal4-Apr-06 0:54 
GeneralRe: Load & read the XML File Pin
thatsme_cool4-Apr-06 1:41
thatsme_cool4-Apr-06 1:41 
GeneralRe: Load & read the XML File Pin
Amit Agarrwal4-Apr-06 1:57
Amit Agarrwal4-Apr-06 1:57 
GeneralRe: Load & read the XML File Pin
thatsme_cool4-Apr-06 2:30
thatsme_cool4-Apr-06 2:30 
GeneralRe: Load & read the XML File Pin
Amit Agarrwal4-Apr-06 2:44
Amit Agarrwal4-Apr-06 2:44 
GeneralRe: Load & read the XML File Pin
thatsme_cool4-Apr-06 3:08
thatsme_cool4-Apr-06 3:08 
AnswerRe: Load & read the XML File Pin
ThatsAlok3-Apr-06 8:16
ThatsAlok3-Apr-06 8:16 
QuestionA stupid question regarding buttons Pin
llp00na3-Apr-06 2:01
llp00na3-Apr-06 2:01 
AnswerRe: A stupid question regarding buttons Pin
Nibu babu thomas3-Apr-06 2:06
Nibu babu thomas3-Apr-06 2:06 
AnswerRe: A stupid question regarding buttons Pin
Laxman Auti3-Apr-06 2:19
Laxman Auti3-Apr-06 2:19 
AnswerRe: A stupid question regarding buttons Pin
Hamid_RT3-Apr-06 2:25
Hamid_RT3-Apr-06 2:25 
AnswerRe: A stupid question regarding buttons Pin
Ganesh_T3-Apr-06 2:41
Ganesh_T3-Apr-06 2:41 
AnswerRe: A stupid question regarding buttons Pin
llp00na3-Apr-06 3:49
llp00na3-Apr-06 3:49 

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.