|
From the error message, you are using C++/CLI, so what you want is:
array<system::drawing::color> ^Color1 = {Color::Black, Color::Brown, Color::Red};
(edited Feb 19 to ignore html tags)
David Anton
http://www.tangiblesoftwaresolutions.com
C++ to C# Converter
C++ to VB Converter
C++ to Java Converter
Instant C#: VB to C# converter
Instant VB: C# to VB converter
Instant C++: convert VB or C# to C++/CLI
Java to VB & C# Converter: convert Java to VB or C#
modified on Tuesday, February 19, 2008 10:31 AM
|
|
|
|
|
Ack! Good eye - I don't know how many times I read it and missed the "^" LOL
Cheers,
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Thanks but it doesn't work.
|
|
|
|
|
The code was mangled when posting (forgot to check "ignore html tags..").
It should be:
array<System::Drawing::Color> ^Color1 = {Color::Black, Color::Brown, Color::Red};
David Anton
http://www.tangiblesoftwaresolutions.com
C++ to C# Converter
C++ to VB Converter
C++ to Java Converter
Instant C#: VB to C# converter
Instant VB: C# to VB converter
Instant C++: convert VB or C# to C++/CLI
Java to VB & C# Converter: convert Java to VB or C#
|
|
|
|
|
I load a report from my Visual c++ NEt program.
I have a error message : invalid report file path,evenif the report is in this directory
my code is bellow.
What can be the problem ?
SqlConnection^ cprl = gcnew SqlConnection();
cprl->ConnectionString = "Persist Security Info=False;Integrated Security=SSPI;database=payroll08;server=sem;Trusted_Connection=Yes;" ;
cprl->Open();
// Ds_report^ data = gcnew Ds_report();
DSENFANTS^ data = gcnew DSENFANTS();
SqlDataAdapter^ adapt = gcnew SqlDataAdapter();
SqlCommand^ Cmd = gcnew SqlCommand();
Cmd->CommandText = "select* from ficenf";
Cmd->CommandType = CommandType::Text;
Cmd->Connection = cprl;
adapt->SelectCommand::set(Cmd) ;
adapt->Fill(data,"enfants");
RDEnfants->SetDataSource(data);
RDEnfants->Load(L"c:\\GESTION\\payrollv2\\payrollv2\REPENFANTS.rpt");
//rptsearchsig->PrintToPrinter(1,true,0,65500);
RVENFANTS->ReportSource = RDEnfants;
//crystalReportViewer1->ReportSource = rptsearchsig;
modified on Monday, February 18, 2008 10:54 AM
|
|
|
|
|
Dear Sir,
I use Visual c++ Net 2005.
I need to know how we do the non document printing in Visual c++ NEt 2005.
Can you show me articles that talk about it ?
It's not Urgent but I need your Help
I learn my self
|
|
|
|
|
mikobi wrote: I learn my self
When? We are still waiting.
On the CodeProject menu under "Chapters" click "Desktop Development" then click "Printing"
led mike
|
|
|
|
|
I did not yet see article that shows me how to print in Visual c++ 2005 NET.
I am blocked by this, I can't go far if I cannot print.
Who can Help me.
|
|
|
|
|
On my form I have one combobox that I need to fill data from my database.
I am using Visual c++ Net 2005
How can I make declaration and add items ?
Urgent
|
|
|
|
|
mikobi wrote: Urgent
The only thing that's urgent is you urgently need to stop trying to learn how to do EVERYTHING through internet forums. Most software developers go to university and read books to learn fundamentals of software development. If you refuse to learn fundamentals there is no hope you will ever be a capable developer.
led mike
|
|
|
|
|
Please Sir, I have not this opportunity to access that university, but I want to know. I learn my self Visual c++ 6.0 and I have made 4 programs .
As there are a new version I need to improve my programs.
|
|
|
|
|
mikobi wrote: I have not this opportunity to access that university
Then obtain some books or even find online courses or tutorials that target beginner programming.
led mike
|
|
|
|
|
I try to do that :
this->nationalite->AddItemsCore("Congo");
I have a message candidate function not accessible.
Remarque: This combobox(nationalite) I need to fill is in a user form.
I do know if this message is related to the kind of form.
|
|
|
|
|
I find solution.
I DO THIS->NATIONALITE->ITEM-ADD
It works.
You must encourage me Dear Sirs.
Thanks, I go ahead
|
|
|
|
|
Dear Sir,
I use Visual c++ Net with Sql server 2000.
I need to make a connection string so that i can use it every where I need to open database.
how can I at the starting of my program to initialise a String variable and to use it every where ; at any forms?
|
|
|
|
|
Dear Sir,
I use Visual c++ Net with Sql server 2000.
I need to make a connection string so that i can use it every where I need to open database.
how can I at the starting of my program to initialise a String variable and to use it every where ; at any forms?
|
|
|
|
|
Store connection string in config file and read it in a string when your program starts
|
|
|
|
|
This connection string is in a text file, I read it when I need to connect to a data base.
Now I ask if it is not a means to read one time at the starting programme and use it every where without read many times. Another precision I need, the starting of program is in what file and what procedure or part.
I learn my self
|
|
|
|
|
Hey all...
I'm trying to call an exe i.e (PING) with argument ("www.yahoo.com")
and want output in my textBox instead of console...
I manage to redirect output to my textBox and also manage to hide the console window but in synchronous way... i.e the output comes after ping get fully executed... I need the output in asynchronous way..The way it shows in console window(Line by Line)..
I know i've to use BeginOutputreadLine() but couldn't manage to write exact code..Can anyone help mr out..
Following is my code ..
Process^ a = gcnew Process;
ProcessStartInfo^ b = gcnew ProcessStartInfo;
b->FileName = "ping.exe";
b->Arguments = "www.yahoo.com";
b->UseShellExecute = false;
b->RedirectStandardOutput = true;
b->CreateNoWindow = true;
a->StartInfo = myProcessStartInfo;
a->Start();
StreamReader^ myStreamReader = a->StandardOutput;
textBox1->Text = myStreamReader->ReadToEnd();
a->Close();
Ash..
|
|
|
|
|
Ashish Chauhan wrote: I know i've to use BeginOutputreadLine() but couldn't manage to write exact code..Can anyone help mr out..
The documentation for BeginOutputReadLine() contains example code. Perhaps you could explain specifically what you are having a problem with?
led mike
|
|
|
|
|
Thnks for ur reply...
But i believe i need to add event handler for tht..I mean for BeginOutputReadLine()... but whenever i try to write code for DataRecievedHandler i.e whenever i try to define object of DataRecievedHandler it denies it..It doesn't recognize as any of predefined
thing..
Am i forgetting to include any of files???
Ash..
|
|
|
|
|
Ashish Chauhan wrote: whenever i try to define object of DataRecievedHandler it denies it..It doesn't recognize as any of predefined
thing..
If you are receiving error messages you should probably post them. Many times the contents of error messages can be meaningful.
led mike
|
|
|
|
|
|
Member 4542272 wrote: i am confusing until cant move a single step.
There is an excellent set of C++/CLI Beginner Articles here on CodeProject. Stop typing code and READ the articles.
led mike
|
|
|
|
|
I am trying to open an .lib file using the ildasm from visual studio tool menu.
When I open the gui for ildasm, there is no option for .lib file. The type of files it can open is
(*.exe, *.dll, *.mod, *.dll), there is no .lib files in the list. when I select all file types, it shows the .lib file but can not open it.
Is there any body know more about it.
I made a library file using Pure clr option. The files in that project all are native c/c++;
There is no error when I build the file but it give me linking error when I tried to use this library in another project it gives me some unresolve token.
Any help will be highly appreciated.
Thank you.
|
|
|
|