|
Thanks... it works!
QzRz
|
|
|
|
|
Hi,
Please consider that there are many
users that have graphical tablets/pen
as pointing devices instead of/in parallel with
a mouse. (i have a Genius tablet)
Your method is in that case instantly overriden by the
next pen position event (which occur at a rate
of > 100-1000 times/sec), therefore:
For these devices it is always the absolute position
of the pen where the cursor will be, no matter where
your program puts it.
This also is the case of course for Tablet- and Pocket PC's
IMHO, moving the cursor programatically is not very user
friendly, because if you move it out of the area where the
attention is, the user then has to look where it is.
It's like taking control away from the user
Mouse drives often have a feature to move the cursor
to the default dialog button. I always disable this.
Regards
Ted
|
|
|
|
|
How to measure sound level on sound card input in decibel? I need to write a program in C#, which alert when the sound level is less the threshold (n db).
|
|
|
|
|
It's not possible to do because the sound cards do not support input based on decibels. You would need to set the levels on the the Microphone to known values, and keep them there, then you would need a calibration device that measures decibels and a source of calibrated sound to know at what levels the Microphone is hearing the sound. Once you have the input levels mapped to known decibel values, then you can just monitor the mic for known decibel levels of sound.
Someone asked this very same question about a month or two ago...
Hmmm....
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
But how programs like SoundForge, Adobe Audition (CoolEdit) or any other audio programs show the level in db of the sound without any Microphone or calibration?
> Someone asked this very same question about a month or two ago...
I try to found in this board messages about this problem? but i found nothing.
Many years ago i create such ptogram on pascal under dos. But now i need to write it on C# under Windows. I can't find any docs about this theme.
|
|
|
|
|
That's because you're under the impression that "decibel" is a measure of the loudness of a sound. It's not. It's a measure of relative signal strength. Those programs are showing you the decibel power of a small sample of a signal relative to itself, or the signal strength around the sample. There is absolutely no way a sound card can tell you what the decibel power of a sound is because it has no reference to compare it to.
Don't bother searching for the answer to the previous question. It's the same as this one.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Hi,
For my application i need grid control having future of typing data in grid cells. like billing. any suggestion or any samples send to me. make cc to murali_utr@vsnl.net
thanks in advance!!!!!!!!!!!
Have A Nice Day!
Murali.M
|
|
|
|
|
I have written a billing system using the dataGrid control. Let me know exactly what you are looking for and I might be able to help you out. But please, keep it in the forum instead of private e-Mails, as it may help others as well.
|
|
|
|
|
hi,
thanks for ur reply. in case of DataGrid is faced some problems in vb 6.0. so afraid about datagrid then only searching any other control. I don't know how this working on C#.Net. How u feel datagrid in ur project. it's ok to do?
Have A Nice Day!
Murali.M
|
|
|
|
|
The .Net datagrid seems to be very stable and easy to use. I wouldn't hesitate to include it in your form. The simplest method I have found for using the datagrid for this type of project is once you have an invoice or order ID, you bind your datagrid to a dataset with "items" that are being purchased. Each of these items has a column for Invoice/Order ID as well.
I think if you use the datagrid, you'll be happy with your choice. For a project such as this, there are a few details you have to keep in mind, such as calculating line totals from the price and quantity. If you need help with things like this, just keep replying in this post, or start another one...I don't respond much, but I read the questions on codeproject almost every day!
- D
|
|
|
|
|
Hello everybody
Can anybody tell me how to generate Msn Messnager 6 or higher's chat log styled XML Decuments.
Cheers
take care byee
Rizwan Ahmed
|
|
|
|
|
Can you be a little more specific? Have you even read the .NET Framework SDK for the System.Xml[^] namespace, or are you just looking for someone to do the work for you. You won't find the latter here.
This forum is for asking specific questions, not finding free help. Read the documentation for classes like the XmlTextWriter or the XmlDocument and, if you have questions, ask here.
Microsoft MVP, Visual C#
My Articles
|
|
|
|
|
thank you sir. actually i wanted a quick hellp coz i have never studied it nut want to use some where in my project.
1. for a little data base
2. dor genrating well formed documents.
any wayz thnx for reply
God bless
byeeee
Rizwan Ahmed
|
|
|
|
|
There's plenty of articles here on CodeProject dealing with such topics - just search or browse the categories. "quick help" won't teach you anything.
Microsoft MVP, Visual C#
My Articles
|
|
|
|
|
Thnkxx again sir
|
|
|
|
|
Hi
Now I try to work with C#,but my trouble common and with COM programmin in standart C++. My application had to process an *.xml file through Excel COM. Cause of I use native Excel help for VBA : “VBAXL9.CHM” .But there is any troubles .When C# generate proxy for excel object it not consider about optional argument and cause of I should explicit pass this arguments every time in methods call. In many places into excel help referenced behavior of an methods with parameters by default (optional parameters which omit), but I don’t know what it are.
Where I can learn about definition of this defaults parameters????
|
|
|
|
|
Use Missing.Value , or something like this for optional parameters:
object missing = Missing.Value;
excel.Save("filename.xls", ref missing, ref missing, ...); (Note: this is sample code; it won't compile)
The help still applies. Since the RCW (Runtime Callable Wrapper) is generated over the typelib, the types and members are the same (may marshal a little differently; knowing comes from reading and experience).
Read Interoperating with Unmanaged Code[^] in the .NET Framework SDK - especially the parts about COM interop and COM marshaling - for more information.
Microsoft MVP, Visual C#
My Articles
|
|
|
|
|
|
And quit crossing posting in so many Forums. It's considered very rude...
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Hi there all
Has anyone experienced the NetworkStream gotten from the TcpClient underload conditions sends out packets in reverse!?
I have done a low-level packet capture of my local port and it confirms what I see at the server. Packets that are queued , tend to get mixed up when the buffer is not full. Seems to send the packets while actually sorting them... any ideas?
top secret xacc-ide 0.0.1
|
|
|
|
|
Set TcpClient.NoDelay to true (default is false ). This disables coalescing of packets by sending them immediately instead of storing them until a significant amount of data can be sent. This results in a more chatty protocol, but should eliminate the problems you're having.
Microsoft MVP, Visual C#
My Articles
|
|
|
|
|
Heath Stewart wrote:
TcpClient.NoDelay to true
Tried that, and every property I have access too, still the same...
top secret xacc-ide 0.0.1
|
|
|
|
|
Other things I have tried (but same results):
- Send ever packet via a threadpool
It only happens when the NetworkStream is buffering (when doing Write in "quick" (still by hand!) succession). Its not the server either, this has been verified by the captured packets, and the fact that an unmamaged client behaves correctly in the same scenario.
top secret xacc-ide 0.0.1
|
|
|
|
|
Out of curiosity (sorry, no clue what might be wrong without digging into lots of IL (and a lot is actually internal implementation in the CLR - I always hate that road block)), why would you try to solve this in a ThreadPool ? I would expect that to make it worse (nothing says your queued work items are executed in order).
Microsoft MVP, Visual C#
My Articles
|
|
|
|
|
My initial idea, although I dont think it works like I thought ( ) was to just get a little pause or something, tried some locks too.
Basically I place a Console.Write after the NetworkStream.Write , so I can see it IS being dispatched by me, in a sequencial order, which I have confirmed.
Here is a trimmed version of a packet "dispatch" leaving my port, as captured, by NGSniff and WinPCap, each line refers to a stream.Write action, where the id is generated sequencially, and the data is just entered on the keyboard. This refers to a single packet leaving my network port.
id="msg135" 7
id="msg134" 6
id="msg136" 8
id="msg137" 9
In this case, the order seems random, most other cases the order seems to be in reverse, that would look like:
id="msg137" 9
id="msg136" 8
id="msg135" 7
id="msg134" 6
This can surely not be the real behaviour of the NetworkStream, as for a workaround I would have to add an unessary packet layer that should already be provided on a lower OSI level.
Thanks for trying to help though
top secret xacc-ide 0.0.1
|
|
|
|