Beiträge von Brandon

    Zitat von wpsupport

    Spellcheck starts from the cursor position - so in all cases except the case that it starts from the beginning the question makes sense.



    I apologize, but your response does not make any sense. Why would it display this message if I was starting the spellcheck from the beginning?

    I am running the spellcheck from the toolbar. Clicking the button runs the following code:
    memo.TextCursor.GotoStart
    memo.TextCommand 7, 0, 0

    However, if I remove the GotoStart command, it still produces the same pop-up box (with Retry Cancel). How can I get this pop up box to appear correctly?

    Zitat von wpsupport


    This is pretty difficult to debug, I am sorry. I am working on an update to do it.

    I found a work around. I took all of my custom words and then added them to a custom user dictionary. I then set the installer to load the dictionary using CommandEx 9500 8 <user dictionary path>.

    I am not 100%, but it is possible that this problem was caused by words with trailing spaces. I don't see any spaces in my source word list, but spaces may have been introduced by the compiler.

    New Issue: When I run spellcheck and there are no misspelled words, a dialog box pops that says:

    SpellCheck Complete
    Retry Cancel

    This should be an OK button, not the Retry & Cancel buttons. How can I fix this?

    Zitat von Brandon

    What am I missing?


    I figured out what I was missing. I had to add replace wpa="" with action="" and then it worked great.

    So they should like:
    <Button image="30" action="DiaSaveTemplate" name="DiaSaveTemplate" hint="Save the letter template (CTRL+S)"/>
    <Button image="37" action="DiaSaveLetter" name="DiaSaveLetter" hint="Export merged letter to MS Word"/>
    Please clarify this in the manual. I had to piece this together myself. The manual just says:

    Action=text Set any name of a custom action. The name can be retrieved using the property Action.

    I would also mention that a custom wpa can be retrieved with the wpaGetID and set with wpaSetFlags.

    I found in the manual that you need to create a custom wpa in order interact with a custom toolbar button. I think I have done everything correctly, but it is not disabling them.

    Here are my custom actions:

    <wpa>
    <action name="DiaSaveTemplate" c="Save Template" h="Save the letter template (CTRL+S)"/>
    <action name="DiaSaveLetter" c="Export Template" h="Export merged letter to MS Word"/>
    </wpa>

    Here is my toolbar entry:
    <Button image="30" wpa="DiaSaveTemplate" name="DiaSaveTemplate" hint="Save the letter template (CTRL+S)"/>
    <Button image="37" wpa="DiaSaveLetter" name="DiaSaveLetter" hint="Export merged letter to MS Word"/>

    I have a button (wpa="diaPrint") that is disabling and enabling properly, so I know it is working overall.

    I have confirmed that the wpaGetID is getting an ID (255 and 256 respectively.) I have also confirmed that the system can read both the wpa and the name because I did a wpaGetID(thebuttons.Name)

    Here is my actual OnUpdateGui code:
    Dim wpaButton As Integer
    Set memo = WPDLLInt1.memo
    Select Case Me.MergeTab
    Case 0 'Template
    wpaButton = WPDLLInt1.wpaGetID("DiaSaveTemplate")
    WPDLLInt1.wpaSetFlags Editor, wpaButton, 1, "A"
    wpaButton = WPDLLInt1.wpaGetID("DiaSaveLetter")
    WPDLLInt1.wpaSetFlags Editor, wpaButton, 1, "@"
    wpaButton = WPDLLInt1.wpaGetID("DiaPrint")
    WPDLLInt1.wpaSetFlags Editor, wpaButton, 1, "@"

    ****
    I know it works because the "DiaPrint" button is working just fine.

    What am I missing?

    Thanks. This is most of what I needed. I recommend updating the documentation to also include the following:

    "A" - Action is visible and enabled
    "@" - Action is disabled
    "E" - Action is hidden

    New Issue: Is there is any way to hide a button based on its name (rather than it wpa?) I have a button that is listed in the Image Manager as:

    <Button image="37" name="DiaSaveLetter" hint="Save the Letter"/>

    I can get a button that uses a wpa (i.e. wpa="diaPrint") to work, but not one that doesn't use a wpa.

    Is there a way around this?

    The compiled spell checker is not finding all of the words that I have included in the dictionary. It seems to be inconsistent as to which words that it has problems with. To illustrate this you can use the following files with your own spellchecker.

    <Files removed>

    For example, when I do a spell check it will tell me that the following words are misspelled: OrgName, SalutationFirst, ItemBlockPaid, and ItemTotalPaid.

    When I ran the compiler I used the following options:
    I unclicked all of the Option boxes
    custom flags = 0
    maxlength of words: 50
    Language ID: 9
    Name: <left blank>
    CodePage: 1252 (default)

    Julian: Can you help me to fix this problem?

    I have scoured the manual and I am unable to figure out how to programmatically switch a toolbar button from being enabled to disabled. For example, I could disable the Save button until they have loaded a template and then I would enable the button.

    If it is not possible to activate or de-activate specific buttons, then I would need to use multiple toolbars. I tried to figure out how to use the WPCubed ImagePack Manager to include a different toolbar for Editor 1 and Editor 2, but the instructions for this are not clear and I gave up.

    Any advice or direction you can provide would be greatly appreciated.