Re: error on bookmark

From: Doug Robbins - Word MVP - DELETE UPPERCASE CHARACTERS FROM EMAIL ADDRESS (dkr_at_mOSTvALUABLEpROFESSIONALs.org)
Date: 03/07/04


Date: Sun, 7 Mar 2004 21:14:11 +1000

When the error occurs, what message is displayed? What line of code is
highlighted if you click on Debug?

-- 
Please post any further questions or followup to the newsgroups for the 
benefit of others who may be interested.  Unsolicited questions forwarded 
directly to me will only be answered on a paid consulting basis.
Hope this helps
Doug Robbins - Word MVP
"phil" <pwbga@bigpond.com> wrote in message 
news:uext9LDBEHA.1548@TK2MSFTNGP12.phx.gbl...
> if you have a problem with other people within this user group please deal
> with it directly with them instead of using a third party. I am trying to
> complete a userfrom for a group which I'm not getting paid for and 
> stringing
> me out has delayed the work I wish to get done over this weekend so if
> anyone can help me solve this coding problem it would be much appreciated
>
> thank phil
>
> "Word Heretic" <myfullname@tpg.com.au> wrote in message
> news:dmvl4091u1j82deee5uscmspoj5pqumdv6@4ax.com...
>> G'day "phil" <pwbga@bigpond.com>,
>>
>> I think I just changed my mind about that free help here.
>>
>>
>> Steve Hudson - Word Heretic
>> Want a hyperlinked index? S/W R&D? See WordHeretic.com
>>
>> steve from wordheretic.com (Email replies require payment)
>>
>>
>> phil reckoned:
>>
>> >is anyone going to give me an answer to my problem or are the egos in
> this
>> >usergroup getting to big for this usergroup to function properly
>> >
>> >
>> >"Word Heretic" <myfullname@tpg.com.au> wrote in message
>> >news:q08j40ph6m9g4qfm97aoc62cpcsjmoijrp@4ax.com...
>> >> G'day Peter Hewett <Nospam@xtra.co.nz>,
>> >>
>> >> Oh yeah - the MVPs also claim to have not seen many of the posts I
>> >> reply to, so I am really just tryimg to help them see all and collect
>> >> their brownie-nosed points.
>> >>
>> >> Steve Hudson - Word Heretic
>> >> Want a hyperlinked index? S/W R&D? See WordHeretic.com
>> >>
>> >> steve from wordheretic.com (Email replies require payment)
>> >>
>> >>
>> >> Peter Hewett reckoned:
>> >>
>> >> >
>> >> >I don't think it's an ability/capability issue, more one of tolerance
> and
>> >> >patience (or the lack of it)! If the OP can't be bothered to read
> what's
>> >> >posted, assist in debugging their own code or remotely appreciative 
>> >> >of
>> >> >assistance provided, the well dries up!
>> >> >
>> >> >
>> >> >Word Heretic <myfullname@tpg.com.au> wrote in
>> >> >news:h1oi40dep74958jbv5nkh9va0mh6432jib@4ax.com:
>> >> >
>> >> >> G'day "phil" <pwbga@bigpond.com>,
>> >> >>
>> >> >> Bounced to the almost useless MVPs. I have an answer, just want 
>> >> >> them
>> >> >> to show THEY aren't capable of it.
>> >> >>
>> >> >>
>> >> >> Steve Hudson - Word Heretic
>> >> >> Want a hyperlinked index? S/W R&D? See WordHeretic.com
>> >> >>
>> >> >> steve from wordheretic.com (Email replies require payment)
>> >> >>
>> >> >>
>> >> >> phil reckoned:
>> >> >>
>> >> >>>i have a bookmark problem via a checkbox  autotext is inserted into
> the
>> >> >>>document this auto text also contains bookmarks my problem occurs
> when
>> >> >>>unchecking the textbox to remove the autotext  an error occurs i
> think
>> >> >this
>> >> >>>is because the code is trying to update a bookmark that is not in
> the
>> >> >>>document anymore this is the code im using any help will be much
>> >> >appricated
>> >> >>>
>> >> >>>thank phil
>> >> >>>
>> >> >>>Private Sub CommandButton2_Click()
>> >> >>>ActiveDocument.Unprotect Password:=""
>> >> >>> If chkPRE_surveyor_certificate.Value Then
>> >> >>>        InsertAutoText "surveyors certificate", 
>> >> >>> "bmautopre_surveyor"
>> >> >>>    Else
>> >> >>>        UpdateBMText "bmautopre_surveyor", ""
>> >> >>>    End If
>> >> >>>
>> >> >>>With ActiveDocument
>> >> >>>    UpdateBMText "bmpre_footing_referance",
>> >tbpre_footing_referance.Value
>> >> >>>End With
>> >> >>>  ActiveDocument.Protect Password:="", NoReset:=True, Type:= _
>> >> >>>        wdAllowOnlyFormFields
>> >> >>>UserForm2.Hide
>> >> >>>
>> >> >>>End Sub
>> >> >>>
>> >> >>>Private Sub InsertAutoText(ByVal strAutoTextName As String, _
>> >> >>>                           ByVal strBookmarkName As String)
>> >> >>>    Dim tplAttached As Word.Template
>> >> >>>    Dim rngLocation As Word.Range
>> >> >>>
>> >> >>>    '
>> >> >>>    Set tplAttached = ActiveDocument.AttachedTemplate
>> >> >>>    Set rngLocation =
> ActiveDocument.Bookmarks(strBookmarkName).Range
>> >> >>>    Set rngLocation = tplAttached.AutoTextEntries(strAutoTextName) 
>> >> >>> _
>> >> >>>      .Insert(rngLocation, True)
>> >> >>>    ActiveDocument.Bookmarks.Add strBookmarkName, rngLocation
>> >> >>>End Sub
>> >> >>>
>> >> >>>Public Sub UpdateBMText(ByVal strBMName As String, _
>> >> >>>                        ByVal strBMValue As String)
>> >> >>>    Dim rngBM As Word.Range
>> >> >>>
>> >> >>>    Set rngBM = ActiveDocument.Bookmarks(strBMName).Range
>> >> >>>    rngBM.Text = strBMValue
>> >> >>>    ActiveDocument.Bookmarks.Add strBMName, rngBM
>> >> >>>End Sub
>> >> >>>
>> >> >>
>> >> >>
>> >>
>> >
>>
>
> 

Loading