|
Hello, I'm not sure which topic to post this kind of problem.
If I ask on the wrong board, please let me know.
I write a windows form project with CLR supporting, and I want to
package it into an exe file.
I run the exe file in the Debug folder. It works on my computer, but not on other's computer which doesn't install .NET.
But I want the exe file to be portable and without install.
It seems that it needs a .NET environment.
I try to install .net framework 2.0 to the computer which doesn't install Microsoft Visual Studio 2005.
But I still can't open the exe file, too.
Is it possible to create a exe file without install in Microsoft Visual Studio 2005?
Thx for ur reply.
Jane
|
|
|
|
|
minihotto wrote: But I want the exe file to be portable and without install.
Then don't use the .NET platform
minihotto wrote: Is it possible to create a exe file without install in Microsoft Visual Studio 2005?
Yes. The MSDN documentation has information detailing deployment issues of Visual Studio C++ projects, well any type of Visual Studio project actually.
|
|
|
|
|
A program written using /clr should run on any computer with .Net framework installed. Make sure that
1. The program in 100% .Net /clr then you can just install dotnetfx
2. Also check which version of .net are you targeting
3. If you are doing a mixed assembly, make sure you deploy appropriate CRT/OpenMP/ etc DLLs as well,
you can distribute using vcredist<arch>.exe or MSMs.
4. And finally, you need to distribute applications built in Release mode not Debug mode. Debug DLLs cannot be distributed.
|
|
|
|
|
How can I gain access to a file hosted on my server, and read from it?
Please help.
|
|
|
|
|
I'm beginner for graphical prog. in C++,
#include <graphics.h>
#include <stdlib.h>
#include <stdio.h>
#include <conio.h>
int main(void)
{
/* request auto detection */
int gdriver = DETECT, gmode, errorcode;
/* initialize graphics mode */
initgraph(&gdriver, &gmode, "");
/* read result of initialization */
errorcode = graphresult();
if (errorcode != grOk) /* an error occurred */
{
printf("Graphics error: %s\n", grapherrormsg(errorcode));
printf("Press any key to halt:");
getch();
exit(1); /* return with error code */
}
/* draw a line */
line(0, 0, getmaxx(), getmaxy());
/* clean up */
getch();
closegraph();
return 0;
}
But this programme show error while linking after compilation,
like, undefined symbol initgraph in module <prog. name.cpp="">
undefined symbol line in module <prog. name.cpp="">
undefined symbol graphresult in module <prog. name.cpp="">
Please someone help me in compiling and running it successfully.....Please
Thanks in Advance...
SAJAN A PILLAI
C#.NET Programmer
TELESOFT INDIA PVT LTD...
BANGALORE
"Winners don't do different things. They do things differently. ...
|
|
|
|
|
Wrong forum, you should ask similar questions to the MFC/C++ one.
Anyway, initgraph is a TurboC function, you have to use that compiler (if I remember well it's free at Borland website). Have a look at
http://electrosofts.com/cgraphics/index.html[^]
to know all requisites you need in order to link correctly.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
[my articles]
|
|
|
|
|
Hi, all:
I'm migrating code from VS2003 to VS2005, (using /clr without :oldsyntax) and have hit a strange problem. I have a control class with properties. They used to show up (VS2003) in the application using the control (in their own category) - but now nothing.
Here's a piece:
[Description("Total Number Of (Unsuccesful) Logon Attempts Before Failure"),Category("Logon_Dialog")]<br />
static property int LogonTries {<br />
public: int get() { return retries;}<br />
public: void set(int NumTries) { retries = NumTries; }<br />
}
Searching all about on MSDN, I finally came up with an example. Alas, it looks just like what I have! (Thanks, again, Microsoft)
How do I get a property to show up in the property list for the control?
Thanks,
Balboos
|
|
|
|
|
Hi
May be it it a very silly thing but I don't know to how to do it.
In my VC++ application where I have a form with some control on it. I want to copy this form with control and paste to a different project.
In solution explorer, I have a file form.h and form.cpp file and there is a .resx file which is under the form.h file. If I simply copy these three files to another project, I can not open it is designer view.
How can I copy this form with controls on it and add paste it to another project with its control and still able to open it in designer view.
Any link or avdise will be helpful.
Thank you.
|
|
|
|
|
You can actually copy any winform from one project to another no matter what the language is. All you have to do is open the form in the designer and hit ctrl+A to select all the controls, then hit ctrl+c to copy the controls and Ctrl+P to paste the controls in the other project.
Don't be overcome by evil, but overcome evil with good
|
|
|
|
|
Which kind of control can i use to realise the Windows Xp menu like what I see . when I click on my computer, one windows is opened, at his left there are menu, and the right side the details of each item when we click on it.
Is this a windows control or un OCX that I can use to do that ?
|
|
|
|
|
Hi All,
I have to handle text files of larger sizes ranges from 10GB and more which are exported from some application softwares. The text files contains the required information scattered throughout the file. I need to gather all those information in a particular format to do further analysis. Say for example, if the input file contains as following:
#10 // time stamp 10
0!
1(
1=
#15 // time stamp 15
1!
0:
I have to gather the information as,
! 10 0 15 1
( 10 1
= 10 1
: 10 0
So please suggest me how to store the above gathered information either as a vector, class arrays, or anything else like database e.t.c., The information surely occupies size larger than 10GB. And i have to access the gathered information for further progress.
With Regards,
Sangeetha.
|
|
|
|
|
I would not read the whole file into one data type. I would push it into an arraylist and pop it out after I saw the timestamp and write it to the new file.
Programmer
Glenn Earl Graham
Austin, TX
|
|
|
|
|
hi all, i have made winform application using vs 2005,when i call one form from another form then error is displayed that undeclared class member,
both classes have same namespace, i have compiled program with /clr option but still gives error when i declare the object of class.
Regards.
Tasleem Arif
|
|
|
|
|
Sounds to me like if you pasted your code, we'd be able to see your error and help you.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hey,
I'm trying to compile a project and I am getting the following errors:
<br />
#define BUFF 5000<br />
const SIZE_T m_cbStrBuffer = 5000;<br />
const WNDID_LIMIT = 1024;<br />
<br />
<...>"And so on"<br />
<br />
</...>
The compiler is complaining about both 'const' lines...
Anyone have any idea what I'm not doing right...?
let me know,
Cheers,
|
|
|
|
|
peepsicola wrote:
The compiler is complaining about both 'const' lines...
My psychic abilities are failing today....what are the error messages??????????
The second const line has no data type specified.
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
The actual error message is as follows:
error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
and yes, it is refering to the second 'const' line...
|
|
|
|
|
peepsicola wrote: const WNDID_LIMIT = 1024;
You're declaring a variable - the variable needs a type,
not just a name. For example, to make WNDID_LIMIT an int...
const int WNDID_LIMIT = 1024;
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
VC6 used to assume int. In fact, I had to work on some code that had methods which didn't specify a return type, it assumed int, code that called those methods assumed the int was an error code, and branched based on the result, but the actual code didn't return anything.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
|
I am using a C++ Dll in C# Window Application.For this I am trying to write a managed wrapper in C++/CLI so that it can consume the native C++ Dll and expose the methods to the C# application.While doing so I am facing a problem to marshal multidimensional character array.
I have an structure like
struct TouAnalysis
{
int x;
char TouName[500][5];
}
I am creating a corresponding structure in C#
[StructLayout(LayoutKind.Sequential,CharSet=CharSet.Ansi,Pack=8)]
public struct TouAnalysis
{
[MarshalAs(UnmanagedType.I4)] public int x;
}
The problem is How do I define the data type for the character array char TouName[500][5] in C# structure.
I would be a great help if anybody can help on this or can tell any alternate way of using native C++ structures in Managed code
Kamal
|
|
|
|
|
Maybe something like
[MarshalAs(UnmanagedType.LPArray, SizeConst=2500)] public byte[] TouName;
I'm no C# programmer, but I'm guessing you'll need/want to marshal those chars
as Strings unless they are really just signed bytes.
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
How to marshal them as String??
|
|
|
|
|
Hi,
I have a cli::array that I need to convert to a Byte[] (unsigned char[]).
I have code as follows:
Byte ImageBytes []= Convert::FromBase64String(structParam->m_sValue);
m_sValue is a String ^.
However, this gives me the following error:
error C2440: 'initializing' : cannot convert from 'cli::array<type,dimension> ^' to 'unsigned char []'
I have looked everywhere, but have not found a way to do this. I am sure I missed it somewhere.
How would this be done?
Thanks!
----------------------
William Dicks
|
|
|
|
|
WilliamD wrote: Byte ImageBytes []= Convert::FromBase64String(structParam->m_sValue);
should be:
array<Byte>^ ImageBytes = Convert::FromBase64String(structParam->m_sValue);
"We make a living by what we get, we make a life by what we give." --Winston Churchill
|
|
|
|