Re: Making a Part of code to be executed once
- From: "Ignacio Machin \( .NET/ C# MVP \)" <machin TA laceupsolutions.com>
- Date: Mon, 25 Jun 2007 09:47:38 -0400
Hi,
"sravan_reddy001" <sravanganta2002@xxxxxxxxx> wrote in message
news:1182736895.520683.43830@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
this is what i want to do...
method()
{
--------
if(flag)
{
code; and flag=false
}
----
}
making this will execute the code only once and i'm never going to
change the flag to true(flag is boolean)
i can't use the init() method... the code is linked with the the
method's operation.
Is there any other method??
What is wrong with that?
If you are worried about performance, forget it. A simple if has no
repercusion overall.
.
- References:
- Making a Part of code to be executed once
- From: sravan_reddy001
- Re: Making a Part of code to be executed once
- From: Diego Jancic
- Re: Making a Part of code to be executed once
- From: sravan_reddy001
- Making a Part of code to be executed once
- Prev by Date: Re: Key Press event when no focus
- Next by Date: Re: ContainsKey() does not find key
- Previous by thread: Re: Making a Part of code to be executed once
- Next by thread: Creating strings using Console.WriteLine format
- Index(es):
Relevant Pages
|