|
Hi all ,
I want to do without change quality when I was zooming to graphic like as in autocad..
I have to this in C#. Is it hard? or can you give me some hint and links?
thanks
|
|
|
|
|
You can only do that if you're dealing with a vector image. Bitmap images will degrade in quality the more you zoom into them.
|
|
|
|
|
Hello,
I'd like to know if a user scrolls my ListView, since .NET (weird?) doesn't support this. Now I've found several articles (on Google) which tell me I need to create a Virtual ListView and override WndProc. I've done this but: 1) The control is terribly slow, and I can't just drag it on the form, meaning I need to create it in code. Is there any easy way to check if a NORMAL ListView gets scrolled? I also need to know the difference between Scrolling Up, and Scrolling Down.
Please help me out,
Zaegra
Motivation is the key to software development.
|
|
|
|
|
Talking about WPF or WinForms?
For WPF, I think you can just hook the ScrollViewer.ScrollChanged event, and you're golden...
As for WinForms... Never noticed they didn't have an event for that... Well, you could catch the various mouse events, and look for changes in the TopItem property... Bit easier than hooking WndProc, but not as direct.
|
|
|
|
|
Using WinForms But I don't care about the internal layout of the Listview, I only need to know if a listview has focus, if the scrollwheel is scrolled. And if so, if it was scrolled up or down.. Can't seem to find anything fitting this purpose. Any ideas on this?
Motivation is the key to software development.
modified on Tuesday, October 13, 2009 2:24 PM
|
|
|
|
|
Well, if TopItem changes, it means it was scrolled... TopItem is the first item visible... Figuring out the direction would require knowing the content, though.
On the other hand, if you're specifically looking for the mousewheel... There IS a MouseWheel event
|
|
|
|
|
Hi,
For mousewheel actions, there is a MouseWheel event.
However there probably are other ways to cause a scroll which you also would like to get (for consistency if nothing else), such as clicking in the scroll bar parts, using the arrow keys, maybe performing a find on the content, etc.
Therefore I would be inclined to use the Paint event: just add a handler to Paint, and compare TopIndex to its previous value. You will get some redundant events (e.g. when uncovering part of the Form), but that would be OK I guess.
BTW: I said "add a handler", not "override OnPaint", as you still want the original painting to occur.
Luc Pattyn
I only read code that is properly indented, and rendered in a non-proportional font; hint: use PRE tags in forum messages
Local announcement (Antwerp region): Lange Wapper? Neen!
|
|
|
|
|
I have to do SerialPort communication that constantly needs to read data from a serial interface (for example COM1). and also identify the strating of first message and ending of that message and also starting of second message. please give me reply ASAP becuase I really stuck in that.
|
|
|
|
|
You had similar questions 3 months ago!?
now start by telling more:
1. is it text or binary data?
2. is it message oriented? what is the minimum and maximum message length?
3. is there a unique byte that indicates end-of-message and is guaranteed not to appear inside a message?
4. is it going to fill the bandwidth, or just a few messages a second?
5. what kind of data is it? is it real-time? can you afford to loose some (as in audio/video streaming)?
6. what is more important: latency (reaction to first data) or bandwidth (kilobytes per second)?
7. what is the other device? did you design it? can it be modified if need be?
etc
Luc Pattyn
I only read code that is properly indented, and rendered in a non-proportional font; hint: use PRE tags in forum messages
Local announcement (Antwerp region): Lange Wapper? Neen!
|
|
|
|
|
This is nice I agreed.
Thanks
Md. Marufuzzaman
Don't forget to click [Vote] / [Good Answer] on the post(s) that helped you.
I will not say I have failed 1000 times; I will say that I have discovered 1000 ways that can cause failure – Thomas Edison.
|
|
|
|
|
I know that I asked same question that before 3 months ago but I tried to implement for it but still facing problem and dont know the solution. let me explain from scratch so you will have some idea about it.
1) My allication has to intract with another device and this device cannot be modified. Its kind of embedded tech. means whaterver signal the device can send that computer has to recieve it and in some cases computer has to send some instruction to control the device.(in the case when the device generates signals and if it goes beyong some set points then computer has to control it. its kind of two way communication).
2) its in format of binary of ascii value.
3) there is no minimum or maximum length. its continous
4)probably its real-time.
I dont have enough background info about this and I am only in this project so cant get help from other and never work any this kind of project in past.so please give me a proper guidence for it.
thank you so much for intrest in this topic.
thanks.
|
|
|
|
|
that still is extremely vague.
what is the peripheral's function?
is the peripheral a commercial one, has it on-line documentation I could look at?
can you show say 100 bytes of the data, preferably in hex?
both continuous and real-time is something Windows cannot handle; maybe you're exagerating?
Luc Pattyn
I only read code that is properly indented, and rendered in a non-proportional font; hint: use PRE tags in forum messages
Local announcement (Antwerp region): Lange Wapper? Neen!
|
|
|
|
|
means? I didnt understand what kind of details you want?
Actually I am going to use this programming for commericial use. In my project there is a need to develope this. the requirment is computer has to recieve signals from another device which is not computer but its a kind of detector. and whatever signals it sends computer has to recieve it.
still if you have confusion then let me know I'll explain you. If you are availabe for chat then we discuss about it more clearly.
but thanks a lot for help.
|
|
|
|
|
I don't chat.
I have read your several messages and still have no clue about your app, your amount of data, its timing, etc.
You'll be on your own.
Luc Pattyn
I only read code that is properly indented, and rendered in a non-proportional font; hint: use PRE tags in forum messages
Local announcement (Antwerp region): Lange Wapper? Neen!
|
|
|
|
|
Hi All!
I have a problem that I can't find the solution of:
In an application I'm using MaskedTextBox controls for dates (displaying current value and letting user change value). Default language for application is Swedish and mask is 0000-00-00 (for yyyy-MM-dd). This works fine.
The application is also to be run in Finnish and then I set the mask to 00.00.0000 (for dd.MM.yyyy), this does not work at all! The mask is correct but for a reason beyond my comprehension in the text-property of the control the "." (dot) is replaced with "," (comma). I have tried to replace the comma, to overwrite the text property and a number of other things but without success.
Is the problem that the control interpretes the date as a number and replaces the dot with the NumberGroupSeparator and NumberDecimalSeparator of the MaskedTextBox.Culture? If so how do I get the control so interprete the date as a date?
What can I do to make the MaskedTextBox to work with my Finnish dates???
Thanks!
Chris
|
|
|
|
|
I guess yes. It is picking things up from the current culture. I think you will need to override that through FormatProvider.
It's not necessary to be so stupid, either, but people manage it. - Christian Graus, 2009 AD
|
|
|
|
|
Hi,
Have you read the MSDN notes for the Mask property? To me they suggest that the date separator / will be interpreted according FormatProvider.
Alan.
|
|
|
|
|
Thank you Alan!
You've made the day for our whole project team!
/Chris
|
|
|
|
|
You have seen the user comments part of the forum of the codeproject site. It is like a treeview control.
I have managed to make something similar to it. As you see in the forum a line is put after a message and all its answers. Can anyone give me details of how it is done ? What are the algorithm ,the database structure and details ?
|
|
|
|
|
Well... This is Gr8. I think you can write an article and post it at codeproject.com on what you did.. so we can also get some idea on it..
Thanks
Md. Marufuzzaman
Don't forget to click [Vote] / [Good Answer] on the post(s) that helped you.
I will not say I have failed 1000 times; I will say that I have discovered 1000 ways that can cause failure – Thomas Edison.
|
|
|
|
|
Huh??
Everything makes sense in someone's mind
|
|
|
|
|
|
I m using crystal report with data base mysql.
i m genrating report dynamic.
as we select column from check box report will be genrate.
all thing is done well but genrated data is not display in report.
my problem is i result is not display in report.
|
|
|
|
|
Why do people make posts like this with no code attached? Does Miss Cleo now frequent the CodeProject message boards?
|
|
|
|
|
I think you should post in detail.. your code snippets.. error you are facing ..etc so that everyone can get the actual scenario.
Thanks
Md. Marufuzzaman
Don't forget to click [Vote] / [Good Answer] on the post(s) that helped you.
I will not say I have failed 1000 times; I will say that I have discovered 1000 ways that can cause failure – Thomas Edison.
|
|
|
|