Why my code(CS2 VB Script) only pastes what on the clipboard, not everything I select?

I have created a graph, now I want to copy the entire thing to a new document.  I used the following code.  Even visually you can see it selected everything in the document, but when it pasted to a new document, it only pasted what's left on the clipboard, not everything as I wanted. 
What's wrong here? Does it have anything to do with grouping?  See code below.
Please help!  Thanks.
    Dim oCurDoc As Illustrator.Document
    Set oCurDoc = oApp.ActiveDocument
    Dim iPageItemCount As Integer
    iPageItemCount = oCurDoc.PageItems.Count - 1
    Dim vItems() As Variant
    ReDim vItems(iPageItemCount)
    Dim oPageItem As Object
    For Each oPageItem In oCurDoc.PageItems
        Set vItems(iCnt) = oPageItem
        iCnt = iCnt + 1
    Next   
    oCurDoc.Selection = vItems
    Dim oNewDoc As Illustrator.Document
    If oApp.Documents.Count > 0 Then
        If TypeName(oCurDoc.Selection) = "Variant()" Then
            oCurDoc.Copy
            Set oNewDoc = oApp.Documents.Add(aiDocumentRGBColor)
            oNewDoc.Paste
        End If
    End If

Yes, I tried to group them first by
    Dim oGrp As GroupItem
    For Each oPageItem In oCurDoc.PageItems
        Set oGrp = oCurDoc.GroupItems.Add
        Set oPageItem = oGrp.PageItems.Add
        iCnt = iCnt + 1
        If iCnt > iPageItemCount  Then Exit For
    Next
     oCurDoc.Selection = oGrp
But the selection is always "empty" - nothing been selected.  Why?
Thanks.

Similar Messages

  • Why do some of my apps only work ón my iphone and not ón my iPad ?

    Why do some of my apps only work ón my iphone and not ón my iPad ?

    That should work on the iPad. Basic app troubleshooting from Apples support site. Items 1, 2 & 3 should not apply to your situation, but I posted the link at the end if you want to read them.
    4. Restart the application
    If the issue affects only a single app, try closing just that app:
    Press the Home button to return to the Home screen.
    Double-tap the Home button to display recent apps.
    Tap and hold the affected app until the red minus appears.
    Tap the red minus to quit the app.
    Press the Home button, then restart the app.
    5. Restart your device
    Hold the Sleep/Wake button until "slide to power off" appears. Slide to power off your device. When it is off, press the Sleep/Wake button to turn it back on.
    6. Reinstall the affected application
    Remove the application from your device and reinstall it.
    Touch and hold any application icon on the Home Screen until the icons start to wiggle.
    Tap the "x" in the corner of the application you want to delete.
    Tap Delete to remove the application and all of its data from your device.
    Press the Home button.
    Go to the App Store.
    Search for the application and then download it again.
    Note: If it is a paid app, ensure you are using the iTunes account you purchased the app with originally. If it is not, you will be charged for the app again. For more information regarding downloading previously purchased items, see this article.
    7. If the issue is still unresolved
    If you continue to experience the issue, contact the developer of the application for further assistance.
    http://support.apple.com/kb/TS1702

  • Very slow pasting data from the Clipboard into a Sharepoint 365 list by using the Quick Edit view

    <p>In sharepoint 2010 it was very fast to paste data from the Clipboard by using the Data Sheet view. Why is it so slow in Sharepoint 365 when using the Quick Edit View? is there a workaround?</p><p>also in Sharepoint 365 if you try to
    paste a large number of records (2,000) it will freeze.</p>

    I'm interest about same thing. Clipboard is often only way to migrate lists between sharepoint versions and now it is almost unpossible to use.

  • Why do we need downcasting in Java? What is the use of it?

    Why do we need downcasting in Java? What is the use of it?

    here's an example of a valid downcast.
    class Dog {}
    class Dogma extends Dog {}
    class Dogmatic extends Dog {}
    Dog dogwood = new Dogma(); // a Dogma object is upcast to a Dog
    Dogma bush = (Dogma) dogwood; // a Dogma object is downcast from a Dog
    You cannot upcast a Dogmatic to a Dog and then downcast it to a Dogma. You also cannot downcast a Dog to a Dogma. In the working example, above, the dogwood references a Dogma, so you can downcast the Dogma.
    and one more example
    If you have a class hierarchy where class B extends class A (B is a specialization of A) you can use B in the place of A since B supports all the operations that B does. This is called polymorphism.
    When you use an object of type B in place of A you actually do a up-cast, meaning you make the object of type B look like an object of type A (a less specific class type).
    What you are asking about is down-casting which is making an object be of a more specific type, i.e. transforming an object of type A to type B. Is is only allowed if the object was actually created as a type B.
    This is allowed (line 2 is a down-cast):
    A a = new B();
    B b = (B)a;

  • Why view have no stored data ?  And what is the reason view take more time

    Why view have no stored data ? And what is the reason view take more time to query ?
    what happen if a view have stored data?

    user12941450 wrote:
    I want to know the reason that why querying view is slower then querying a normal table?..Untrue.
    For example take a table with 2laks record and a view for that table.
    If i make a query like( Select name,address from table) then it works fast then select(name,address)from view..Incorrectly interpreting the results.
    A view is a SQL statement. Only difference is that the SQL statement is stored in the database's dictionary. Let's consider the following view:
    create or replace view foo_view as select * from empWhen you use the view as follows:
    select * from foo_viewOracle sees it as follows:
    select * from (select * from emp)This is no slower, or no faster, than providing the following SQL to Oracle:
    select * from empSo if you observe a difference in performance between using plain SQL versus using that same SQL via a view, there are other reasons for that difference in performance. The reason is NOT that views are slower.

  • HT5306 I do not want to give remote access to anyone but myself as privacy is my friend.  Can this remote desktop software still be for me personally unless I allow access and for my MAC lap top only?  What if I do not update? compatibility issues with wh

    Hello:
    Thank you for the update for remote access for desktops.
    Personally, I do not want to give remote access to anyone but myself as privacy is my friend.  Can this remote desktop software still be for me personally unless I allow access and for my MAC lap top only?  What if I do not update? I do use this lap top in other countries.  compatibility issues with what?

    Apple Remote Desktop is off be default. It has to be enabled for some one to be able to remotely connect to the computer. And then, you still have to have a user name and password on the computer to remotely connect with.
    If you want to see if remote access has is enabled for Apple Remote Desktop; you can find the setting in, Apple Menu, System Prefrences, Sharing. If it's enabled, Remote Management or Screen Sharing will be checked.
    Beucase Apple Remote Desktop Agent is part of the Mac Operating System; even if your not using it, Apple Software Updates will from time to time offer updates for ARD Agent. Software Updates can some times be stacked ontop of each other; so chosing not to install an update, can mean other updates you may want may not be offered. At least until you install the updates those updates require. Also software updates can improve the security of your computer.

  • The "small ball" on the mouse allows me only to scroll to the top not to the bottom

    The "small ball" on the mouse allows me only to scroll to the top not to the bottom

    Crud builds up under the ball and prevents the rollers from operating properly.
    Turn it upside down and rub the ball vigorously with a microfiber cloth.
    Regards,
    Captfred

  • What does Factory Unlocked International Version GSM Only? what's the difference from other iphon5 specs? pls explain

    What does Factory Unlocked International Version GSM Only? what's the difference from other iphon5 specs? pls explain

    Only GSM/LTE iPhones can be purchased unlocked. CDMA iPhones are always locked to their specific carrier for CDMA use, though some may either have the GSM portion unlocked or will unlock upon request assuming any necessary requirements are met.
    Regards.

  • We have bought an Apple TV, and have downloaded the sky sports app. We are trying to watch this via airplay, but we are only managing to get the sound, not the picture. Any ideas??

    We have bought an Apple TV, and have downloaded the sky sports app. We are trying to watch this via airplay, but we are only managing to get the sound, not the picture. Any ideas??

    Sky do not allow the app to work with Airplay.You will only get sound.

  • Why does my Safari Auto-Fill only work part of the time?

    First of all, why isn't there a link on the Apple website to provide Feedback?  Secondly, I'd love to know why my Safari Auto-Fill only works some of the time, like when entering Sweepstakes information.  I realize some websites don't allow Auto-Fill, but on the ones that do, I can't get the second window to open up when I click "Auto-Fill".

    Safari 6.1.1 and yes all web forms are checked under Preferences Auto-Fill.  I am daily entering sweepstakes for the HGTV dream home, and even though the initial bubble shows up "Auto-Fill your contact information" shows up, when I click on it, the second bubble that lets you confirm the info doesn't always open.  I tried it just now in a separate tab, and it opened; then I came back here to write some of the message.  Then I went back to try again and it won't open.  It drives me crazy.  I keep trying with each new data field and sometimes the second bubble will open further down the page.

  • Why sign many contract, I'm only using what I am told to use.?

      Why have many signins for all the product needed for a computer? I only use what I purchase & the parts  used to operate my machine. It's a vehical of communication only to me. I really don't need to sign for every item for the vehical to operate propertly. You & I know it's like a car with many parts. Please make it simple rather than making me a machinist on a computer.
      For new parts, be like an autopart's store. All they need is my name, address, phone number, make & modle of what I have and the part from you I need to purchase, whether it's hardware or software. <Removed by Moderator> Thanks for your coming answer.

    1stAdobeContact which Adobe product or service are you referring too?  I have also removed your e-mail address from your previous post as this is a public forum.

  • Why did my ipod touch gen5 only hold under 4000 songs and not 10000, I had the proper settings @128

    why does my ipod touch 5gen only hold just under 4000 songs and not 10000, I had the proper settings @128?

    it is a 32gb unit

  • Pasting HTML to the clipboard to be used by Windows native apps

    I'm having problems creating a DataFlavor that will allow me to write a
    string to the clipboard in html format so that a windows native app (e.g.
    MS Word) can recognise this format and allow me the option of
    pasting as html rather than just plain text.
    I've found that if I alter my code to first get the contents off the
    clipboard (some html I copy from an Internet Explorer-viewed web page), I
    can extract the html DataFlavor from the Transferable object that IE has
    placed on the clipboard. If I then use this "stolen" DataFlavor to write my
    contents to the clipboard, I find that I can successfully paste as HTML in a
    windows native app.
    However, since I can't rely on grabbing some html from IE just to get a
    suitable DataFlavor each time I need to use my copy function, I have been
    attempting to construct my own DataFlavor to match the characteristics of
    the IE example flavour.
    The problem is that, having set the representation class, MIMEType and human
    presentable name to match the IE flavor, when I call DataFlavor.equals() to
    compare the two flavours it returns false, and my constructed flavour
    subsequently fails to show up as a paste option in any native apps. Having
    compared every possible property of both flavours, I've concluded that the
    only difference between the two is that the IE flavour has the charset
    parameter set as utf-8, whereas my constructed flavour has no charset
    parameter specified. I have found no way to manually set the charset. So
    calling getMimeType() on each flavour gives:
    IEDataFlavor.getMimeType() = text/html; class=java.io.InputStream; charset=utf-8
    MyOwnDataFlavor.getMimeType() = text/html; class=java.io.InputStream
    Using the Windows Clipboard viewer I have observed that my constructed
    DataFlavor does exist on the clipboard, however whereas the IE flavour's
    visible name is "HTML Format", mine is "JAVA_DATAFLAVOR: text/html;
    class=java.io.InputStream"
    and I think this is the reason that native windows apps are failing to
    recognise my DataFlavor as a valid option for display.
    I'm using jdk 1.3.1
    If anyone has ever encountered this problem or can think of a solution I'd
    be extremely grateful for your help.
    Thanks,
    Steve White

    I have a similar problem:
    IE actually put the "HTML Format"(CF_HMTL) flavor into the clipboard, with some additional info, such as SourceURL as the description.
    see
    http://msdn.microsoft.com/library/default.asp?url=/workshop/networking/clipboard/htmlclipboard.asp
    How will this information be available to Java clipboard?
    Main question, for HTML data pasted by IE into the clipboard, how to get the source url.
    I know some Windows native apps could get that info nicely.
    Thanks!

  • Torch will NOT charge with Wall or Car Chargers, only USB - what is the fix?

    About 3 days ago, my Torch decided it no longer wants to work with ANY wall charger, or car charger for that matter.  I have been using it just fine for the past 6 months, and charging it just about every night, topping it off for a fresh charge for the morning.
    Now, NO wall chargers work, simply no response.  The ONLY way I can charge is via the USB cable and my laptop.  This is VERY annoying and no one at the AT&T store seems to know what's going on.
    I've tried all kinds of battery pulls and reboots - even upgraded to the latest software, downgraded back - NOTHING seems to be working!
    What is the solution to this problem?  How can I get it to charge again in my wall and car chargers?

    If the device (Blackberry phone) will recharge using the computer this means that the port on the device should be functioning properly.  The USB port on your computer puts out up to 500 ma at 5 Volts. The voltage regulator in the phone adjusts the power coming in to be in specs to charge the battery. The Blackberry charger is a 700 ma charger. The computer will take about 30% longer to charge the phone.
    I have had the connectors on the chargers and car adabtors go defective from handling and use.  I have also had chargers fail. Since the phone can be recharged using the computer this tells me the fault has to be with the charging devices you have. Unfortunately these chargers are not serviceable. As for myself, over time I bought a number of spare chargers.
    I would strongly suggest to try another charger. Maybe you can go in to a store that sells them and try another charger that they have in stock.
    When buying or trying a charger, it would be best to get an original Blackberry charger. This guarantees the specifications will be exactly correct for your phone, and also for the electrical safety for your phone. It is also known that many of the universal chargers will not properly charge the Blackberry phone.
    Jerry G.
    Jerry G.

  • A script to identify pictures in the Finder not added to Aperture?

    Does anyone know of a script that can check out the contents of a folder containing a series of nested folders holding files that are being referenced in the Aperture Library and point out the files in that folder which have not been added to the Aperture Library?
    The majority of the files in that folder (thousands) are being actively referenced in my Aperture Library, but for whatever reason that I won't get into, a few hundred pictures that are in that folder somewhere have had their links to Aperture broken and it would be great if I could identify which files those were and hook them back up to Aperture.
    These are all pretty old pictures that I likely won't ever need to be touching ever again, so if the solution is going to be a massive re-doing of my Library, then it won't be worth it, but if it can be done relatively easily then, ya know…it'd be nice to have the Library be "perfect" and free from broken links

    Thanks for your reply.
    What you are suggesting is part of the process that I am using to reconnect these missing files.
    The part that I am needing help with is the "If you direct Aperture to the first of those missing masters" aspect.  There are so many pictures in my reference library location (all nester in folders, so I can't just use Coverflow to skim through them and find the missing file to reconnect) that it would be extremely time consuming for me identify the correct file.
    Even if I do a spotlight search for "DSC_00413" in that folder, I get back ~500 results.
    This is why I feel that the script option to consolidate all of those "unconnected to Aperture" files in one folder, where I can then use Coverflow to identify them would be most effective.
    EDIT: I manged to do it though, by using Aperture's "Relocate Masters" command to move all files linked to Aperture to another location, thus leaving all "unconnected" files in their current location

Maybe you are looking for

  • Ipod nano - cover flow sort order nano 5th gen

    hi community, i'm using different ipods (3rd gen, 4th gen, 5th gen, nano) and i love tagging my mp3s (artist, album, _but not_ album artist) the sorting in cover flow for my ipod (3rd, 4th gen, touch, _but not 5th gen_) is fine for me: first regular

  • Problems with Ipad mini

    I just got an Ipad on my imail wont connect saying there is a server problem. However, I can brows the internet on the same Ipad so this cannot be true...

  • Help! Trying to redirect a website currently hosted by 1

    Hi I created a website in iWeb for a friend of mine but I want his old webaddress(currently hosted by a company called 1&1 who's customer support is almost non existent) to redirect to the new iWeb created page.I've tried logging into the control pan

  • Splitted packages (KDEmod-like) for docs?

    Sorry for posting another thread about the "stripping-docs" issue. I built last week some KDEmod packages from svn to get rid of a bug in kate, and I encountered for the first time the splitted packages concept used in KDEmod. In your opinion, is it

  • How can I find a converter for wmv movies

    How can I find a converter for wmv movies. I tried some converters, but non was sufficiant enough!