Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Programming / July 2005

Tip: Looking for answers? Try searching our database.

compile error - named arguement already specified - Selection.EndK

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
turneg02 - 29 Jul 2005 00:39 GMT
I keep getting this error and i dont know why. It comes from this line of
code and its because of be when i change the unit to wdstory (previously i
left it out)

ps i want it to select everything within a cell , will wdstory do this?

Selection.EndKey , unit:=wdStory, Extend:=wdExtend

'code which is causing problem

If Selection.Find.Found = True Then
 
   Selection.Move unit:=wdCell, Count:=12
   Selection.EndKey unit:=wdColumn, Extend:=wdExtend
   Selection.MoveRight unit:=wdCharacter, Count:=1, Extend:=wdExtend
   '
   Selection.Copy
   Selection.Move unit:=wdCell, Count:=-13
   Selection.Paste
   
   Selection.EndKey unit:=wdColumn
 
   

   Selection.HomeKey
   'Selection.ClearFormatting
   Selection.EndKey , unit:=wdStory, Extend:=wdExtend ' error line
Jezebel - 29 Jul 2005 00:47 GMT
Try removing the supefluous comma:

>    Selection.EndKey , unit:=wdStory, Extend:=wdExtend ' error line

>    Selection.EndKey unit:=wdStory, Extend:=wdExtend ' error line

>I keep getting this error and i dont know why. It comes from this line of
> code and its because of be when i change the unit to wdstory (previously i
[quoted text clipped - 21 lines]
>    'Selection.ClearFormatting
>    Selection.EndKey , unit:=wdStory, Extend:=wdExtend ' error line

Rate this thread:






 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.