Detach library using Jdapi

Hi,
I am using JDAPI to detach libraries from the forms(10g). I am using the following code to detach library. The system run successfully without error but the libraries were not detached and it is still attached in the forms.
private static void destroyLibrarys(FormModule formModule){
JdapiIterator formAttachedLibraries = formModule.getAttachedLibraries();
while (formAttachedLibraries.hasNext()){
AttachedLibrary formAttachedLibrary = (AttachedLibrary)formAttachedLibraries.next();
System.out.println("Library: " + formAttachedLibrary.getName());
formAttachedLibrary.destroy();
Has anyone faced such problem and resolved it? Please help me in this issue.
Regds,
Nandakumar

Hi Nandakumar,
i faced the same problem and got the following solution, not very pretty but working. First i count the libraries to instantiate a string array, then write the names of the libraries to the array. For each element in the array i refresh the iterator for the AttachedLibraries after destroying one library. I used this method to change the library names to lowercase and to replace some libraries in the migration process.
The String switchLibrary is of format oldPllName:newPllName, oldPllName:newPllName; you may ignore this.
* Get a list of all attached libraries
* Destroy the attached library and attach it again with new name
* @param fmb - FormModule we are working on
private void reAttachLibraries(FormModule fmb) {
writeLogln("");
writeLogln("Attach libraries");
String switchLibrary = getMigrationProperties().getProperty("migration.process.plsqllibrary.switch");
String[] switches = null;
String[] oldPll = null;
String[] newPll = null;
if (!isNullOrEmpty(switchLibrary)) {
switches = switchLibrary.split(",");
oldPll = new String[switches.length];
newPll = new String[switches.length];
for (int i = 0; i < switches.length; i++) {
String[] tmpArray = switches[i].split(":");
oldPll[i] = tmpArray[0].toLowerCase();
newPll[i] = tmpArray[1].toLowerCase();
JdapiIterator attLibItr = fmb.getAttachedLibraries();
int libCounter = 0;
while (attLibItr.hasNext()) {
AttachedLibrary lib = (AttachedLibrary)attLibItr.next();
libCounter++;
attLibItr = fmb.getAttachedLibraries();
String[] libNames = new String[libCounter];
libCounter = 0;
while (attLibItr.hasNext()) {
AttachedLibrary lib = (AttachedLibrary)attLibItr.next();
String attLibName = lib.getName().toLowerCase();
if (!isNullOrEmpty(switchLibrary)) {
for (int i = 0; i < oldPll.length; i++) {
if (attLibName.equals(oldPll[i])) {
attLibName = newPll[i];
writeLogln("Library "+oldPll[i]+" replaced with "+attLibName);
libNames[libCounter] = attLibName;
libCounter++;
for (int i = 0; i < libNames.length; i++) {
attLibItr = fmb.getAttachedLibraries();
AttachedLibrary lib = (AttachedLibrary)attLibItr.next();
lib.destroy();
for (int i = 0; i < libNames.length; i++) {
AttachedLibrary lib = new AttachedLibrary(fmb, libNames[i]);
writeLogln("Attached Library: "+libNames[i]);
regards Perry

Similar Messages

  • Library path problem using JDAPI

    HI,
    Under Windows XP, I am trying to attach library to forms using JDAPI. But the path also gets hardcoded in this case. When I move the forms to Linux and try to open the forms, it says library not found.
    Can anyone help me in this regard ?
    I would highly appreciate immediate help.
    Thanks & Regds,
    Nandakumar

    Its home directory does not contain files .profile,.bashrc,.bash_historySo feel free to create it manually.
    I have added LD_PATH_LIBRARY in file /etc/init.d/oracle-xe This not much well but all work. Of course it didn't help. Because you set it for root (again) and this setting is ignored because su command (in that script) uses oracle's enviroment settings.
    So create .bash_profile in /home/oracle (oracle's home) and set the enviroment in that file.

  • Using JDAPI to reattach PLL Library/Libraries

    Hi
    I am attempting to change the libraries attached to some forms, to convert the names to lowercase as part of a Unix deployment project.
    I am using the standard code posted on Metalink. The Forms were Designer-generated as Forms 4.5 originally and have been upgraded to Forms 9.0.4.0.19. I am using the JDK in the Developer Suite Oracle Home. The Forms are in a different directory to the Libraries, but all the directories are in the FORMS90_PATH set both in the Registry and as a cmd.exe environment variable.
    I have two problems:
    1) If I attempt to just list the libraries attached to the Form, with something like:
         FormModule fmd;
         fmd=FormModule.open(args[0]);
         System.out.println("Processing module " + fmd.getName() + "...");
         JdapiIterator all_libs = fmd.getAttachedLibraries();
         while (all_libs.hasNext())
              AttachedLibrary lib = (AttachedLibrary)all_libs.next();
              System.out.println("Attached Library = " + lib.getName());
         fmd.destroy();
    This returns:
         Processing module MODULE...
         Attached Library = OFG4TEL
         Attached Library = OFG4MES
         Attached Library = OFG4BSL
         Attached Library = OFGMES
    Unfortunately, I know that there are more libraries than this. The Form is attached to a single module library (called MODULE.pll), which is attached to an application-level library, which is then attached to the Designer-libraries (OFG4*).
    Does anyone know why this code lists the Designer libraries, but not the others?
    If you convert the FMB to XML, it also has only the Designer-libraries, but opening the Form in Form Builder shows the full list.
    2) I attempted to remove all the libraries from the Form by adding a lib.destroy(); into the loop above and a fmd.save(args[0]); after it. When I run this the loop terminates after the first iteration. It doesn't report any errors, but it doesn't actually remove the module library either. It is doing something though, because if you reopen the Form in Form Builder the module and application library attachments have been lost and just the Designer ones remain?
    I don't really want to update all the modules by hand, and any assistance would be greatly appreciated.
    FWIW I also tried converting the FMBs to XML using the IFF2XML90 batch file, and then doing a search & replace on the XML file before converting back into a Form using IFXML2F90.bat. This doesn't work either because it also loses the module and application library attachments as described above, possibly because these batch files are using JDAPI internally and JDAPI doesn't like my Forms!
    Thanks
    Roger

    I sincerely hope that you have found a solution by now....
    It is a strange situation that you describe.
    I think you might have found that the OFG-libraries are actually in a different directory from where you expected them to be found by JDAPI. Have you used lib.getLibraryLocation()?
    The next step would have entail trying to find out where this different path was set, and why JDAPI uses that setting, instead of the settings in registry and batchfile.
    Just some thoughts.
    Greetings!
    Remco

  • Replacing library Location using Jdapi ??? SUCCESS

    Hi,
    we want to replace physical directory names by only the name of pll attached to forms and menus.
    (eg : C:\directory\mypll.pll replaced by mypll)
    to be able to use the forms_path.
    Using Jdapi the first problem is that whith FormModule.open() the library is not found of course.
    Is there a way to trap this exception like the forms migration assistant does
    ERROR opening myform.fmb :oracle.forms.jdapi.JdapiException: FRM-10102: Imposs. attacher biblio PL/SQL C:\directory\mypll.pll : risque de perte d'attachement en cas d'enreg. de module.???
    And than reattach the pll trapped by the exception?
    Last point, there is method getLibraryLocation which give the physical path to the pll, but there is no setLibraryLocation method that will be usefull in our case.
    Is there a way to achieve that ?
    Thanks
    JeanYves
    Message was edited by:
    JeanYves
    Message was edited by:
    JeanYves
    Message was edited by:
    JeanYves
    Message was edited by:
    JeanYves

    Hi Christian,
    Thank you very much for your answer !
    when using the wrong working direcotry, the library attachment gets lost when saving the form.The problem is that the fmb and pll are in about 20 different dir. And the lib are attached by relative path from a starting directory (that was working fine in 6i C/S windows mode) :
    C:\app\startdir and then the fmb and pll are in C:\app\startdir C:\app\dir1 C:\app\dir2 etc. So one fmb in dir1 can have an attached library like ..\startdir\st.pll and another ..\dir2\dir2.pll.
    What we wanted to do is to regroup they by file type directory (fmb pll mmb rdf ) because the forms path will be too long. And that's why we lost the attachment.
    I made some tests with frmf2xml but the attachment is also lost.
    So we went back to the initial structure with all the directories.
    I made a test frmf2xml starting from C:\app\dir1 and when i convert an fmb then the attachment was not lost.
    In the tag AttachedLibrary the LibrayLocation was ..\dir2\dir2.pll.
    I will see this morning with our java developer to make appropriate changes (i.e: CurrLib.setStringProperty(JdapiTypes.LIBRARY_LOCATION_PTID, "mypll")
    and test it.
    Thanks again for your help !
    JeanYves

  • How to attach that object_library to a form using jdapi?

    Hi!
    I am doing a migration process from Forms 6i to Forms 10g, and I need to attach an object_library object to a specific form using jdapi. The object_library that I want to attach is the web_util object_library.
    How to attach that object_library to a form using jdapi?
    Thanks.

    I had never used JDAPI before reading your post, but the attached code creates a minimal WebUtil-enabled form from scratch -- adapting it to update an existing form should be fairly straightforward. I've only been coding in Java for about a year, so consider this only as a starting point -- there may be better, easier ways of doing this.
    import oracle.forms.jdapi.*;
    public class Driver {
      public Driver() {
        /* create a minimal form */
        FormModule frm = new FormModule("JDAPI_DEMO");
        Block dummyBlock = new Block(frm, "BLK_DUMMY");
        Canvas dummyCanvas = new Canvas(frm, "CVS_DUMMY");
        Item textItem = new Item(dummyBlock, "TXT_DUMMY");
        textItem.setCanvasObject(dummyCanvas);
        /* open WebUtil object library */
        ObjectLibrary olWebUtil = ObjectLibrary.open("c:/ora10g/forms/webutil.olb");
        /* attach WebUtil PL/SQL library */
        AttachedLibrary alWebUtil = new AttachedLibrary(frm, "c:/ora10g/forms/webutil.pll");
        /* loop through each tab in object library */
        for (JdapiIterator it=olWebUtil.getObjectLibraryTabs(); it.hasNext();) {
          ObjectLibraryTab olt = (ObjectLibraryTab) it.next();
          /* loop through each object in tab */
          for (JdapiIterator it2=olt.getOwnedObjects(); it2.hasNext();) {
            JdapiObject obj = (JdapiObject)(it2.next());
            String className = obj.getClassName();
            /* handle module parameters */
            if (className.equals("ModuleParameter")) {
              ModuleParameter mp =
                new ModuleParameter(frm, obj.getName(), (ModuleParameter) obj);
            /* handle object groups */
            if (className.equals("ObjectGroup")) {
              ObjectGroup og = new ObjectGroup(frm, obj.getName(), (ObjectGroup) obj);
        frm.compile();
        frm.save("c:/jdapi_demo.fmb");
      public static void main(String[] args) {
        Driver drv = new Driver();
    }

  • Error while accessing a library using content and structure

    I have a library having document and folder inside it. When I open the library using content and structure I get an error with a correlation ID. When checked the the logs with Correlation ID got an error message "View 'All Document' does not exist."
    'All Document' is name of default view on the library.
    When I open the library from view all site content the library is being opened.
    Please help!!!

    Hello Victoria,
    Thanks for  the response.
    I have tried troubleshooting steps given by you. 
    Check if the issue occurs with other users. Use another user to access the library in Content and Structure and then compare the results. --
    I tried with different users but no luck
    Make sure that the user account with issue has permission to view the All Documents view of the library. --
    Yes, user Account have the permission
    Check if the issue occurs with other libraries in the Content and Structure. If not, I recommend to save the library as
    a template including contents and then create a new library based on this template. After that use the new library instead of the old library. --
    No other library have this problem. I cannot save the library as template including the contents as the it has many folders and  files. The current size of library is 786 MB
    Clear cache in the browser or use another browser to see if the issue still occurs. --
    tries but issue persists.
    Best regards,
    Ratnesh

  • I downloaded a WMA audiobook from library using Overdrive. It shows up on my Itunes listing of Audiobooks on my Ipod, but on the actual Ipod it only shows up on Playlists. How do I get it to show up under Audiobooks?

    I downloaded a WMA audiobook from library using Overdrive. It shows up on my Itunes listing of Audiobooks on my Ipod, but on the actual Ipod it only shows up on Playlists.  It is marked as an audiobook in Options | Media Kind.  It is also marked to Remeber Position, but it does not do that. How do I get it to show up under Audiobooks and remember the position?  I have a 4th Gen Ipod running Ios5

    Check out the instructions for a work around on this post: https://discussions.apple.com/message/18702732#18702732
    This worked for me.  I would like to see Apple fix this issue, as it isn't very fun to have to do this for every downloaded book.

  • I have the current iPhoto when I try to open it I get an error message You can't open your current photo library using this version of iPhoto

    You can’t open your current photo library using this version of iPhoto.
    I am using the current iPhoto and O/S 10.8.2

    Make a temporary, backup copy of your library if you don't already have one (Control-click on the library and select Duplicate from the contextual menu) and  apply the two fixes below in order as needed:
    Fix #1
    Launch iPhoto with the Command+Option keys held down and rebuild the library.
    Select the options identified in the screenshot. 
    Fix #2
    Using iPhoto Library Manager  to Rebuild Your iPhoto Library
    Download iPhoto Library Manager and launch.
    Click on the Add Library button, navigate to your Home/Pictures folder and select your iPhoto Library folder.
    Now that the library is listed in the left hand pane of iPLM, click on your library and go to the File ➙ Rebuild Library menu option
    In the next  window name the new library and select the location you want it to be placed.
    Click on the Create button.
    Note: This creates a new library based on the LIbraryData.xml file in the library and will recover Events, Albums, keywords, titles and comments but not books, calendars or slideshows. The original library will be left untouched for further attempts at fixing the problem or in case the rebuilt library is not satisfactory.
    OT

  • Can't open current photo library using this version of iPhoto 7.1.5

    I have recently had to perform a disk repair due to the disk image not mounting. In this process I completed a full backup of my home folder and verify/repair/format of my harddrive. At this time I also added 4G RAM bringing the MacBook up to 5G RAM.
    Since the reinstallation of 10.7.5 (Which took about 18hrs) I have none of the iLife package. I have reinstalled from the original disk that I recieved on initial purchase back in 2008. After installation I ran the software update and have updated everything (iTunes, iPhoto etc) I have been able to import all data from my backup via a simple drag & drop. I am now unable to open my iPhoto library (file size 105.43G). I have searched many forums and have been unable to find a solution that is suitable (rebuild library) because as soon as I launch this option it brings up the following message:
    You can’t open your current photo library using this version of iPhoto. You have made changes to your photo library using a newer version of iPhoto. Please quit and use the latest version of iPhoto.
    After this I must quit the application. What am I missing? I'm sure it is something quite simple... I'm hoping it is as easy as it was to find the recoveryHD during the reformat of the disk.
    Any help would be greatly appreciated, Cheers.

    It sounds like a damaged library. Try the 2 fixes below in order as needed:
    Fix #1
    Launch iPhoto with the Command+Option keys depressed and follow the instructions to rebuild the library. Select the last three options.
    Fix #2
    Rebuild the library using iPhoto Library Manager as follows:
    Using iPhoto Library Manager to Rebuild Your iPhoto Library
    1 -Download iPhoto Library Manager and launch.
    2 -Click on the Add Library button, navigate to your User/Pictures folder and select your iPhoto Library folder.
    3 - Now that the library is listed in the left hand pane of iPLM, click on your library and go to the File->Rebuild Library menu option
    4 - In the next window name the new library and select the location you want it to be placed.
    5 - Click on the Create button.
    Note: This creates a new library based on the LIbraryData.xml file in the library and will recover Events, Albums, keywords, titles and comments but not books, calendars or slideshows. The original library will be untouched for further attempts at fixing or in case the rebuilt library is not satisfactory.

  • Not able to copying files/folders from one Document Library to another Document Library using Open with Browser functionality

    Hi All, 
    We have SharePoint Production server 2013 where users are complaining that they are not able to copy or move files from one document library to another document library using “Open with Explorer” functionality.
    We tried to activate publishing features on production server but it did not work. We users reported following errors:  
    Copying files from one document library to another document library:
    Tried to map the document libraries and still not get the error to copy files: 
    In our UAT environment we are able to copy and move folders from using “Open with Explorer” though.
    We have tried to simulate in the UAT environment but could not reproduce the production environment.  
    Any pointers about this issue would be highly appertained.
    Thanks in advance
    Regards,
    Aroh  
    Aroh Shukla

    Hi John and all,
    One the newly created web applications that we created few days back and navigated to document library, clicked on “Open with Explorer”, we get this error.
    We're having a problem opening this location in file explorer. Add this website to your trusted and try again.
    We added to the trusted site in Internet Explorer for this web application, cleared the cache and open the site with same document library but still get the same above error.
    However, another existing web application (In same the Farm) that we are troubleshooting at the moment, we are able click on “Open with Explorer”,  login in credentials opens and we entered the details we are able to open the document
    library and tried to follow these steps:
    From Windows Explorer (using with Open with Explorer), tried to copy or move a files to
    source document library.
    From Windows Explorer moved this file to another destination document library and we got this error.
    What we have to achieve is users should be able to copy files and folders using
    Open with Explorer functionality. We don’t know why Open with Explorer
    functionality not work working for our environment.  
    Are we doing something wrong? 
    We have referred to following websites.
    we hope concepts of copying / Moving files are similar as SharePoint 2010. Our production environment is SharePoint 2013.   
    http://www.mcstech.net/blog/index.cfm/2012/1/4/SharePoint-2010-Moving-Documents-Between-Libraries https://andreakalli.wordpress.com/2014/01/28/moving-or-copying-files-and-folders-in-sharepoint/
    Please advise us. Thank you.
    Regards,
    Aroh
    Aroh Shukla

  • I try to open iphoto and it comes up with You have made changes to your photo library using a newer version of iPhoto. Please quit and use the latest version of iPhoto. I have downloaded photo manager and it's telling me to update but it wont update...

    I try to open iphoto and it comes up with You have made changes to your photo library using a newer version of iPhoto. Please quit and use the latest version of iPhoto. I have downloaded photo manager and it's telling me to update but it wont update...

    iPhoto is Apple's included program to manage your photo's and pictures.
    It receives updates over time with Software updates and new machine or iLife purchases.
    When iPhoto gets updated or a newer version is used, it may alter iPhoto support files, but newer iPhoto versions usually always compatible with older files which it then updates.
    If you used a newer iPhoto on your iPhoto support files, then they got altered to the newer format, older iPhoto versions can't read the older format.
    Somewhere along the line you somehow got a older version of iPhoto on your computer, you need to fine the newer version of iPhoto (not this photo manager, sounds like another program)
    Or somewhere along the line you used a newer iPhoto version (like on another Mac) and it altered the iPhoto support files on your older version of iPhoto.
    So the key here is to find the newest version of iPhoto and use that to access your iPhoto support files.
    If you didn't access your iPhoto support files from another Mac, then you should have the newer iPhoto version on your computer.
    Once you find it, and get it in the Dock, you should remove the older iPhoto version from your computer to prevent this from happening again.
    Lastly, if the newer version of iPhoto is somehow gone off your computer, you should be able to get a copy off the latest OS X install disk or iLife using a free program called Pacifist.
    http://www.charlessoft.com/
    Then you need to check for updates for iPhoto in the program itself, the current version is 9.1.2

  • I keep receiving this message "You can't open your current photo library using this version of iPhoto" You have made changes to your photo library using a newer version of iPhoto. Please quit and use the latest version of iPhoto."

    I keep getting this message. What do I do? You have made changes to your photo library using a newer version of iPhoto. Please quit and use the latest version of iPhoto.

    https://itunes.apple.com/ca/app/iphoto/id408981381?l=en&mt=12

  • Can't open iPhoto after installation .Displays message :You can't open your current photo library using this version of iPhoto

    Can't open the program after Installing . Shows message " You can't open your current current photo library using this version of photo.
    Made several attemps in fresh instalaltion without any success.

    So I assume it is version 9.3, not sure?
    Look at the application in the Finde, if you cannot launch it.
    Select your iPhoto application in in the Applications folder and use the command "File > Get Info". What does the Info panel show in the "General" brick?
    If it says 9.4.3, try to launch iPhoto by clicking the iPhoto icon in the Applications folder. Does that work?

  • Yet AGAIN! "You can't open your current photo library using this version of iPhoto"

    I have read every thread on this topic I could find in these forums, and tried most solutions, and I still can't get iPhoto to work. 
    Equipment:  MacBook Pro June 2010, OS 10.6.8.  Bought a Macbook Air February 2012, OS 10.7.2
    Not sure why, but I can't open iPhoto.  Here's what I have tried.
    Original message on MBPro:  "You can’t open your current photo library using this version of iPhoto". 
    1.  Tried to rebuild library as per this thread https://discussions.apple.com/message/8429269#8429269.  I get the list of checkboxes, but when I hit "okay" I get the same "you can't open your current photo library ..." message again.
    2.  Ran software update - no sign that iPhoto is out of date.
    3.  Copied new version of iPhoto from brand new MBAir to MBPro, replacing older version .  Got same "you can't open your current photo library ..." message again.
    4.  Tried to rebuild library using new version of iPhoto - guess what - same message.
    5.  Downloaded free trial version of iPhoto Library Manager as suggested in the thread referenced above.  The dmg loads to my desktop just fine but nothing happens when I click on it -- this has never happened before.  Perhaps it is looking for iPhoto, which of course I can't get to work.
    So I have been unable to access my old iPhoto library with (sob) thousands and thousands of family photos in it.  I run TimeMachine on to an external hard drive every hour so I hope that if my iPhoto library is corrupted, there is a safe copy on that external drive ...
    Between this hassle -- hours of time wasted -- and recent debacle of upgrading iTunes which erased my library and all of my playlists, which also took hours and hours to restore ... my 25 year devotion to Apple products is taking a major hit.  I'm getting very weary of heart-pounding fear every time a new software upgrade arrives ... but that's a topic for another time. ;-)
    Thank you very much indeed for all suggestions.

    I'm going to start from scratch as  the link you references is very, very old.
    Try this:  launch iPhoto with the Option key held down and try to create a new, test library and import some photos. If you are able to then the problem lies with your current library. If you get the same message then maybe the iPhoto application is the problem.
    Try the following again:  make a temporary, backup copy (if you don't already have a backup copy)  of your library and apply the three fixes in order as necessary.
    Fix #1
    1 - delete the iPhoto preference file, com.apple.iPhoto.plist, that resides in your HD/User/Home()/ Library/Preferences folder.
    2 - delete iPhoto's cache file, Cache.db, that is located in your HD/User/Home()/Library /Caches/com.apple.iPhoto folder. 
    3 - launch iPhoto and try again.
    NOTE: If you're moved your library from its default location in your Home/Pictures folder you will have to point iPhoto to its new location when you next open iPhoto by holding down the Option key when launching iPhoto.  You'll also have to reset the iPhoto's various preferences.
    Fix #2
    Launch iPhoto with the Command+Option keys held down and rebuild the library.
    Select the options identified in the screenshot. 
    Fix #3
    Using iPhoto Library Manager  to Rebuild Your iPhoto Library
    Download iPhoto Library Manager and launch.
    Click on the Add Library button, navigate to your Home/Pictures folder and select your iPhoto Library folder.
    Now that the library is listed in the left hand pane of iPLM, click on your library and go to the File ➙ Rebuild Library menu option
    In the next  window name the new library and select the location you want it to be placed.
    Click on the Create button.
    Note: This creates a new library based on the LIbraryData.xml file in the library and will recover Events, Albums, keywords, titles and comments but not books, calendars or slideshows. The original library will be left untouched for further attempts at fixing the problem or in case the rebuilt library is not satisfactory.
    If all of these fail there's one more option:
    Start over from scratch with new library
    Start over with a new library and import the Originals (iPhoto 09 and earlier) or the Masters (iPhoto 11) folder from your original library as follows:
    1.  Move the existing library folder to the desktop.
    2. Open the library package like this.
    Click to view full size
    3. Launch iPhoto and, when asked, select the option to create a new library.
    4. Drag the each subfolder in the Originals folder (iPhoto 09 and earlier) or the entire Masters (iPhoto 11) folder from the iPhoto Library on the desktop into the open iPhoto window.
    Click to view full size
    This will create a new library with the same Events as the original library but will not keep the metadata, albums, books slideshows and other projects.
    OT

  • You can't open your current photo library using this version of iPhoto.

    I tried to open iphoto this morning and recieved this message: "iphoto damaged or incomplete." There was also a white circle with a slash through the icon in both dock and applications folder.  Recently I had loaded idvd from ilife since it was not included on my MBP.  I reinstalled iphoto using the disc and then the following began to occur.
    I received this message when I tried to launch iPhoto after reinstalling. Yesterday it was working fine. "You can’t open your current photo library using this version of iPhoto." It gave me the option of quitting but nothing else.
    I followed directions on another thread to rebuild using the database by holding down command+option while launching iphoto.  None of my folders came back and all the photo boxes are empty, although there are dates.
    I do have a backup on an external but am not sure how I would restore using that (I've never had to in the past).
    This is iphoto 11 - version 9.1. I am unsure how to check what version was installed when I purchased this MBP (Nov. 2012). I am also runnign OSX 10.8.3
    Is there anyway to remove the update and recent install and revert to what I had yesterday? Or even two days ago?
    Any help would be appreciated. I don't want to have to re-create my folders.
    Thanks in advance!

    When you installed iDVD, you must accidentally also have reinstalled and downgraded iPhoto.
    This is iphoto 11 - version 9.1. I am unsure how to check what version was installed when I purchased this MBP (Nov. 2012). I am also runnign OSX 10.8.3
    You have two options, either delete your current iPhoto version and reinstall iPhoto from the AppStore, or go to the -menu and run Software update to upgrade your current iPhoto version to iPhoto 9.4.3, the current version.
    To reinstall: See this document http://support.apple.com/kb/ht4718
    Scroll down to the paragraph: Restoring iLife applications after Internet Restore of OS X Lion or OS X Mountain Lion
    It explains how to reinstall the bundled iLife applications, that came preinstalled, from the AppStore.
    Regards
    Léonie

Maybe you are looking for