|
Thank you for the answer
|
|
|
|
|
Can we make two function in a class that have same name and same number of parameters but function return types are different.
Can anybody help me.
Thanks in advance.
kartik rathi
|
|
|
|
|
|
Ya I too think so you need to have some difference in the parameters.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Creating a function with the same name is called overloading. You can create as many functions as you want with the same name, as long as the parameters are not the same number.
Why do I mean by the same?
You can have two functions with the same number of parameters as long as at least one of them is of a different type than the other definion.
But this will not compile:
public void abc(int m)<br />
{<br />
}<br />
<br />
public int abc(int m)<br />
{<br />
}
because the return type is not part of the function signature. Only the name and the parameters are.
regards,
Mircea
Many people spend their life going to sleep when they’re not sleepy and waking up while they still are.
|
|
|
|
|
Nice expalnation.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Hi Friends,
Why the asp.net controls having two different width and height in IE and mozilla firefox?
Regards,
Thomas
|
|
|
|
|
Well they don't but if they display differently in IE than Mozilla, it's because of the incompatibilities probably caused by the elements they reside into (tables, divs, etc). These are usually the ones that cause problems with height/width display.
regards,
Mircea
Many people spend their life going to sleep when they’re not sleepy and waking up while they still are.
|
|
|
|
|
|
Quite informative.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Hello,
How can I provide different data formats in my web application.
Some user wants PST (mm/dd/yyyy), some wants IST(dd/mm/yyyy).
My database date setting is PST.
If any one have idea, please advice.
Best Regards,
S Kumar
|
|
|
|
|
If you want to display the dateformat according to the user then you can store the dateformats for each of the user in the database and then you can display the date in user format.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Hi Apurva Kaushal,
Formatting is not a issue while dispalying to user.
My Problem is USER INTERFACE, while entering data some user wants to enter data in mm/dd/yyyy format and some user wants to enter data in dd/mm/yyyy.
But database setting is mm/dd/yyyy only.
Best Regards,
S Kumar
|
|
|
|
|
Here two(there may be some more also) ways are there which you can opt for:
1. either you use a javascript calender(for the user to enter the date) or you can even use dropdownlist control for the user to select the date.
2. If user has to enter the specifically in a textbox then enforce to enter in a particular format.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Hi Apurva,
Thanks for your reply.
Presently we have have text box for date fields and users are habitual for this, I think we can't change to drop down box.
Best Regards,
S Kumar
|
|
|
|
|
In that case I feared you have to go for the enforcement for the format of the date i.e ask the user to enter the date in a particular format.
Best Regards,
Apurva Kaushal
|
|
|
|
|
How can I create a CAPTCHA imagte in ASP without using any Service like www.CAPTCHA.net?
Arghya Mahapatra
|
|
|
|
|
|
Hi
I have a simple masterpage setup going. With a default "form1" form in the masterpage and a "hdnProvinceHTML" HTML hidden input control in one of the content pages.
The same content page has a block of JavaScript that needs to access the value of the hidden control.
alert(form1.hdnProvinceHTML.value) tells me that the controls are undefined.
If I look at the source of the running page I see that .Net has changed the names of my controls, and calling
alert(document.aspnetForm.ctl00$mainContentPlaceHolder$hdnProvinceHTML.value);
works.
Is there a way around this? What are the odds that .Net will always asign those names to the controls? And why is this happening in the first place?
Thanks a lot for any help...
|
|
|
|
|
Amos_Keeto wrote: What are the odds that .Net will always asign those names to the cont
Those names represent the control in the hierarchy of controls. Meaning the controls inside which your control is present. The odds that the name will be the same depending on the control mostly. It is not good practice to hardcode the names into the javascript. What you could do is register a call to the javascript function from codebehind.
You can get the full name of the control that will be registered in the page, by calling controlname.ClientID . So you could register in your codebehind something like
RegisterClientScriptBlock("genericname","alert(" + hdnProvinceHTML.ClientID +");")
regards,
Mircea
Many people spend their life going to sleep when they’re not sleepy and waking up while they still are.
|
|
|
|
|
Thanks, I'll certainly give it a try...
But ofcourse I have been yanked from that project to "quickly have a look at and fix a bug" in another project, so I don't know when I'll get around to it... grrr
|
|
|
|
|
Well, the idea is that you can get the ID that is generated in the browser by calling the controlname.ClientID method. From there you can call a javascript function passing the name as a parameter, and get a javascript refernce for the control with getElementById('clientsidename') that return the object. You can perform any operations on it from that point on.
Good luck with bugfixing.
regards,
Mircea
Many people spend their life going to sleep when they’re not sleepy and waking up while they still are.
|
|
|
|
|
Hi all,
I have installed VS.net 1.1 on a machine running Windows XP. Whenever I create a new web application it always throw error - Access to the path "c:\windows\microsoft.net\framework\v1.1.4322\Temporary ASP.NET Files\webapplication2\37f71cbe\939c5907" is denied.
I have also excluded "c:\windows\microsoft.net\framework\v1.1.4322\Temporary ASP.NET Files" folder from indexing services but same problem continues. When I go in folder "c:\windows\microsoft.net\framework\v1.1.4322\Temporary ASP.NET Files" there is no other folder or file except Bind Logs which is also empty.
Waiting for your valuable ideas.
Thanks
God help those who help others
Varun
|
|
|
|
|
|
I want to merge or Append mulitple Tiffs into one Tiff.
Can you suggest some way out for this.
Actually I finds lot of things on Internet, But they are selling whole
package of Imaging. I just want one assembly from third party tool
to get it Done.
kartik rathi
|
|
|
|