|
Post back is the only problem for me I dont want to use it. I want to display a Date field with three combo boxes. When month and year are selected, automatically the days combo must me filled with those many number of days according to leap or not and then 31 or 30 like that. So please help me if any body could do it.
Thank you.
S/W Engineer
Akebono Soft Technologies
aleem_abdul@akebonosoft.com.
|
|
|
|
|
Try this Javascript function on each combo's on change event....
function GetDayOfMonth(DayCtrlName, MonthCtrlName, YearCtrlName){
var DayCtrl=document.getElementById(DayCtrlName);
var MonthCtrl=document.getElementById(MonthCtrlName);
var YearCtrl=document.getElementById(YearCtrlName);
var lastDayValue=DayCtrl.value;
var DaysCount=31;
if (MonthCtrl.options[MonthCtrl.selectedIndex].value=='2' &&
(parseInt(YearCtrl.options[YearCtrl.selectedIndex].value)%4)==0){
DaysCount=29;
}else if (MonthCtrl.options[MonthCtrl.selectedIndex].value=='2'){
DaysCount=28;
}else if (MonthCtrl.options[MonthCtrl.selectedIndex].value=='4' ||
MonthCtrl.options[MonthCtrl.selectedIndex].value=='6' ||
MonthCtrl.options[MonthCtrl.selectedIndex].value=='9' ||
MonthCtrl.options[MonthCtrl.selectedIndex].value=='11'){
DaysCount=30;
}
DayCtrl.options.length=0;
var oOption;
for (var i=1;i<=DaysCount;i++){
oOption = document.createElement('option');
DayCtrl.options.add(oOption);
oOption.innerHTML=i;
oOption.value=i;
if (i==lastDayValue) oOption.selected=true;
}
}
Regards,
Venkatesh Mookkan.
|
|
|
|
|
I tried to connect in this way the javascript function to "OnSelectedIndexChanged" event hanlder. But Its not giving me any thing. Means its not adding this "Javascript" function to the event. What may be the problem. If you can please help me by giving some code snippet too please.
ddlMonRes.Attributes.Add("OnSelectedIndexChanged", "GetDayOfMonth1();")
S/W Engineer
Akebono Soft Technologies
aleem_abdul@akebonosoft.com.
|
|
|
|
|
Hi,
i am using class System.EnterpriseServices for transaction management and i m using a strong name file keypair for strong name and keypair1.snk for strong name token and i give the key pair file name in solution explorer\Property pages\Msbuild option but when i compiled web project in debug mode its giving me error. i have paste the compelete error message.
I m confused why visual studio create random files for this and why its not running from my virtual folder if some body know about this error reply me soon
Best Regards
Tariq Mahmood
System.EnterpriseServices.RegistrationException was unhandled by user code
Message="The assembly 'C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\trinity\951852e9\59d35ae4\App_Code.xsmhqh4d.dll' does not have a strong name."
Source="System.EnterpriseServices"
StackTrace:
at System.EnterpriseServices.RegistrationDriver.InstallAssembly(RegistrationConfig regConfig, Object obSync)
at System.EnterpriseServices.RegistrationHelper.InstallAssemblyFromConfig(RegistrationConfig& regConfig)
at System.EnterpriseServices.RegistrationHelper.InstallAssembly(String assembly, String& application, String partition, String& tlb, InstallationFlags installFlags)
at System.EnterpriseServices.RegistrationHelper.InstallAssembly(String assembly, String& application, String& tlb, InstallationFlags installFlags)
at System.EnterpriseServices.RegistrationHelper.System.EnterpriseServices.Thunk.IThunkInstallation.DefaultInstall(String asm)
at System.EnterpriseServices.Thunk.Proxy.RegisterAssembly(Assembly assembly)
at System.EnterpriseServices.Thunk.Proxy.LazyRegister(Guid id, Type serverType, Boolean checkCache)
at System.EnterpriseServices.Thunk.Proxy.CoCreateObject(Type serverType, Boolean bQuerySCInfo, Boolean& bIsAnotherProcess, String& uri)
at System.EnterpriseServices.ServicedComponentProxyAttribute.CreateInstance(Type serverType)
at System.Runtime.Remoting.Activation.ActivationServices.IsCurrentContextOK(Type serverType, Object[] props, Boolean bNewObj)
at newuser.btnSubmit_Click(Object sender, EventArgs e) in E:\Tariq\Project1\Trinity\newuser.aspx.vb:line 29
at System.Web.UI.WebControls.Button.OnClick(EventArgs e)
at System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument)
at System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument)
at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)
at System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData)
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
Tariq Mahmood
Software Engineer
|
|
|
|
|
How can I add elements in to a .Net Drop down list server control using Javascript function. Like I have 3 dropdown list server controls. I want change the date field whenever month or year changed. If possible please give some code snippet.
S/W Engineer
Akebono Soft Technologies
aleem_abdul@akebonosoft.com.
|
|
|
|
|
You probably want to do this with a postback, or use AJAX/Atlas
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Post back is the only problem for me I dont want to use it. I want to display a Date field with three combo boxes. When month and year are selected, automatically the days combo must me filled with those many number of days according to leap or not and then 31 or 30 like that. So please help me if any body could do it.
Thank you.
S/W Engineer
Akebono Soft Technologies
aleem_abdul@akebonosoft.com.
|
|
|
|
|
How can I add elements in to a Drop down list server control using Javascript function. Like I have 3 dropdown list server controls. I want change the date field whenever month or year changed. If possible please give some code snippet.
S/W Engineer
Akebono Soft Technologies
aleem_abdul@akebonosoft.com.
|
|
|
|
|
The problem is, when you add items using javascript, they won't be in the viewstate, and so won't appear in your server side code, at least, not as a result of a postback.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
I tried to connect in this way the javascript function to "OnSelectedIndexChanged" event hanlder. But Its not giving me any
thing. Means its not adding this "Javascript" function to the event. What may be the problem. If you can please help me by
giving some code snippet too please.
ddlMonRes.Attributes.Add("OnSelectedIndexChanged", "GetDayOfMonth1();")
S/W Engineer
Akebono Soft Technologies
aleem_abdul@akebonosoft.com.
|
|
|
|
|
I have created a crystal report web project. When my report was static the print/Export buttons were working fine. I exported report to pedf. But I changed the report as dynamic. Now the export and print buttons on the Crystal Report toolbar are not working. How can I print or export from the toolbar buttons? Please help me.
Arghya Mahapatra
|
|
|
|
|
1. I want to access a Server control in .net within a Javascript function. I used this method.
alert(alter(document.getElementById('tbCmpName').id); still its not working.
Can any body help me in accessing server side control from client side scripting?
2. How can I declare string variables in Javascript?
3. And one more question, how can I get the length of a string?
Please reply me for these queries.
S/W Engineer
Akebono Soft Technologies
aleem_abdul@akebonosoft.com.
|
|
|
|
|
indian143 wrote: I want to access a Server control in .net within a Javascript function
Your aspx needs to get the ID from the server code. Like this:
document.getElementById('<%=tbCmpName.ClientID%>')
indian143 wrote: How can I declare string variables in Javascript?
var str = "this is a string";
indian143 wrote: And one more question, how can I get the length of a string?
str.length, I believe.
Google will find you tons of javascript tutorials.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Can anyone point out the error of my ways?
I was under the impression that IE7 implemented the native XMLHTTPRequest object but this code is not working in IE7.
The code works in IE6 (using the ActiveX object) and other browsers that implement the native XMLHTTPRequest object, but not in IE7.
<br />
var XMLHTTPREQUEST_MS_PROGIDS = new Array(<br />
"Msxml2.XMLHTTP.7.0",<br />
"Msxml2.XMLHTTP.6.0",<br />
"Msxml2.XMLHTTP.5.0",<br />
"Msxml2.XMLHTTP.4.0",<br />
"MSXML2.XMLHTTP.3.0",<br />
"MSXML2.XMLHTTP",<br />
"Microsoft.XMLHTTP"<br />
);<br />
<br />
var HTTPREQUEST_UNINITIALIZED = 0;<br />
var HTTPREQUEST_LOADING = 1;<br />
var HTTPREQUEST_LOADED = 2;<br />
var HTTPREQUEST_INTERACTIVE = 3;<br />
var HTTPREQUEST_COMPLETED = 4;<br />
var HTTPREQUEST_SUCCESS = 200;<br />
<br />
function getXMLHttpRequest(){<br />
var httpRequest = null;<br />
<br />
if (window.XMLHttpRequest)<br />
httpRequest = new window.XMLHttpRequest();<br />
else if (window.ActiveXObject){<br />
var success = false;<br />
for(var i = 0; i < XMLHTTPREQUEST_MS_PROGIDS.length; i++){<br />
try{<br />
httpRequest = new ActiveXObject(XMLHTTPREQUEST_MS_PROGIDS[i]);<br />
success = true;<br />
}
catch(e){}<br />
}
}
<br />
if (httpRequest == null)<br />
alert("Error in HttpRequest():\n\n"<br />
+ "Cannot create an XMLHttpRequest object.");<br />
<br />
return httpRequest;<br />
}
I'm on-line therefore I am.
JimmyRopes
|
|
|
|
|
if someone can help please
i want the java script which enable me to make preloader if someone can help please urgent
thanks in advance
|
|
|
|
|
What do you need to preload?
Brad
Australian
-CAUTION-
The previous statement may contain traces of PHP, and by reading this statement you negate the right to vote me down.
|
|
|
|
|
What is the best way to produce and print simple reports from an ASP.NET application? I have an application hosted on a public web site (public hosting company), and would like to print simple reports without using such things as Crystal Reports since I have no access to the web server machine.
You could point me to any useful source for printing reports via an ASP.NET application.
|
|
|
|
|
Have you considered asking in the ASP.net forum?
Brad
Australian
"Keyboard? Ha! I throw magnets over the RAM chips!" - peterchen
|
|
|
|
|
OH and also if you can view the reports in the browser then use the javascript command "window.print" or just ctrl+P
Brad
Australian
"Keyboard? Ha! I throw magnets over the RAM chips!" - peterchen
|
|
|
|
|
Hopefully somebody here could explain how these work.
From what I understand, to give a website an icon, a resource with the name of favicon.ico should be placed in the root directory.
I'm creating a C++ utility which interacts with the users internet cache, so please forgive my ignorance I know very little about web development.
From my utility, I have listed all the favicons stored in the internet cache. I should point out these are favicons ONLY and not normal images displayed on a page with the same name. For one favicon in particular, the url returned is not what I expected (being in the root directory), though the icon is the same.
"http://www.mininova.org/images/favicon.ico"
I just want somebody to confirm that what I am seeing is not an error. Also, does the favicon HAVE to be in the .ico format? ie can .png .jpg and the like be used? If so, would you happen to know of any websites that use them? ( for code testing purposes )
Thanks in advance.
|
|
|
|
|
Hey mate,
Working on the project I see.
You can attach a FavIco through a link tag.
here is an example below:
<html>
<head>
<link rel="SHORTCUT ICON" href="/images/icon.ico">
</head>
<body
This page has an icon!
</body>
</html>
I will email you on how I think we should implement this.
Also only .ico files can be favicons.
Talk to you soon.
Brad
Australian
"Keyboard? Ha! I throw magnets over the RAM chips!" - peterchen
|
|
|
|
|
Hey man,
Bradml wrote: Working on the project I see.
You guessed right :p I have completely reversed the index.dat files where the interent cache is stored. I can now retrieve and manipulate all of the data without being imposed with IE's security restrictions.
|
|
|
|
|
Hi
In Internet Explorer i have a problems, but in firefox only rename your icon file to favicon.ico and move your icon file to root folder.
Cuando salga el sol, no estare aqui...
|
|
|
|
|
I'm sorry, I don't follow...
Brad
Australian
-CAUTION-
The previous statement may contain traces of PHP, and by reading this statement you negate the right to vote me down.
|
|
|
|
|
Hi All
i am facing one small but strange issue. I hope you guys can help me in correct direction.
I am storing user login/password information via using cookies. It worked fine firefox but in IE7 it is not working. Code is very simple.
a) I am using httpcookie.
b) Dim LoginCookie As New HttpCookie("LoginName")
c) LoginCookie.Value = Me.TxtLoginName.Text
Response.Cookies.Add(LoginCookie)
d) On Page load
Me.TxtLoginName.Text = Request.Cookies("Login")
Before you say i change the setting in IE7 -->privacy tab->advance->override
accept first party/third party and as well as accept session cookies.........
But still same code works in firefox but not in IE7....
Pl help.
Amit
Amit
|
|
|
|