|
I'm told the 32-bit XP program used:
... int nRet = SendMessage(hWndC.ToInt32(), WM_GETTEXT, cap, buffer);
but the original programmer does not recall why that did not work on the 64-bit Vista machine.
Thanks Dave, I'll give WM_GETTEXT another try.
|
|
|
|
|
IceWater42 wrote: int nRet = SendMessage(hWndC.ToInt32(), WM_GETTEXT, cap, buffer);
It fails on 64-bit machines because window handles in 64-bit Windows are 64 bits wide. Look at what you passed in the first parameter. A signed, 32-bit integer, instead of a 64-bit wide IntPtr. Change that so hWndC returns an IntPtr and it should work.
|
|
|
|
|
i want to create one window service for watching a file. whenever file content change i want to get new data, which is just comes to file.
how can i do this. there is any way to do this??
yogesh
|
|
|
|
|
Need more information. Is it a text file to which additional data is added at the end, like a log file? I've written a Windows Service to do that.
|
|
|
|
|
yes that is a text file. whenever new data comes to file, i want to perform some action through window service. please help me sir,
yogesh
|
|
|
|
|
I had the service running on a thirty* second cycle; on each cycle it would:
0) Open the file
1) Seek to the position where it had read to on the last read
2) Read to the end of the file
3) Close the file
4) Store the new position
There were a number of other challenges to overcome, including being sure that it read only complete lines.
Your requirements may vary.
* Configurable.
|
|
|
|
|
could u give me code for that????
yogesh
|
|
|
|
|
It wouldn't be much use to you; it's very specific to one situation.
But with what I've said so far and an article on writing a Windows Service you should have a working version by the end of the week.
|
|
|
|
|
Create a Windows service and use the FileSystemWatcher class. You will get an event every time your file has been changed.
Patrik
|
|
|
|
|
That might be suitable for the OP's requirements, but not mine.
|
|
|
|
|
I have a app that list users that are locked out but it shows this in my combobox
billy-Noel Schmitlin,OU=Quality-Labo,OU=Users,OU=Soultz,DC=jacob-wonder,DC=com
i just want it to show "Billy-Noel" just the users name
what i have searched removes the CN= but thats it
<br />
strName = strName.Remove(0, 3); <br />
Thank you for your time.
|
|
|
|
|
Hi,
Split() on the first char you don't want, I guess that is a comma.
And read up on string class.
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
Some mupet-numb-nuts gave you onesy, so I've dropped a five on top to make it better.
Panic, Chaos, Destruction.
My work here is done.
|
|
|
|
|
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
or you could try:
int i = yourString.IndexOf(",");
string s = yourString.SubString(0,i);
|
|
|
|
|
Thanks for the help ill give that a go.
-Summey
|
|
|
|
|
Good people,
We have created a .NET application that will include several MP3 music files. We have approximately 12 MP3 files. These files are quite large (some are around 11MB). Therefore, our installable executable file is also quite large.
We plan on reducing the size of the MP3 files, however, I was wondering if there was some sort of best practice or common way to include music files in your .NET software application? If I zip up all the MP3 files, how do I tell .NET installer to unzip the files into the correct directory?
Thanks,
Blitz
|
|
|
|
|
Zipping MP3's generally doesn't help
|
|
|
|
|
MP3 is a compressed format, and it's lossy, hence it gives a quite good compression rate. Zipping MP3s won't usually reduce their size enough to make a difference.
2+2=5 for very large amounts of 2
(always loved that one hehe!)
|
|
|
|
|
Hi! You have seen programs like TeamViewer. How can I monitor the desktop of another computer and send the information to a client using C#. How can I film the desktop and send it like a stream video?
Can you give some directions on what approach to take?
Still learning...
|
|
|
|
|
|
nike_arh wrote: Still learning clueless...
Fixed a minor inaccuracy for you.
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
I've done one in C++, it won't be very hard to so in C# as well. As you seem to be clueless from your previous posts, may be your should hire someone else to do it for you.
In case you wondering my charges are $500/hr it may take me around 6 weeks to complete ( so you are looking $500 * 40 * 6)
|
|
|
|
|
|
Thats 240 000 cans of coke (in my country)
|
|
|
|