Jump to content

Recommended Posts

Posted

Hi,

 

I've just installed HAP v10.1 and I've come across an issue which I need some help with; when a user tries logon with their UPN, and they get a Server Error in Application error: Index was out of range. Must be non-negative and less than the size of the collection. Parameter name: index

 

Logging on with the users Pre2000 account name works fine.

 

Many thanks, Dan.

  • 3 months later...
Posted
HAP+ only supports logging on with a username/password, not an email address or UPN

 

Hi Nick

sorry to bump this, but I am getting the same error when the wrong username is typed. (stupid staff)

 

Any way to get it to redirected to login with message similarly to when password is wrong?

Posted

Try this, edit ~/login.aspx

 

Find and insert

            $('input[type=text],input[type=password]').keyup(function (e) {
               if (e.keyCode == 13) {
                   $("#<%=username.ClientID%>").val($.trim($("#<%=username.ClientID%>").val()));
                   location.href = $("#<%=login.ClientID %>").attr("href");
               } [b]else if (e.keyCode == 220 || e.keyCode == 222) /*back slash*/ {
                   alert("Please enter just your username");
               }[/b]
                   
           });

Posted

Same error im afraid

 

Source Error: 

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace: 


[ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index]
  System.Collections.ArrayList.get_Item(Int32 index) +14310269
  System.DirectoryServices.SearchResultCollection.get_Item(Int32 index) +28
  HAP.AD.User.UserAccountControl(String username) +146
  HAP.Web.Login.login_Click(Object sender, EventArgs e) +1009
  System.Web.UI.WebControls.LinkButton.RaisePostBackEvent(String eventArgument) +153
  System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3804

  • 2 weeks later...
Posted

This code on the login page works

 

            $('input[type=text],input[type=password]').keyup(function (e) {
               if (e.keyCode == 13) {
                   $("#<%=username.ClientID%>").val($.trim($("#<%=username.ClientID%>").val()));
                   location.href = $("#<%=login.ClientID %>").attr("href");
               } else if (e.keyCode == 220 || e.keyCode == 222) {
                   alert("Please enter just your username");
                   $(this).val($(this).val().substr(0, $(this).val().length - 1));
               }
           });

 

I just tested it, as soon as I typed \ or @ I get the warning and it removes the @ or \ sign

  • 5 years later...
Posted

i know this is an old thread and unlikely to get a reply, but on the off chance.

 

Ive used the above code to block out backslash and AT symbol (also had to add quotes too depending on the keyboard type), however this key alert affects the password field as well and some people have those three chars in there password.

 

Ive taken out the input[type=password] bit and now it only affects the username field however the effect that it has had is removed the ability to press enter on the password field.

 

Any help would be appreciated and I appreciate the system is not being developed anymore. Thank Steve

Posted
           $('input[type=text]').keyup(function (e) {
               if (e.keyCode == 13) {
                   $("#<%=username.ClientID%>").val($.trim($("#<%=username.ClientID%>").val()));
                   location.href = $("#<%=login.ClientID %>").attr("href");
               } else if (e.keyCode == 220 || e.keyCode == 222) {
                   alert("Please enter just your username");
                   $(this).val($(this).val().substr(0, $(this).val().length - 1));
               }
           });
           $('input[type=password]').keyup(function (e) {
               if (e.keyCode == 13) {
                   $("#<%=username.ClientID%>").val($.trim($("#<%=username.ClientID%>").val()));
                   location.href = $("#<%=login.ClientID %>").attr("href");
               }
           });

  • 2 weeks later...
Posted

Thanks Nick, I was almost close with me trying to figure it out myself.

 

Also (sorry), any ideas why the 'Delete' option is missing in MyFiles, it works as me (im an administrator) so it must be permissions based, but i've gone through everything and cant figure it out (even briefly given the HAP files folder everyone rw). It was there but disappeared during some of my configuring.

 

Any suggestions would be greatly appreciated.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...