Psst! Did you know DevelopmentNow is a mobile web site design agency?

Contact us for help mobilizing your site, or to sign up for our beta Mobile Web SDK!


Archived Months
June 2003
July 2003
August 2003
September 2003
October 2003
November 2003
December 2003
January 2004
February 2004
March 2004
April 2004
May 2004
June 2004
July 2004
August 2004
September 2004
October 2004
November 2004
December 2004
January 2005
February 2005
March 2005
April 2005
May 2005
June 2005
July 2005
August 2005
September 2005
October 2005
November 2005
December 2005
January 2006
February 2006
March 2006
April 2006
May 2006
June 2006
July 2006
August 2006
September 2006
October 2006
November 2006
December 2006
January 2007
February 2007
March 2007
April 2007
May 2007
June 2007
July 2007
August 2007
September 2007
October 2007
November 2007
all groups > visual c > february 2007

Filter by week: 1 2 3 4

Create pop3 mail account problem
Posted by su haiqing at 2/28/2007 9:38:32 PM
Hi All, Is there a Windows API function used to create a pop3 mail account for Win server 2003. I just know an ADSI method to implement this. Thanks, Su ...more >>


Refering a header file of unmanaged project in managed project
Posted by Sarwan at 2/28/2007 4:33:12 AM
Hello everybody I have a solution in which there is an unmanaged MFC application. Then i added a new managed .Net Windows Form application. I was trying to refer an header file of unmanaged project into the my managed project. But it leads to link error. Form1.obj : error LNK2001: unresolve...more >>

GetIDispatchForObject / exposing an object to a scripting client
Posted by mclp at 2/28/2007 2:51:56 AM
I have an object created within a C++/CLI class library that I want to expose to a VBScript client. The class is declared as: [ClassInterface(ClassInterfaceType::AutoDispatch)] public ref class Foo { public: // some methods... }; The object is constructed using Foo^ foo = gcnew Foo; Th...more >>

SmtpClient problem
Posted by Torben Laursen at 2/27/2007 11:21:21 PM
My program needs to be able to send e-mails back to me. It is all working fine. I use my own SMTP server with username and password given. But on some customers computers I get the error: "Mailbox name not allowed. The server response was: sorry, that domain isn't allowed to be relayed thru ...more >>

NetGroupAdd ERROR_ACCESS_DENIED problem
Posted by su haiqing at 2/27/2007 10:54:28 PM
Hi All, I am trying to use NetGroupAdd() to create a group on my computer, but it always return ERROR_ACCESS_DENIED. Do you guys know how to resolve the problem? (Windows Xp sp3) ///code here _GROUP_INFO_0 groupInfo; DWORD param_err; NET_API_STATUS sResult; ZeroMemory(&groupInfo,...more >>

Retrieving drive letter using device name
Posted by Priya at 2/27/2007 6:27:33 AM
Hi, Could someone tell me how to retrieve a drive's drive letter from user mode given its device name? Any information is greatly appreciated. Thanks, Priya...more >>

bison and flex in visual stdio 2005
Posted by eng.sharif NO[at]SPAM gmail.com at 2/27/2007 12:30:16 AM
want use bison and flex in visual stdio 2005 for make small compiler by use Custom Build Rules in Visual C++ 2005 "FlexBison.rules file " but when i compile "example.y" i get error ---------------------------------------------------------------------------= =AD--------------- bison.simple...more >>

frustrating parameter issue
Posted by Vinz at 2/26/2007 11:40:55 PM
Hello everyone, My question is part C# and part C++. Please don't kill me for bringing C# inhere :-) Also please don't kill me for asking a n00b question, I'm still new to C++/CLI and C#. I have an assembly written in C++/CLI with a public function: int MyClass::MyFunction(String ^x) ...more >>



C++/CLI How to I store Associated Data on ComboBox Item?
Posted by JEKATICH at 2/26/2007 8:33:59 PM
How do I store associated data on a ComboBox item (ToolStripComboBox)? The API and MFC has a (Set/Get)ItemData(Ptr), however, I do not see any such animal in .NET. Thanks JEK ...more >>

error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
Posted by Bit Byte at 2/26/2007 3:16:59 PM
The following function pointer declarations used to compile without any problems in VS7.1, now when I try to compile in VS8, I get a C4430 error. Anyone knows why, and how to fix it (without using pragma disable)? //My header file ... /* Prototypes for subscription callbacks */ typedef vo...more >>

Problem
Posted by renbin at 2/26/2007 12:00:00 AM
Now I have a problem. I have some code like this: void SetFieldName(LPCTSTR lpszNewValue) { char szFieldName[11]; strcpy(szFieldName,lpszNewValue); } When I debug it,the System tells me "Error 1 error C2664: 'strcpy' : cannot convert parameter 2 from 'LPCTSTR' to 'const char *' ...more >>

C++/CLI parameter type conversion
Posted by vijay.gandhi NO[at]SPAM gmail.com at 2/25/2007 9:41:07 PM
Hello, I am trying to write a wrapper function in C++/CLI over an existing function in C++. For instance, assume the C++ function is: ComputeMedian(double* x). To create a C++/CLI wrapper, I created a function in C++/CLI which looks like: ComputeMedianInterface(array<double>^ x). I w...more >>

identifier not found error, undeclared identifier
Posted by aarthi28 NO[at]SPAM gmail.com at 2/25/2007 3:28:36 PM
Hi, I have this code that I am trying to compile, but I am getting the following errors 'CoInitializeSecurity': identifier not found 'EOAC_NONE' : undeclared identifier I have pasted the code below // Using_WMI1.cpp : Defines the entry point for the console application. // #include ...more >>

Simple Question - Passing Arrays to Functions
Posted by Rich at 2/25/2007 6:22:10 AM
I need to pass an array from C# to a managed C++ function (that will in turn call unmanaged C code). My knowledge of managed C++ syntax is limited (obviously). This needs to be a reference parameter so the function can change the contents of the array and give it back to the caller. How sho...more >>

Handle to an opened form
Posted by Tomas at 2/25/2007 12:32:13 AM
Hi, I have an C++/CLI MDI application with two Forms A and B. When I work with Form A I would like to know the handle of Form B (if it is opened), to use its handle in a delegate that execute a function in Form B. In example: DelegateAbc^ d = gcnew DelegateAbc(HANDLE,&FormB::TestB); ...more >>

error LNK2001: unresolved external symbol "extern "C" ...
Posted by Mateusz Rajca at 2/24/2007 3:45:05 PM
Hi! How can I fix this error? Error 1 error LNK2001: unresolved external symbol "extern "C" long __stdcall SHFlushClipboard(void)" (?SHFlushClipboard@@$$J10YGJXZ) UnmanagedTest.obj Basically I am calling the SHFlushClipboard method from "shlobj.h" (Win32) in a managed c++ app. ~Matt...more >>

Dependency walker msvcr80d.dll missing coredll.dll and dwmapi.dll
Posted by phnimx at 2/23/2007 6:43:24 PM
I've completed migrating one of our company's C++ Managed Code applications to VS2005. I'm now attempting to run the application but there seems to be problems when accessing an object that is properly exported from a utility dll of ours. The dll is written in MFC with sections of C++ Ma...more >>

A VERY VERY HARD QUESTION ABOUT THE LINKER
Posted by Sean Connery at 2/23/2007 2:46:08 PM
Sorry, its Friday and beautiful out.. Anyway, is there a way to ignore specific warnings in the linker like you can with the compiler? I compile with /WX mostly to ensure that people don't accidentally mix runtimes and want the ability to ignore other warnings. Thanks! Sean Connery...more >>

Converting unmanaged struct -> CLI value struct
Posted by DaTurk at 2/23/2007 1:08:08 PM
I'm having an issue converting an unmanaged struct to a CLI managed struct. It's a value struct and this cannot be changed. [StructLayout(LayoutKind::Sequential, CharSet=CharSet::Ansi, Pack=1)] public value struct UpdateItem { public: [MarshalAs(UnmanagedType::ByValTStr, SizeConst...more >>

Get CPU Fan Speed and CPU Temp
Posted by Mike C# at 2/23/2007 9:51:49 AM
Hi all, anyone know if there are any Windows functions to retrieve CPU Fan Speed and CPU Temp? Or if it's a BIOS-level call, or something else? If someone out there could just point me in the right direction it would be appreciated. Thanks! ...more >>

Read Excel lines with C++
Posted by GBvdH at 2/23/2007 6:12:14 AM
Hello, Does anyone happen to know if there is a relatively easy way to read lines of an Excel spreadsheet in C++. I am not a real programming pro so I hope it will not be to hard? Please tell me if I should post this question in an other discussion group. Barry ...more >>

from "general" c++ 2 visual c++ managed
Posted by Willi at 2/23/2007 5:03:25 AM
hi! developing few command line programs using c++ and gcc I gained experiences with c++. Now I want to use DevStudio 2005, VC++ and develop .NET application using the MFC, that I haven't used before as well. Do you know a good tutorial? thank you in advance!...more >>

Converting const char * -> System::String^ without gcnew.
Posted by DaTurk at 2/22/2007 3:02:27 PM
Hi, I have several interfaces in CLI that I access via c#. My problem is, is that down in the unmanaged c++, which the CLI lies on top of, I have a lot of c_str() happening. But all of my methods in CLI return System::String^. I originally just gcnew'd System::String^ passing in the c_str(...more >>

VS2003 Runtimes
Posted by annapolis at 2/22/2007 9:41:10 AM
My customer claims he has 2 DLLs with versions that are not listed on the DLL Help Database. We developed our product with Visual Studio 2003, Native Win32. How can I find what MS product ( I suspect Visual Studio 2005) included these versions? Customer DLL H...more >>

CLI compilation problem
Posted by DaTurk at 2/22/2007 7:35:34 AM
Hi, I have a strange issue. I'm pretty sure it's just some strage configuration issue. I have a solution with a couple CLI projects, and a couple unmanged c++ projects. When I clean, and rebuild the build breaks. During this build I see it copying the files it has a dependency on lacally,...more >>

How to use VS2005 ClassLibrary in old MFC project?
Posted by Janus at 2/22/2007 12:00:00 AM
Hi all, I've got a third party class library that i want to use in an 'old' MFC project (actually i need it in a Borland C++ builder project, but if i can use it in MFC i propably can convert it to Borland.) Because i only need 3 methods of the third party dll i want to create a C++ ClassLi...more >>

Callback functions in c++ with managed extensions
Posted by Paul W at 2/21/2007 7:08:16 PM
Hi everybody, This may seem like a Shell question, but I believe it belongs here. I'm trying to make a wrapper class for the SHBrowseForFolder function. This function provides for a callback to your code for certain situations. I've done this in c# but can't seem to get it to work here. ...more >>

ERROR 5553
Posted by microslug at 2/21/2007 5:34:13 PM
Error: Mail could not be sent using the account "Tim Burke" Explanation: relaying denied Error: 5553 Sometimes the error comes up, and sometimes it doesn't and I can send emails. I've contacted my my service providers and confirmed that all the information is correct. I've tried using va...more >>

MsBuild, .NET 2.0 and C++ not building correctly
Posted by DaTurk at 2/21/2007 8:15:34 AM
Hi, I've just converted all of my managed and unmanaged c++ to .NET 2.0. Now I'm trying to add these solutions to the MsBuild script and for some reason it seems as though the post build events are happening. I had these solutions formaly being built under nant, and they built fine, although...more >>

VC2005 C++/CLI VB.NET byref unmanaged interop
Posted by mclp at 2/21/2007 4:05:50 AM
Hi. Just joined this group and I don't think this had been addressed before.. I have a VB.NET class library assembly "xyz.dll" that I want to access from some unmanaged code in an MFC DLL (contained in a cpp file compiled with /clr) via: #include <vcclr.h> #using "xyz.dll" using namespace...more >>

String^, const char*, std::string, and c_str( )
Posted by Kevin Frey at 2/21/2007 12:00:00 AM
I am porting Managed C++ code from VS2003 to VS2005. Therefore adopting the new C++/CLI syntax rather than /clr:oldSyntax. Much of our managed code is concerned with interfacing to native C++ code (ie. wrappers etc). In Managed C++ there was an automatic conversion between const char* and S...more >>

I am a fresh Visual C++ .NET Developer. Convert char[1024] to System::String
Posted by simon NO[at]SPAM simon-john.com at 2/20/2007 4:41:55 PM
I am a fresh Visual C++ .NET Developer. Can you kindly guide me for How to Convert char[1024] to System::String I am using windows forms and trying to set a text value referencing the method className() of an object of class HetConvert (my own) this returns a char - which as you can see from ...more >>

Screen Saver Fails to Start
Posted by Jim Ormsbee at 2/20/2007 7:41:01 AM
Hopefully my solution will help others. I have a MacBook Pro on which I am running WindowsXP Home Edition. It is running totally separate from the Mac OS. I have to reboot to switch between OS's. After running my system for about 3 months successfully with a combination Microsoft wireless mous...more >>

STL & C++ CLI
Posted by Frank Kuhn at 2/20/2007 1:31:59 AM
Hi, i need the fast power of STL and the connection to .NET and C#. I want to use my C++ library in a C# Application. Does someone has the same problem? And or has solved this Problem ? If i use a non managed code i get an error, that i cand used a mixed type. Thankx, Frank ...more >>

RC2104 error on #ifdef
Posted by David W at 2/20/2007 12:00:00 AM
Hello, In a C++ MFC application I need to conditionally #include one of two additional resource files in my main resource file because different forms of the application have different names. I would also like to edit the main resource file with the IDE's resource editor and save it without...more >>

import emails
Posted by Nick C at 2/20/2007 12:00:00 AM
Hi I am trying to import emails from a webserver. This code retrieves only 1 email. I also would like to save them into an xml file? thanks N Request = (System.Net.HttpWebRequest)HttpWebRequest.Create("http://email-server/Exchange/account/Inbox/EmailSubject.EML"); Request.Credent...more >>

Exception Catching difference between VC++ and C#
Posted by fischermx NO[at]SPAM gmail.com at 2/19/2007 1:10:31 PM
Exception Catching difference between VC++ and C# In C# I have this: try { int x, y, z; x = 20; y = 0; z = x / y; } catch { Console.WriteLine("oops !"); } And it nicely catches whatever error happens inside the try block. But now in C++ I...more >>

Wierd mixed c++ assembly problem.
Posted by Mike Smith at 2/19/2007 10:18:29 AM
We are having an issue where .NET assemblies are inconsistently being found/not found. On some runs, everything runs fine. On other runs, we get exceptions saying that one of our assemblies was not found. Also, if we were to do a Search using Windows Explorer, sometimes the assembly show up...more >>

From native to managed
Posted by Erik_Wikstr=F6m at 2/19/2007 5:00:46 AM
I'm working on a project where all the current code is written in standard compliant C++ with no dependencies on any external libraries except the standard library. The application is used to perform simulations of thermal radiation and is highly performance sensitive and as such we have no plan...more >>

Drawing in Windows Vista.....
Posted by nileshkontamwar NO[at]SPAM gmail.com at 2/19/2007 3:28:11 AM
will anybody tell me, why drawing is slow in windows vista as compared to windows vista..... i m running an application of moving a rectangle,....... i observed that rectangle drawing is slow in windows vista......... i will be thankfull if anybody clarifies where i m wrong....or is this the p...more >>

register contorl (dll) ?
Posted by Anu at 2/19/2007 12:04:12 AM
Hi, I have a shell extension in VS 6. I am porting the code to VS 2005. After porting, how can I register the dll from IDE? In VS 6, there is a option to register control from tools menu but I could not find the similar option in VS 2005. I am very new to this. So, please help me. Also, when...more >>

Windows and Forms
Posted by Allen Maki at 2/19/2007 12:00:00 AM
Hi Everybody, I need your help. I have MS Visual Studio .NET 2003. I noticed that if I added a context menu to a form. It will not work, unless you add the line: This ->ContextMenu = this->contextMenu; manually. Can anybody tell me why? IF you have the book ...more >>

linker error in template instance
Posted by antani at 2/18/2007 8:14:42 AM
When I add to my code this line vcg::tri::io::Importer<CMesh>::Open(mesh,"mesh.ply"); I get a linker error. Please help me. I tested a qt empty project with only main function. I added the incriminate line of code and work correctly. mi error LNK2019: unresolved external symbol "privat...more >>

The effect of "^"
Posted by Maxim at 2/18/2007 3:45:34 AM
Hi, All! What is the effect of using ^ with the managed type? I'm trying to create a class library in managed c++. There is a class: public ref class MyClass { public: IntPtr^ WindowHandle; int^ SomeNumber; }; When I use this class in another project (C#) it is shown as ...more >>

converting a console application to a dll
Posted by Sarwan at 2/17/2007 4:15:10 AM
I want to convert a vc++ console application having UI forms to a dynamic library or a static libray in .Net, where can i find such procedure for converting. ...more >>

Exception type
Posted by Maxim at 2/17/2007 2:48:25 AM
Hi, All! How do I get unmanaged exception type in the catch block. Here's the piece of code to clarify my question. try { throw int(1); } catch(Exception^ ex) { ............. } How do I get the type (int) and the value (1) of the exception thrown? Thanks in advance ...more >>

abstract sealed & literal
Posted by Vedo at 2/17/2007 12:00:00 AM
ref struct XXX abstract sealed { literal int A = 5; }; The definition above gives me the compiler warning "C4693: a sealed abstract class cannot have any instance members 'A'". The equivalent definition is perfectly legal in other CLR languages. For example in C#; static class XXX ...more >>

How do I return a NULL reference?
Posted by Jeremy Chaney at 2/16/2007 5:13:53 PM
Forgive me if this is a dumb question. It seems like such a simple thing that I shouldn't have to ask, but alas, I can't seem to figure it out. I'm porting some C++ code to MC++ and I have a function that formerly returned either a valid pointer, or NULL. In MC++, how do I return NULL? If I tr...more >>

help Recording with Microphone
Posted by Debbie at 2/16/2007 5:04:05 PM
Hi I have Windows XP Media Edition, would like to learn how to record my granddaugter singing onto a CD, or if I have to download first onto the hard drive. Either way need help as to the steps to do either of these. -- Thanks Debbie...more >>

Why does .NET raise_XXX proxy code lock on a mutex.
Posted by daniel NO[at]SPAM mfaconsulting.com at 2/16/2007 7:56:05 AM
Maybe I'm not understanding things. I have a multi-threaded callback producer (Unmanaged C++), which fires into a managed proxy class, which in turn calls into a managed C++ consumer (mixed mode DLL). From the managed C++ class I have defined __events, which are consumed by a C# class. This wo...more >>


DevelopmentNow Blog