15,899,475 members
Sign in
Sign in
Email
Password
Forgot your password?
Sign in with
home
articles
Browse Topics
>
Latest Articles
Top Articles
Posting/Update Guidelines
Article Help Forum
Submit an article or tip
Import GitHub Project
Import your Blog
quick answers
Q&A
Ask a Question
View Unanswered Questions
View All Questions
View C# questions
View C++ questions
View Javascript questions
View Visual Basic questions
View Python questions
discussions
forums
CodeProject.AI Server
All Message Boards...
Application Lifecycle
>
Running a Business
Sales / Marketing
Collaboration / Beta Testing
Work Issues
Design and Architecture
Artificial Intelligence
ASP.NET
JavaScript
Internet of Things
C / C++ / MFC
>
ATL / WTL / STL
Managed C++/CLI
C#
Free Tools
Objective-C and Swift
Database
Hardware & Devices
>
System Admin
Hosting and Servers
Java
Linux Programming
Python
.NET (Core and Framework)
Android
iOS
Mobile
WPF
Visual Basic
Web Development
Site Bugs / Suggestions
Spam and Abuse Watch
features
features
Competitions
News
The Insider Newsletter
The Daily Build Newsletter
Newsletter archive
Surveys
CodeProject Stuff
community
lounge
Who's Who
Most Valuable Professionals
The Lounge
The CodeProject Blog
Where I Am: Member Photos
The Insider News
The Weird & The Wonderful
help
?
What is 'CodeProject'?
General FAQ
Ask a Question
Bugs and Suggestions
Article Help Forum
About Us
Search within:
Articles
Quick Answers
Messages
Comments by AsthaS (Top 35 by date)
AsthaS
9-Dec-13 3:16am
View
Hi..
Thanks for the reply, But my problem is still there-
I am using the following code :
string xmlString = "<getcapabilities service="\"WCS\"" version="\"1.0.0\"" xmlns="\"http://www.opengis.net/wcs\"/">";
curl_easy_setopt(m_ptrCurlHandle, CURLOPT_URL,"http://172.21.134.150:8080/geoserver/wcs");
curl_easy_setopt(m_ptrCurlHandle, CURLOPT_POST, 1);
curl_easy_setopt(m_ptrCurlHandle, CURLOPT_POSTFIELDS, xmlString.c_str());
curl_easy_setopt(m_ptrCurlHandle, CURLOPT_POSTFIELDSIZE, xmlString.length());
slist = curl_slist_append(NULL, "Content-Type: text/xml; charset=utf-8");
curl_easy_setopt(m_ptrCurlHandle, CURLOPT_HTTPHEADER, slist);
curl_easy_perform(m_ptrCurlHandle);
curl_easy_cleanup(m_ptrCurlHandle);
Where my desired xml post request is
< GetCapabilities service="WCS" version="1.0.0" xmlns="http://www.opengis.net/wcs"/>
But every time is execute the code it gives me -
< ?xml version="1.0" encoding="UTF-8"?>
< ows:ExceptionReport version="1.0.0"
xsi:schemaLocation="http://www.opengis.net/ows http://172.21.134.150:8080/geoserver/schemas/ows/1.0.0/owsExceptionReport.xsd"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ows="http://www.opengis.net/ows">
< ows:Exception exceptionCode="NoApplicableCode">
<ows:exceptiontext>org.xmlpull.v1.XmlPullParserException: only whitespace content allowed before start tag and not \u0 (position: START_DOCUMENT seen \u0... @1:1)
only whitespace content allowed before start tag and not \u0 (position: START_DOCUMENT seen \u0... @1:1)
as the response. I really don't have the clue what am I doing wrong.
Please help.
AsthaS
9-Dec-13 3:10am
View
Deleted
Hi..
Thanks for the reply, But my problem is still there-
I am using the following code :
string xmlString = "<getcapabilities service="\"WCS\"" version="\"1.0.0\"" xmlns="\"http://www.opengis.net/wcs\"/">";
curl_easy_setopt(m_ptrCurlHandle, CURLOPT_URL,"http://172.21.134.150:8080/geoserver/wcs");
curl_easy_setopt(m_ptrCurlHandle, CURLOPT_POST, 1);
curl_easy_setopt(m_ptrCurlHandle, CURLOPT_POSTFIELDS, xmlString.c_str());
curl_easy_setopt(m_ptrCurlHandle, CURLOPT_POSTFIELDSIZE, xmlString.length());
slist = curl_slist_append(NULL, "Content-Type: text/xml; charset=utf-8");
curl_easy_setopt(m_ptrCurlHandle, CURLOPT_HTTPHEADER, slist);
curl_easy_perform(m_ptrCurlHandle);
curl_easy_cleanup(m_ptrCurlHandle);
Where my desired xml post request is <getcapabilities service="WCS" version="1.0.0" xmlns="http://www.opengis.net/wcs">
But every time is execute the code it gives me -
<ows:exceptionreport version="1.0.0"
="" xsi:schemalocation="http://www.opengis.net/ows http://172.21.134.150:8080/geoserver/schemas/ows/1.0.0/owsExceptionReport.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ows="http://www.opengis.net/ows">
<ows:exception exceptioncode="NoApplicableCode">
<ows:exceptiontext>org.xmlpull.v1.XmlPullParserException: only whitespace content allowed before start tag and not \u0 (position: START_DOCUMENT seen \u0... @1:1)
only whitespace content allowed before start tag and not \u0 (position: START_DOCUMENT seen \u0... @1:1)
as the response. I really don't have the clue what am I doing wrong.
Please help.
AsthaS
6-Dec-13 5:20am
View
Please someone help me out in this.
AsthaS
28-Nov-13 5:49am
View
Ok...Thanks a lot.
AsthaS
28-Nov-13 5:28am
View
Thanks for the reply...I just wanted to know if there is a way by which at the time of parsing of the response file only the comment nodes are ignored altogether. I am not preferring the check for each node option because the response received from the server here is huge, and this will increase the code length. So just wanted to know if there is any other way of achieving this.
AsthaS
27-Nov-13 7:12am
View
Moved to question.
AsthaS
27-Nov-13 6:25am
View
Hi..Thanks for the response. I have improved the question. Hope it can help you help me now...!!
AsthaS
27-Nov-13 6:22am
View
Deleted
Hi..Thanks for the response. I have improved the question. Help it can help you help me now...!!
AsthaS
27-Nov-13 6:16am
View
Deleted
Thanks for the response.
What I am trying to do here is -
1. Hit a server and receive an XML response.
2. Parse the XML response and store the values of the xml tags in some variables.
I am doing it as – (if “cur” is my root node)
cur1 = cur->children->next;
tagValue = (char*)cur1->children->content;
This gives the value “xyz” in the variable “tagValue” if following is the XML received from the server :
<root>
<child>xyz
My problem here is since the response is dependent on the input send it is random, it may or may not have comment nodes at places.
If for some input I get a response as -
<root>
<!--This is a sample response-->
<child>xyz
My code fails. I am clueless what to do.
AsthaS
27-Nov-13 1:46am
View
Please help me out with this...anyone...I am really stuck...!!
AsthaS
21-May-13 5:39am
View
Thanks for the prompt reply...actually I am passing the object pointer to the constructor, and accessing the public members in the other member functions of the class...my doubt is can this be done..?? when i am accessing public members within the constructor the code is working fine..but when i copy the same line in the other member function its giving me "run failed" message.
AsthaS
14-May-13 1:50am
View
This is my sample code :
#ifndef DEMO_CODE_H
#define DEMO_CODE_H
#include < stdio.h >
#include < windows.h >
#include < iostream >
#include "curl/curl.h"
extern "C" __declspec(dllexport) int GetCapabilities();
//;
There is one cpp file which includes the definition of int GetCapabilities() method.
But the error is occurring in the curl.h file which i haven't even touched.
AsthaS
14-May-13 1:48am
View
Deleted
This is my sample code :
#ifndef DEMO_CODE_H
#define DEMO_CODE_H
#include <stdio.h>
#include <windows.h>
#include<iostream>
#include "curl/curl.h"
extern "C" __declspec(dllexport) int GetCapabilities();
//;
There is one cpp file which includes the definition of int GetCapabilities() method.
But the error is occurring in the curl.h file which i haven't even touched.
AsthaS
13-May-13 6:08am
View
i have compiled a simple dll and used it in an application, that was done successfully. The problem occured when i introduced a method which uses LibCurl..!!
AsthaS
11-Apr-13 6:06am
View
Ok thanxx...i guess u have identified the issue well. Will try it with boost library now.
AsthaS
11-Apr-13 5:45am
View
I have tried the code. But the same error--Unable to resolve identifier shared_ptr-- But it works fine if i change shared_ptr with auto_ptr.. :(
AsthaS
11-Apr-13 5:32am
View
I am using netbeans 7.3 with cygwin to run this code. Hope this is not the root of error.
AsthaS
11-Apr-13 5:19am
View
have included #include< memory >. Is there some other header which i need to include for shared_ptr.??
AsthaS
11-Apr-13 5:18am
View
Deleted
have included #include<memory>. Is there some other header which i need to include for shared_ptr.??
AsthaS
11-Apr-13 5:18am
View
Deleted
I have included #include<memory>. Is there some other header which i need to include for shared_ptr.??
AsthaS
11-Apr-13 0:50am
View
Yess..my mistake. it should be the way u wrote it...but still the problem of undefined reference persists.. :(
AsthaS
10-Apr-13 8:34am
View
Thankss ..but i think error is not b'coz of class Person b'coz the compiler is not showing me error in other lines where i have used person. Its giving me error only on this line..
AsthaS
5-Apr-13 8:27am
View
Thanxx Matthew...After a bit of roaming around the facts..I have finally done it..!!
AsthaS
2-Apr-13 7:27am
View
*** C:\\Users\\595849\\Documents\\libCppApplication_1 is dll path
AsthaS
2-Apr-13 7:15am
View
Deleted
Thanxx..!!
Here's the code which I have tried to use my dll...
#include <cstdlib>
#include<iostream>
#include<windows.h>
using namespace std;
/*
*
*/
void CallMyDLL()
{
/* get handle to dll */
HINSTANCE hGetProcIDDLL = LoadLibrary("C:\\mydll.dll");
/* get pointer to the function in the dll*/
FARPROC lpfnGetProcessID = GetProcAddress(HMODULE (hGetProcIDDLL),"demo");
/*
Define the Function in the DLL for reuse. This is just prototyping the dll's function.
A mock of it. Use "stdcall" for maximum compatibility.
*/
typedef void (__stdcall * pICFUNC)();
pICFUNC MyFunction;
MyFunction = pICFUNC(lpfnGetProcessID);
/* The actual call to the function contained in the dll */
MyFunction();
/* Release the Dll */
FreeLibrary(hGetProcIDDLL);
/* The return val from the dll */
}
int main(int argc, char** argv) {
CallMyDLL();
return 0;
}
This code is getting "build successfully".. but when i run this code it says "Run failed"
Note:
Mydll.dll is the name of the dll which i want to use.
demo is the method in the dll, which will simply display a message.
Any help will be appreciated.
AsthaS
2-Apr-13 7:02am
View
Ok .. Thanxx anyways...!!
AsthaS
2-Apr-13 5:12am
View
Consume is just a word that i used...My purpose for posting this question was just to get my problem solved(which I am not able to find yet) and not to get instructions for what to do and what not to...
PS- don't take it personally..but i really want a solution thats it.
AsthaS
2-Apr-13 2:36am
View
I am becoming greedy...can u please help me on how can i consume this dll in my code. Thanxx in advance.!!
AsthaS
2-Apr-13 2:25am
View
I am new to this forum and mind you i wasn't aware that this forum had such norms.
AsthaS
2-Apr-13 1:00am
View
Thanxx a lot... Finally It worked....:)
AsthaS
1-Apr-13 8:06am
View
I have tried it. But its taking infinite time. I don't know what actually the problem is?? M totally clueless.
AsthaS
29-Mar-13 7:35am
View
Does netbeans 7.3 provides any option by which I can generate makefile of the application directly.?
AsthaS
29-Mar-13 7:19am
View
Thanx for the reply. I am a newbie to the cross platform development and am using cygwin for compiling my c++ code in netbeans. What I want to know is will g++,gcc,gdb and make which are accompanied in cygwin suffice for cross platform development or will I require some other libraries too.
AsthaS
26-Mar-13 6:40am
View
I have explored about this but I am little confused. Do I need to download and install g++, gcc, make, cygwin and gdb seprately ? And if it is so can how to set the path for all this. Your help will really be valuable.
Thanks
AsthaS
26-Mar-13 2:51am
View
I want to develop my code in visual studio and want to make it cross platform.
Show More