|
Of course, but they are generally exposed only by a read-only property. It's rare and generally not recommended to have a property with a setter or to expose the field directly in a struct.
|
|
|
|
|
I have my vs2008 c# project compiled,
when i install on win Vista, it runs fine
but does not run on win XP SP2.
please can some help me out.
thanks alot.
|
|
|
|
|
Is installed on your Windows XP system the version of the .NET Framework that your application is expecting?
|
|
|
|
|
I used VS2008 and .net 3.5 for the building of the app
on Win Server 2003 Enterprise Edition.
The .net 3.5 will not install on Win XP sp2, so i rebuild with .net 2.0
and i have installed .net 2.0 on the system
|
|
|
|
|
If you had a .NET version problem, I'd expect an error 0135.
Error 0x7b may mean: The filename, directory name, or volume label syntax is incorrect.
Could be many things, e.g. you're trying to access one of the special folders (such as Users or "Documents and Settings") without going through the proper channels (Environment.SpecialFolder). Proper try-catch and Exception reporting would take care of the details.
|
|
|
|
|
But the same project when installed on Win Vista does not generate any errors.
thanks.
|
|
|
|
|
I have found Solution to it,
I formatted my Win XP sys and reinstall the OS.
everything is working fine now.
Thanks to Everyone.
|
|
|
|
|
It's a so drastic as good solution
|
|
|
|
|
Hi,
I have to validate the control in server side and have to find which value is wrong. Ex im passing user name and password. if password is wrong it should find only the password is wrong not the user name.. Please help me..
|
|
|
|
|
Are you in correct forum?
Go here[^]
rahul
|
|
|
|
|
Hello everybody,
I am doing a application which needs to communicates with a DCOM server. I created a .NET wrapper using tlbimp.exe and referenced it in my C# program.
I then create an Object from my remote server using Activator.CreateInstance("Objectdd.obj","ServerNAME"); and cast the returned object to the correct type in the .NET wrapper class.
Until here everything is working fine, I can call method on my object from C# and the call is correctly executed on the remote machine.
The problem is, as soon as I try to connect to an event from C#, I got a System.UnauthorizedAccesException. This is strange because I can call every others method with no problems. I also tried my C# software on the server, using "localhost" as server address and I could connect to the event correctly.
Any ideas what's wrong ? Any security problems I am missing ?
Thank you,
|
|
|
|
|
|
usually when we open a cs file(by Double Click)it open in the vs2005 IDE, if no IDE is opened it will open one and show the file , but if an IDE exist then the file will be opened in the existing IDE.
But i want to open the .CS file through my application and always in a new IDE instance in a new process, because i want to keep tracking the process.
but when call the
process.start("devenv","filename"); it opens in an existing IDE if one exist.
what i want is to always open a separate IDE for my app.
any idea how to do this.
thanx in advance.
|
|
|
|
|
prasadbuddhika wrote: usually when we open a cs file(by Double Click)it open in the vs2005 IDE, if no IDE is opened it will open one and show the file , but if an IDE exist then the file will be opened in the existing IDE.
Yes, that's common behavior, because you are trying to open a file and not the application. you just double click on the visual studio icon, and it will open new IDE all the time, because there you are trying to open an application. now use the same code and don't pass the file name, I think it will open new IDE all the time.
Also, by reading your few previous posts. As suggested to you previously, just develop Visual Studio Add-in / Extension. and you will have access to everything you want in IDE. otherwise keep in mind that you cannot control some external process, that is already running, from another process. they are running in separate domain. unless the process supports RMI kind of functionality. Which Visual Studio IDE is not supporting. so instead of spending time on doing everything remotely. try to create in-process pug-ins and you will have full control.
|
|
|
|
|
You've been told not to do this. Now please stop. Replies to the threads should be done on the original thread.
|
|
|
|
|
Hi all,
Is there any way to hide the Y axis scale points on my Barchart? I wouldn't want to show datapoints for the Y axis.As i dont want to be seen by users.
Chart1.ChartAreas("ChartArea1").AxisY ??????
Is there any Property which ci could use to hide this scale points on Y axis?
Thanks for your time.
-- Modified Wednesday, October 6, 2010 11:05 AM
|
|
|
|
|
As you already know, Bar Chart is 2 Axis chart, so you cannot hide any of the axis, otherwise it will not plot the chart.
but you can make the Color of the Y Axis same as Background color of the Chart Area. So that It's there but not visible (kind of).
Chart1.ChartAreas["ChartArea1"].AxisY.LabelStyle.ForeColor = "Your background color";
Chart1.ChartAreas["ChartArea1"].AxisY.LineColor = "Your background color";
Chart1.ChartAreas["ChartArea1"].AxisY.TitleForeColor = "Your background color";
Hopefully this should work...
If you have gradient background, this is not going to work.
Please Let us know, if you find out any other way to hide the Y-Axis
|
|
|
|
|
Thanks for your email.Its much appreciated.That is great point,what i wouldnt want to show is the scale points as they are Revenue points which users are not allowed to see.
The backcolor is white at the moment setting the forcolor to white wont show scale y axis.
Chart1.ChartAreas["ChartArea1"].AxisY.LabelStyle.ForeColor="#FFFFFF"
Did i get it right?
|
|
|
|
|
kibromg wrote: Chart1.ChartAreas["ChartArea1"].AxisY.LabelStyle.ForeColor="#FFFFFF"
It should be
Chart1.ChartAreas["ChartArea1"].AxisY.LabelStyle.ForeColor = System.Drawing.Color.White;
|
|
|
|
|
Thanks so much.
Sorry if you dont mind , I have another query.On my X axis for each scale points i have two bar graph.
One is the target for the day and the other one is a progreess bar which indicates as we approach to that target.
Lets say (x axis is Hours of the day)
for instance at 8:00am i have a target of $1000 and this is shown with one Bargraph. and i have another one which is an online realtime data that counts as persentage to this value.So at exactly 8:00am it will be zero percent and after few minutes it will climb up this point until the hour finishes. and at 9:00 there will be another datapoints on x axis may be £2000 and another progreess bar that shows the progress etcc..
$1000 is 100% target for 8:00am and another bargraph toshow what is achieved say $500 so it will be at 50%
£2000 is 100% target for 9:00am and another bargraph to toshow what is achieved say $4000 so it will be at 200%
How can i represent one bargraph $1000 and another one saying 50% for one datapoint in X axis?
Is it clear?
-- Modified Wednesday, October 6, 2010 12:37 PM
|
|
|
|
|
Yes, You can do that,
You will need to add one more series in your chart. so that there are total 2 series, one for target and another for progress.
i.e.
Chart1.Series.Add("Target");
Chart1.Series[0].ChartType = System.Web.UI.DataVisualization.Charting.SeriesChartType.Bar;
Chart1.Series[0].IsValueShownAsLabel = true;
Chart1.Series[0].LabelFormat = "#"; -- here you want just target money right ?
Chart1.Series.Add("Progress");
Chart1.Series[1].ChartType = System.Web.UI.DataVisualization.Charting.SeriesChartType.Bar;
Chart1.Series[1].IsValueShownAsLabel = true;
Chart1.Series[1].LabelFormat = "#%"; -- this will show % progress
now get the data set with all the 3 values as columns, time,target,progress. one column for x axes and 2 columns for y axes, and then
Chart1.Series["Target"].Points.DataBindXY(ds["time"],ds["target"]);
Chart1.Series["Progress"].Points.DataBindXY(ds["time"],ds["progress"]);
now the ds["time"] will group the bars to gather if they have same time. and one will show value and another will show percentage. also the ds["percentage"] should have values without x 100, i.e. 0.40 for 40% and not 40...
Also, I would suggest you, that you download[^] the mschart control samples. you will have sample for almost every single scenario.
|
|
|
|
|
Thanks so much its much appreciated.That is really great.
I have a few questions if you dont mind.Lets say for 8:00am target is $1000 and achieved is $500 which is (50%)
and 9:00am target is %2000 and Achieved is $4000 which is 200%
On the first one the progress barchart whould be half target barchart.
on the second one the progrees barchart should exceed the length of the target barchart twice.
But this is not the case as the value 0.5 (50%) is to small in values on the scale points on Y axis though it means £500 which is half the value of the target.
If i choose percentage it is a bit tricky to represnt them on graph? Where i am getting it wrong?
Can you also please let me know how could i choose the backcolor of my barchart?
Many thanks.Your help is great and much appreciated.
|
|
|
|
|
OK, This is because the Axes Y, should bind same kind of values, due to same scale type. so those 0.5,0.1.. will be too small compared to 1000 (which is $ value). so you need to change few things...
i.e.
Chart1.Series.Add("Target");
Chart1.Series[0].ChartType = System.Web.UI.DataVisualization.Charting.SeriesChartType.Bar;
Chart1.Series[0].IsValueShownAsLabel = true;
Chart1.Series[0].LabelFormat = "#";
Chart1.Series.Add("Progress");
Chart1.Series[1].ChartType = System.Web.UI.DataVisualization.Charting.SeriesChartType.Bar;
Chart1.Series[1].IsValueShownAsLabel = false;
Chart1.Series[1].LabelFormat = "#";
now in ds you will need 4 columns, or change the 3rd column from percentage to value. or just 4 columns
1.time
2.target
3.progress
4.percentage
now you need to manually add the points, instead of binding it.
so,
Chart1.Series[0].Points.Clear();
Chart1.Series[1].Points.Clear();
foreach (DataRow dr in ds.Tables[0].Rows)
{
Chart1.Series[0].Points.AddXY(dr["time"],dr["target"])
Chart1.Series[1].Points.AddXY(dr["time"],dr["progress"])
Chart1.Series[1].Points[Chart1.Series[1].Points.Count - 1].Label = dr["percentage"].ToString() + "%"
}
and to change the background color
Chart1.ChartAreas[0].BackColor = System.Drawing.Color.Silver;
And for my next answer, I need MONEY...
Just go through the sample code, I mentioned in the previous post. it has all the code. first you just run the sample project and browse the app, and if you find something interesting, look for the code.
again you can download it here[^]
|
|
|
|
|
Thanks a million you are my hero Dave.Anything will be given for you man. Thanks.
One last question : dr["time"] is coming as Y axis and the others like dr["progress"] are on X axis. How do i reverse it ?so the Dr{time} is X axis.
Here is the Code:--
Dim dt As New DataTable
With dt
.Columns.Add(New DataColumn("Hour", System.Type.GetType("System.String")))
.Columns.Add(New DataColumn("Acheived", System.Type.GetType("System.String")))
.Columns.Add(New DataColumn("Hourly_target", System.Type.GetType("System.String")))
.Columns.Add(New DataColumn("Hourly_targetPer", System.Type.GetType("System.String")))
.PrimaryKey = New DataColumn() {dt.Columns("Hour")}
End With
Chart1.Series.Add("Hourly_target")
Chart1.Series(0).ChartType = System.Web.UI.DataVisualization.Charting.SeriesChartType.Bar
Chart1.Series(0).IsValueShownAsLabel = True
Chart1.Series(0).LabelFormat = "#"
' here you want just target money right ?
Chart1.Series.Add("Acheived")
Chart1.Series(1).ChartType = System.Web.UI.DataVisualization.Charting.SeriesChartType.Bar
Chart1.Series(1).IsValueShownAsLabel = False
' i have changed this
Chart1.Series(0).LabelFormat = "#"
Chart1.Series(0).XValueMember = "Hour"
Chart1.Series(1).YValueMembers = "Hourly_target"
Chart1.Series(0).Points.Clear()
Chart1.Series(1).Points.Clear()
For Each myDataRow As DataRow In dt.Rows
Chart1.Series(0).Points.AddXY(myDataRow("Hour"), myDataRow("Hourly_target"))
Chart1.Series(1).Points.AddXY(myDataRow("Hour"), myDataRow("Acheived"))
Chart1.Series(1).Points(Chart1.Series(1).Points.Count - 1).Label = myDataRow("hourly_targetPer").ToString + "%"
Next
However i get x axis -- Hourly_target and Y axis is Hour. Is there anything i am missing ,It should be the reverse .
sorry i meant to ask changing the color of the barchart not the backcolor.
Thanks Dave
-- Modified Thursday, October 7, 2010 1:36 PM
|
|
|
|
|
It is correct if you select Bar Chart, I think, you want Column Chart.
Change
ChartType = System.Web.UI.DataVisualization.Charting.SeriesChartType.Bar
ChartType = System.Web.UI.DataVisualization.Charting.SeriesChartType.Column
kibromg wrote: sorry i meant to ask changing the color of the barchart not the backcolor.
I though that,
<blockquote class="FQ"><div class="FQA">kibromg wrote:</div> Chart1.Series(0).Points.AddXY(myDataRow("Hour"), myDataRow("Hourly_target"))
Chart1.Series(1).Points.AddXY(myDataRow("Hour"), myDataRow("Acheived"))
Chart1.Series(1).Points(Chart1.Series(1).Points.Count - 1).Label = myDataRow("hourly_targetPer").ToString + "%"</blockquote>
here
add
Chart1.Series(1).Points(Chart1.Series(1).Points.Count - 1).Color = System.Drawing.Color.Red
I think, you want to change the color based on progress, yeah you can do that...just add some IFs...
|
|
|
|