|
I can easyly do this but then I have to write 100 line of code.
If I can get work by this method, it will tak eonly 10-20 lines.
Thanks.
|
|
|
|
|
|
Please, use normal English in here. I myself are not best at english, but please don't use msn/sms- language in here....
U... this is a letter in the alphabet.
You... this is a word which you can see as a pointer to a person you refer to.
|
|
|
|
|
sorry
OKay im again trying to make you understnd.
I want to pass an form object to a method.
Exmp:
I have a form form1.
public void btnClick(object sender, EventArgs e)
{
showForm(formObject);
}
showForm(......)\\ is there any way to catch it here)
{
formObject frmObj = new formObject(); \\ If there has any way then will it work
}
Thanks
|
|
|
|
|
The comment wasn't for you, but for Prajeesh.
But to help you with your problem. You can just do this with a normal parameter.
public void btnClick(object sender, EventArgs e)
{
showForm(formObject);
}
public void showForm(Form myForm)
{
myForm.Show();
}
If this is not what you mean, then you have to specify the problem slightly better.
|
|
|
|
|
Im afried sorry.
Actually I mean a form object passing to method.
By that I can create instance of that object in that method.
Exml:
void showForm( catch the form object)
{
objectName frm = new objectName();
}
public void button_click(..)
{
showForm(formObject);\\ formObject is a type by this i can creat form instance.
}
If you cant get inform me.
Thanks
|
|
|
|
|
I'm sorry, but I've never seen such thing working.
But what's the difference of doing it your way or doing it this way:
void showForm( Iobject obj)
{
}
public void button_click(..)
{
showForm(new formObject());
}
Add an interface to your class so you can use different kinds of classes.
I think your problem is solved by this.
|
|
|
|
|
Hahaha
Okay may be im talking stupid but i need it now
Ya i think i have the ans.
Thanks
|
|
|
|
|
Let's see if I understood what you mean.
You want to pass to the showForm method the type of form to show and then show the kind of form desired.
If it's so, you can use reflection in the following way:
void ShowForm(Type formType)
{
Form frm = Activator.CreateInstance(formType) as Form;
if (frm != null)
{
frm.Show();
}
else
{
}
}
Is this what you wanted to do?
modified on Friday, February 27, 2009 11:14 AM
|
|
|
|
|
it is interesting..
Thanks
I will try it later.
|
|
|
|
|
I can't realy understand your examples (your naming is srtoa off), but if you just try to pass a button and a form to a method, they are objects like everything else.
void PassButton(Button myButton)
{
}
void PassForm(Form myForm)
{
}
|
|
|
|
|
I have project to tracking the eye, I need the smallest algorithm to use can any body help me with it, or some links that are related.(I need it in C#)
|
|
|
|
|
|
thank you but i see the program before.
thank you agin
can any body else help me
|
|
|
|
|
some help with my project please
|
|
|
|
|
Can you explain why you are asking the same question as yesterday?
If you want someone to write a progra for you, try rentacoder.
If you want to find out how something should work, try google.
If you have actually tried something and need help with a problem in your code, not in your head, then ask away here.
Panic, Chaos, Destruction.
My work here is done.
|
|
|
|
|
OK
how can I detrmine the pupil with ROI algorithem
|
|
|
|
|
1) Republic of Ireland algorithm? Never heard of it.
2) This does sound suspiciously like a google question and google will serve you a delicious feast of answers if you try.
3) Find out what you want to do and come back with any problems you have doing it.
That's all. Any more of these half brained antics and I'll start getting grumpy.
Panic, Chaos, Destruction.
My work here is done.
|
|
|
|
|
Regain Of Interest not Republic of Ireland
|
|
|
|
|
i want to decrypt the text(means anytype of text)in to oriya language in c#.net wat's the code
|
|
|
|
|
you asked this just four hours ago. asking a stupid question without describing what exactly your problem is, won't get you an answer.
asking for "the code" will definitely get you no answer!
"I love deadlines. I like the whooshing sound they make as they fly by." (DNA)
|
|
|
|
|
i'm using first time code project i don't know how to ask a qestion properly.actually the problem is my project is in vb6.0 now we r changing to c#.net .in vb project backend is ms-access in that text is encrypted.that text will be appear oriya in c#.net.that's y i'm trying to converting .i take one windows application one textbox n button in the textbox i write english word wen i clicked on the button that word will be changed to oriya language.i searched in google but the xamples r coming but those r webapplications.
|
|
|
|
|
Ok, welcome to codeproject. Click my signature link, it will tell you the rules. A few key points to remember;
-we are not employees and you are not the boss, if you want code write it, or go to www.rentacoder.com and pay for it.
-never ask for code, never.
-this forum is more for specific problems, if you get stuck compiling and can't figure out an error, questions about specific methods or algorithms
|
|
|
|
|
easy...
string newText = TextDecrypt.DecryptText(myText, "oriya");
TextDecrypt can be found in the System.WTF namespace.... maybe im mistaken thou
If only MySelf.Visible was more than just a getter...
A person can produce over 5 times there own body weight in excrement each year... please re-read your questions before posting
|
|
|
|
|
Bad question. Game over. Try again.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|