|
No sorry,
It was an idea
What error message you get?
Sincerely,
Elina
Life is great!!!
Enjoy every moment of it!
|
|
|
|
|
The code that Elina suggested is basically correct. What you have to do is just substitute the "Number" with the value you want to send into the function.
What do you mean by "doesn't work", really? What happens? Do you get an error message?
What does the "..." in the function represent? Do you use the value of the parameter at all?
---
b { font-weight: normal; }
|
|
|
|
|
private int YourNo(int Number)<br />
{<br />
int x = 10;<br />
int y = 5;<br />
Number=(X+Y)*100;<br />
return Number;<br />
}<br />
<br />
<br />
<br />
private void calculate_Click((object sender, EventArgs e)<br />
{<br />
txtNumber.Text= YourNo(Convert.ToInt32(txtNumber.Text)).ToString();<br />
}
|
|
|
|
|
hi there !
thnks for ur reply !
albCode wrote: txtNumber.Text= YourNo(Convert.ToInt32(txtNumber.Text)).ToString();
Why "YourNo(Convert.ToInt32(txtNumber.Text))..." ? , I want to use of "Number Parameter " , when I clicked the button ,
Regards ,
s_mostafa_h
|
|
|
|
|
mostafa_h wrote: Why "YourNo(Convert.ToInt32(txtNumber.Text))..." ?
txtNumber.Text is parameter which u give in YourNo
|
|
|
|
|
but I want to use the return Value "Number" in Event .
txtNumber.Text= YourNo(Number).ToString();
but I have this Error message :
the name 'Number' doesn't exist in the current context .
Regards ,
s_mostafa_h
|
|
|
|
|
the problem was solved as following :
private int YourNo(out int Number)
{
...
Number=(X+Y)*100;
return Number;
}
and :
private void calculate_Click((object sender, EventArgs e)
{
int output;
YourNo(out output);
txtNumber.Text=output.ToString();
}
Regards ,
s_mostafa_h
|
|
|
|
|
Hello i have a C# program which loads a excel file and read its contents. I want to know how can my program be notified if some one modifies the file i am using so that i get the new data. I can handle events for excel object which opened through my program but what if some other user opens the files and modifies and i want that notification. Is there way i can send a remoting message from excel event handlers to C# application?. If so any help or code snippets will be great help
venky
|
|
|
|
|
Why don't you just use a FileSystemWatcher to watch files in that directory?
Logifusion[^]
|
|
|
|
|
well,i can try that but is there any other way? Is there a way to send a remoting call from Excel event handlers?
|
|
|
|
|
what should i do to make my label accepting multiple line of text.
I remember in vb5 we can resize the label the way we want to and the text will wrap automatically too.
Donkaiser
|
|
|
|
|
set autosize to false
Donkaiser
|
|
|
|
|
Hey, I know there is suppose to be a class System.Runtime.Serialization.Formatters.SOAP.SoapFormatter
but I don't even have the namespace System.Runtime.Serialization.Formatters.SOAP, what's the problem?
NaNg.
|
|
|
|
|
You need to reference a separate assembly, with a name like System.Runtime.Serialization.Formatters.SOAP
Josh
|
|
|
|
|
|
Is there any way possible to post a small icon in a cell when your view property on your listview is set to "details". I was trying to highlight my cells but the color doesn't hold when i scroll over it or select it(it reverts back to white) so I thought maybe i could just add an icon.
|
|
|
|
|
|
lulu0441 wrote: do it in C++
You posted this same question in three different forums. Why? It's clearly a homework assignment to be done in C++.
"The largest fire starts but with the smallest spark." - David Crow
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Can you do it in any ways ?
|
|
|
|
|
lulu0441 wrote: Can you do it in any ways?
Probably, but I won't. If people enable you to cheat now, things will only be rougher for you later on. Be responsible and do your own homework.
"The largest fire starts but with the smallest spark." - David Crow
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Go away.
|
|
|
|
|
static void Main()
{
System.Console.Writeline("I am trying to cheat on my homework");
}
|
|
|
|
|
Yeah, Lulu - that should do the trick.
|
|
|
|
|
hello everybody .
iam testing NAT Traversal through UPNP technology to negotiate with the NAT Router and Firewall but there is a problem in the Com Component that iam using from microsoft Which is located at System32 in your windows installation folder called UPNP.dll and Hnetcfg.dll
the problem is that i always have the collection with value Null that is why i can't be able to iterate through all static ports and ip address in my router (iam using Dial up connection not DSL)
here is the code that raise the problem
<br />
using System;<br />
using NatUpnp;<br />
<br />
namespace SnoutoOverride<br />
{<br />
class Nat<br />
{<br />
public Nat(){<br />
<br />
<br />
}<br />
<br />
private void InitializeNat(){<br />
<br />
IUpnpNat NatMgr = (IUpnpNat)new UpnpNatClass();<br />
<br />
foreach(IStaticPortMapping portmap in CurrentCollection)<br />
{<br />
}<br />
}<br />
}<br />
}<br />
The line Of code that has the many asterisks has the problem in which this returned collection is always be null that is why i can't iterate through the available external ip addresses or ports . so is there any solution regarding that . AT Msdn explains that but it doesn't seem that this collection returned with value null with them at all . If this problem is solved the whole problem will be vanished.
Is there any Solutions Freaks.
Human knowledge belongs to the world.
|
|
|
|
|
There could be many issues.
You should be discovering devices, not creating them. Do a DISCOVER for all nat devices on the network, then iterate to the correct one, and use that instance, to get more info (yes, the design of UPnP requires another call at this stage). then you should have the correct info.
That said, many UPnP devices arent using strict HTTP spec's and the UPnP.dll can fail sometimes. In that case you will have to write your own.
Other than that, have you looked ta Intel's UPnP tools? They written for .NET
|
|
|
|