|
how convert some algorithm to c#..
please give me some relevant links.some direction to achieve this goal.
|
|
|
|
|
Algorithms are just general guides,or set of steps for solving a particular problem.It is difficult to convert in code by software.
If any software convert algo to code then it requires some own syntax to define algorith then it will converts intio code.
|
|
|
|
|
You will have to re-write the code in C#. Please ask a specific question if you get stuck on a particular line of code.
There are only 10 types of people in the world, those who understand binary and those who don't.
|
|
|
|
|
can any one provide me code for videos slide show
|
|
|
|
|
This is not a clear question so please search for 3rd party tools or if you are using ASP.Net search for jQuery tools.
There are only 10 types of people in the world, those who understand binary and those who don't.
|
|
|
|
|
I have some charts taking a long time to load (up to 15 seconds). I would like to calculate the time to load if possible.
I already have a feedback to the user using javascript and ajax extensions, but I cannot find any kind of "feedback" from the chart control so that I can display a "6 seconds to finish".
Is there any way to calculate/estimate this?
|
|
|
|
|
Well the chart control just makes a JPG or PNG image, that you reference in HTML in which your server sends back to the users web browser for display.
A well written chart program can generate an image in like 1/10th of a second. So your slow times must be from not closing a Paint handle, SQL handle or something like that, and your waiting for something to timeout. Or you forgot to destroy an object somewhere.
The chart control is just a wrapper to the paint or GDI classes in asp.net, I'm not aware of any feedback handle in the chart control.
Step through your program using debug, and set some breakpoints.
|
|
|
|
|
I'll check it out, thanks!
|
|
|
|
|
I've just tested, and when populating a small amount of data it runs fast, however when populating more data the process slows down. The SQL query runs fine, my x/y plotting runs fine. But after my methods are finished it slows down. It must be something with generating the picture....
FYI: I'm generating a chart based on a timeline with appr. 10000 rows with the X/Y values in two separate columns on each row.
Any suggestions?
|
|
|
|
|
Kaare Tragethon wrote: But after my methods are finished
Could you elaborate on that, Which methods,
the gathering and packaging of data,
or plotting of chart values?
or the final write to create the image file to the disk drive
Did you make a thousand variables, that the garbage collector has to clean-up at the end of your function? garbage collection takes lots of time to complete. Since your writing in an high level language wrapper, you don't see the extra tasks and time needed to cleanup memory at the end.
How big is the final image file size?, over 5 megs?
Are you writing a huge PNG at 24 or 32 bits, instead of a compressed JPG?
A nice chart is something that is 640 x 480, easy to read, no scrolling.
Or you can change the program to create each record 1 by 1, and loop it to create 10K charts, just kidding, but serious about breaking it down into smaller pieces.
You might of run out of memory RAM and threads, and the computer is doing a huge disk swap to complete the job. You may need to do some serious optimization on your code there.
|
|
|
|
|
I mean that it doesn't take long to do the following:
command.CommandText = "SELECT TimeStamp, " + siloNo + " FROM SilosGraphHistory";
UxChartSiloHistory.DataSource = command.ExecuteReader();
UxChartSiloHistory.Series["UxChartSeriesSilo"].XValueMember = "TimeStamp";
UxChartSiloHistory.Series["UxChartSeriesSilo"].YValueMembers = siloNo;
UxChartSiloHistory.DataBind();
It exits my method (that fetches data from the SQL server and binds them to the chart) in milliseconds. Then, after that, I'm unable to find out why it takes so long... Do you have any tricks to detect where the time goes??
The final size when saving it to my desktop is just 30kb.
I am indeed a beginner in ASP.NET and C# so please have that in mind, and thank you very much for taking the time to answer my questions....
|
|
|
|
|
I didn't know you were binding, that's different. I thought you were using pure code to build your chart. I'm not sure if you have downloaded the sample project that shows how to make various charts. In the sample project, they are combinations of code behind and <asp::chart> objects, and use small xml files for data to feed the points, so that's why they run so fast. The sample projects are a good way to learn how to build a faster chart object.
I haven't used a bound object in over 7 years, so I'm not qualified for assisting you. There good for small websites, but not practical for hi volume use because of the amount of resources needed, and speed. There's nothing you can do about the speed right now, until you expand you skill set to write part of it in code.
You should try here and ask for help, the chart control is a beast, and took me a couple of weeks to understand how to write one in pure code.
Objects like the Chart and Gridview can actually be their own forum, because the skys the limit on those topics. But go ahead and ask the same question again, and see what the bound chart object guru's say about it.
Good Luck with that!
http://social.msdn.microsoft.com/Forums/en-US/MSWinWebChart/[^]
|
|
|
|
|
jkirkerx wrote: I didn't know you were binding, that's different.
Sorry for that, I should have provided more info in my initial post.
Thanks for the excellent link, I'll sure read about it and may ask some questions here....
Thanks again for helping me out 
|
|
|
|
|
Found the "problem":
I was using the Spline chart which takes a long time to calculate. Changed it to Fastline with the following results:
10000 points (10000 X-values and 10000 Y-values)
Spline took appr. 27 seconds
Fastline took appr. 0.5 seconds
Thanks for the feedback, it helped me on the way...
|
|
|
|
|
Hi guys
Hope someone can help with a question, Im not an asp.net developer so please bare with me.
I created a very simple Singleton class, that is, its not thread safe. Now I would have though that the singleton class instance would only exist for a single page request.
What I am finding is that my test singleton instance persists over several http requests.
I wanted to develop a very small cms with a single db instance that exists only for each page request. So really my question is how does IIS keep the singleton instance alive for several page requests.

|
|
|
|
|
You may want to remove the form tags from you page, to indicate that the page is a 1 way trip, with no postback capabilties.
|
|
|
|
|
Can anybody help for a window service that start synchronization from ftp to local machine in C# asp.net. It's very urgent for me.
|
|
|
|
|
i also want solution for same thing.
please help me also its urgent.
|
|
|
|
|
aju184 wrote: its urgent
Urgent enough to try this[^]?
Unrequited desire is character building. OriginalGriff
I'm sitting here giving you a standing ovation - Len Goodman
|
|
|
|
|
See here[^].
Unrequited desire is character building. OriginalGriff
I'm sitting here giving you a standing ovation - Len Goodman
|
|
|
|
|
i want to insert mathematical and chemical formula in SQL server database 2005 using xls file and want to retrive it on webpage using asp.netwith c#.iam able to insert other data into database but in place of chemical and mathematical formula its showing null and i am unable to retrive it also so please help me how to short out this problem
|
|
|
|
|
pankaj3086 wrote: its showing null and i am unable to retrive it
What is showing null, what can you not retrieve? You need to explain exactly what information you are storing, what format it is in, and how you are trying to retrieve it.
Unrequited desire is character building. OriginalGriff
I'm sitting here giving you a standing ovation - Len Goodman
|
|
|
|
|
uncheck the allow nulls field in ur database table..
|
|
|
|
|
Can any body help me for web based Chat Room With Private Message in asp.net C# application.
Abhishek
|
|
|
|
|
Try Google, this is one of the most common application questions around.
Unrequited desire is character building. OriginalGriff
I'm sitting here giving you a standing ovation - Len Goodman
|
|
|
|