471,594 Members | 1,780 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,594 software developers and data experts.

UrlDecode in C++?

Hi

I want to use UrlDecode() in C++. I have a Visual C++ (.NET) Win32 project
#using <mscorlib.dll
#using <System.dll
#using <System.Web.dll

using namespace System
using namespace System::Web

void dummy(

...
path = UrlDecode(path)
When I build the project I got error: "fatal error C1190: managed targeted code requires '#using <mscorlib.dll>' and '/clr' option". But I already am using it. Could any one tell me what I am missing? Many Thanks

Yifan
Nov 17 '05 #1
5 5576
Are you sure you have set the /clr switch?

--

Regards,
Nish [VC++ MVP]

"Yifan" <an*******@discussions.microsoft.com> wrote in message
news:14**********************************@microsof t.com...
Hi,

I want to use UrlDecode() in C++. I have a Visual C++ (.NET) Win32 project. #using <mscorlib.dll>
#using <System.dll>
#using <System.Web.dll>

using namespace System;
using namespace System::Web;

void dummy()
{
...
path = UrlDecode(path);
}

When I build the project I got error: "fatal error C1190: managed targeted code requires '#using <mscorlib.dll>' and '/clr' option". But I already am
using it. Could any one tell me what I am missing? Many Thanks!
Yifan

Nov 17 '05 #2
I am afraid I have not set the /clr switch. How do I set the /clr switch in .NET? Thanks!

Yifan
Nov 17 '05 #3
Enable the "Use Managed Extensions" option in the project properties.

--

Regards,
Nish [VC++ MVP]

"Yifan" <an*******@discussions.microsoft.com> wrote in message
news:21**********************************@microsof t.com...
I am afraid I have not set the /clr switch. How do I set the /clr switch in .NET? Thanks!
Yifan

Nov 17 '05 #4
Hi Nishant

Thanks for the reply. Now the original error goes away. But when I build it, I got Command line error D2016 : '/RTC1' and '/clr' command-line options are incompatible. I have no idea what item in the project property controls the setting of '/RTC1' option. Any idea? Thanks

Yifan
Nov 17 '05 #5
Hi Nishan
i have the same problem and i solve it in the following way
1) Go To ---Project Property->Configuration Property --->c/c++ --->/cl
2) Go To ---Project Property->Configuration Property --->Code Generation-->Basic Runtime Checks-->Default
3) Go To ---Project Property->Configuration Property --->Code Generation-->Enable Minimal Rebuild--> N
4) Go To ---Project Property->Configuration Property --->c/c++ -->General-->Debug Information Format-->Program Database (/Zi
5) Go To ---Project Property->Configuration Property --->Code Generation-->Runtime Library--><inherit from project defaults

those settings solve the proble

have a nice day
Gabi
Nov 17 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Thomas Henz | last post: by
reply views Thread by Yifan | last post: by
1 post views Thread by João Santa Bárbara | last post: by
4 posts views Thread by John Hoge | last post: by
6 posts views Thread by John Grandy | last post: by
10 posts views Thread by Alex | last post: by
1 post views Thread by fjm67 | last post: by
3 posts views Thread by gert | last post: by
reply views Thread by XIAOLAOHU | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.