|
First of all never post valid ip addresses in the public domain, it can lead to some nasty things.
Since your using an router you'd have to either connect to the router and read the ip address from there or use a web site such as MyIPAddress.com to find it out.
You'd have to use an HTTPWebRequest to get the information, and then weed out your IP.
Unless anyone knows of a different way.
|
|
|
|
|
Look for a network class DNS. some of the methods are gethostbyname etc. You'll see one in there for retreiving your ip address.
|
|
|
|
|
Hi All!
Do you know about Multi Monitors.
I have a card Video have multi TV outputs.
I want to use only one PC to display to TVs.
pls, show me your solution.
Best regards.
---------------
I Don't want say no wealth.
|
|
|
|
|
|
Oh, Thank, I'm C# Developer.
I need a solution for my problem.
I want to write A software to control data thay display to Screen of TV by Card Convertor.
|
|
|
|
|
You need hardware, not C#.
|
|
|
|
|
No, I don't need hardware, I had hardware, But I have never software. Now, I have to develope a software. Do you know it. pls, send me source code if you have.
Thanks for your help.
Best regards.
|
|
|
|
|
Hello,
I have a problem with the SerialPort Control under VC# Express 2005.
In my application I have to read data from an external device through RS 232.
The process is built on a software-based handshaking which depends on the device.
The process has been implemented by me and works but unfortunately only the first time.
All data are donwloaded successfully as required.
The process is simple serialPort11.Open(), Handshaking, Data Download, Handshaking, serialPort1.Close().
The problem occurs with the second run, when the same procedure is executed again (using a button_onclick event), then the Port is opened again with serialPort1.Open() and with the first serialPort1.readByte() a TimeOut Error occurs.
Even if the Timeout is set to 10sec it does not help.
If the application is restarted and the process is again executed, then the data are read perfectly from the device. Hence it does not depend on the state of the external device, but on the PC (Soft and/or Hardware).
I have the feeling, that closing the SerialPort with serialPort1.Close() does not free all resources and possibly the hardware RS232 is not fully reset.
Has anyone had a similar problem and found a solution for it?
Can you rely on serialPort1.Close()? Are all resources freed?
I hope someone can help
Thanks a lot in advance
Best regards,
Carsten
|
|
|
|
|
Is there really no one who has discovered the same problem?
C.
Regards,
Carsten
|
|
|
|
|
Hello Friends,
An unhandled exception of type 'System.NullReferenceException' occurred in Unknown Module.
Additional information: [Resource lookup failed - infinite recursion detected. Resource name: Arg_NullReferenceException]
Has anyone come across this ?? I am working with a GDI+ user control where i do a bulk of drawing, say atleast 500 MB of data. This drawing is performed in a seperate thread from the main control thread with proper interruption techniques to stop drawing in between.
The problem am facing is, it works perfectly in Win XP environment, no issues. When it comes to Win 2000 the above mentioned exception pops in regularly when i try to interrupt the drawing thread.
can any help me out of this?? Even some clues will be a great help cos the error doesnt give any clue
Hariharan.T
|
|
|
|
|
Hey all,
I've been playing with this for two days now and I cannot get this to work. I have a form, two TabControls on the form. In one of the TabControls, I have a datagrid in there along with a textbox and a search button. I am trying to get the auto-resize anchor/dock functions working correctly, but nothing that I do seems to work. I've tried panels, splitters, using the Anchor/Dock methods every way I can think, but it never displays properly. Basically, it looks like this:
[SEARCH TEXT BOX] [SEARCH BUTTON]
* DATA GRID HERE TAKING UP REST OF THE SCREEN(TAB) *
I want it so that when the user resizes the form, it leaves the search text box and the search button on the top (not resize them and make them huge), but only resizes the datagrid to take up the remaining space. When I play with all the different features, the datagrid usually ends up overtaking the space where the search bar/button is, and it overlaps. I'm clueless as to how to make this work properly. Any help would be appreciated.
|
|
|
|
|
Hi shultas,
Give the following a try:
Search Text Box Settings
First, make sure the Dock property is set to "None".
Set the Anchor property to Left, Top, Right.
This should make the text box expand its width, but not its height when the form is expanded.
Search Button Settings
Again, make sure Dock is set to "None".
Set the Anchor property to Top, Right.
This should make the search button attach itself to the right side of the form when the form is expanded, but keep its width the same.
Data Grid Settings
Make sure Dock is set to "None".
Set the Anchor property to Left, Top, Right, Bottom.
This should make the data grid expand its width and height with the form when it is resized.
Tab Control Settings
I'm not sure where your two tab controls are positioned relative to the form, but you'll need to adjust the Anchor property of the tab control which contains the data grid, search text box, and search button. I think you'd probably want to set the Anchor property to Left, Top, Right, Bottom, so that it gets its share of the extra horizontal and vertical space when the form is expanded.
Give those settings a shot. If it doesn't work, please let me know and I'll try to help you as best I can.
Sincerely,
Alexander Wiseman
|
|
|
|
|
I do not seem to be getting any back when the host side of a socket connection closes softly....meaning..the app on the host side that is listening has closed, but the infrastructure is still present.
Even when I send a packet I'm not getting an exception. Any ideas?
Thanks
Tom Wright
tawright915@yahoo.com
|
|
|
|
|
More information perhaps
Formula 1 - Short for "F1 Racing" - named after the standard "help" key in Windows, it's a sport where participants desperately search through software help files trying to find actual documentation. It's tedious and somewhat cruel, most matches ending in a draw as no participant is able to find anything helpful. - Shog9
Ed
|
|
|
|
|
At the line level there are two types of results from a socket close. A RST or a FIN (reset or fin). If you close a socket there is no data that should be seen at the application layer.
All network programming comes in two flavors Synchronous, and Asynchronous (from the application perspective). You say you don't get anything back? Change the close code to synchronous. You'll at least get an indicator back.
|
|
|
|
|
In a lot of classes I'm working on I find that having a params parameter would be really handy. For instance a polyline constructor taking points as arguments:
public Polyline4D(params Vector4D[] points) { }
Is there any argument against params parameters (like performance, or language support)?
Also it would have been pretty convenient for .NET's List<T>.Add or List<T>.AddRange also had a params overload. Did they have good reasons not to?
Wout
|
|
|
|
|
private void SomeMethod(Point[] points) probably works well in a type sensitive manner.
A man said to the universe:
"Sir I exist!"
"However," replied the Universe, "The fact has not created in me A sense of obligation."
-- Stephen Crane
|
|
|
|
|
|
Params must be the last parameter in the list and a one dimensional array as well. Personally I don't understand the point of a params keyword if the language supports array parameters and object arrays.
A man said to the universe:
"Sir I exist!"
"However," replied the Universe, "The fact has not created in me A sense of obligation."
-- Stephen Crane
|
|
|
|
|
Ennis Ray Lynch, Jr. wrote: Personally I don't understand the point of a params keyword if the language supports array parameters and object arrays.
The syntax candy comes in handy when calling the method. Which one looks cleaner?
<br />
Foobar(new Foo[] { foo1, foo2 });
or
Foobar(foo1, foo2);
Tech, life, family, faith: Give me a visit.
I'm currently blogging about: Goof around music jam with my brothers (with video)
The apostle Paul, modernly speaking: Epistles of Paul
Judah Himango
|
|
|
|
|
Use the minimum syntax necessary to achieve readbility. IMHO, an arbitray parameter list is less documenting. Of course by the same token, which one looks cleaner
Foobar(this.foo);
or
Foobar(this.foo[0], this.foo[1], this.foo[2]);
Really I wouldn't fault you for using Params I just don't prefer it.
A man said to the universe:
"Sir I exist!"
"However," replied the Universe, "The fact has not created in me A sense of obligation."
-- Stephen Crane
|
|
|
|
|
Ennis Ray Lynch, Jr. wrote: Foobar(this.foo);
That will work for the param keyword too. Test it, you can pass an array instead of the optional params.
|
|
|
|
|
I have to agree with leppie, I don't see the clarity argument either. The programmer can use both styles of calling.
Wout
|
|
|
|
|
There is a small speed penalty, but else its just a 'compiler macro' like foreach (not really, its a bit more internal).
wout de zeeuw wrote: public Polyline4D(params Vector4D points) { }
params Vector4D[] points <-- note the array.
|
|
|
|
|
Ah, sorry, forgot the array thing yes (I'll mod the post and erase my traces ).
Would there be a runtime penalty? I would have guessed that just the compiler would insert a new Vector4D[] { a, b, c } statement, which the programmer would otherwise have to do manually.
Thanks,
Wout
|
|
|
|