Jump to content

(solved) List box item not highlighting


Recommended Posts

Hello autoit scripters.  So this problem has caused me no small amount of frustration.  I have a fairly large script that I am trying to finish up, here is the gist.  I am trying to include a spellchecking into the script, and I have success in the past using @big_daddy's Spell Checking Example in the past to check text for spelling errors using a Microsoft Word Com Object, and I have modified it somewhat so that it utilizes the method that @ProgAndy uses in his Multi-line input box udf to create and destroy a Gui Within a single function and return the text obtained by using the GUI in the function.  However, this is where I am running into issues.  I was able to successfully create and use @ProgAndy's Multi-line UDF within my script, but when I try to apply the logic to a different GUI I created, the form behaves strangely.  The problem can be replicated by selecting the "Add/edit" menu item, expanding company, and selecting whole entry (this is just one way to access the spell checking feature that is not working).  When message box pops up to ask for the company name, spell something incorrectly and let the spell checker catch it.  Then, the function "SpellGUI" (at very bottom of script) will execute and bring up the GUI.  But when you try to select the word which is misspelled, it will no highlight, nor will any entries appear in the other list which is supposed to have the spelling corrections for selection highlighted in the first list.  Strangely enough, the spelling suggestions do appear if I click anywhere in the first list that is not where the misspelled word is, and the word only sometimes highlights.  If you could help me figure out what is wrong, I would be very appreciative.

**EDIT: Ok.  This is even stranger.  When I simply "Run" the project from Scite, the list works correctly and the items highlight as they should.  So the question becomes why is the uncompiled script working and the compiled one isn't?

**Edit Again: Ok.  So it worked once.  One time it worked like it should then it started exhibiting same behaviors described in original post.  Still need help......

 

Edited by MattHiggs
Link to comment
Share on other sites

Hello. I think the issue is the height of the $Label10 "Misspelled word". It is too big. So you click the label instead the listbox. Reduce the label height.

 

Saludos

Link to comment
Share on other sites

1 minute ago, Danyfirex said:

Hello. I think the issue is the height of the $Label10 "Misspelled word". It is too big. So you click the label instead the listbox. Reduce the label height.

 

Saludos

Hey danny.  Thank for the input.  I will give it a shot.  It should also be noted, however, that I found that the list box item does highlight when you click it at the farthest left hand point.  But that might be an area where the label is not covering the list box.  I will give it a shot.

Link to comment
Share on other sites

I changed height of $Label10 and $Label11 to 29. And I was able to get highlighted items in both listbox.

 

Saludos

Link to comment
Share on other sites

6 minutes ago, Danyfirex said:

Hello. I think the issue is the height of the $Label10 "Misspelled word". It is too big. So you click the label instead the listbox. Reduce the label height.

 

Saludos

You were absolutely correct.  Problem solved.  Thank you sir!

Link to comment
Share on other sites

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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...