Save a "component of a JFrame to a file.  serialization

hi there
i read something about serialization and using the transient the example on there just using one non-serializable object . but in my case the object is going to be saved which contains : contains: String, double, Graphic, some DataSet.... etc.
actually , i am trying to save a 'component' of a JFrame to a file, the component is a graph........... then i could load the file to do something configration (etc change the name of the graph "String", change the color....).
but when i use the wirteObject method :
out.writeObject(component);
I got the NotSerializableException. I know all the objects have to be serializable in order to use the writeObject method also i know some of the component's objects aren't serialzable but it might contains a 100 of different objects??????...
as i understand, i have to override the readObject and writeObject methods to make alll the object to serialization????? so how could i do that??? there is not just one or two objects..
pls help
thanks in advance

Take a look at this stuff and see if it helps to solve your problem:
http://java.sun.com/products/jfc/tsc/articles/persistence4/index.html
It provides some classes, etc. on how to persist your object graph as an XML file, and then read it back in, etc.

Similar Messages

  • Main component in a JFrame?

    Hi all,
    Just wondering, how do you set the main component in a JFrame (or JDialog). The main component being the component that gets activated when you hit the enter key.
    thanks,
    J

    Well, you can set the default button:
    getRootPane().setDefaultButton(...);

  • Reusable prompt to save changes component

    Using jsf/adf 10.1.3.4. I've implemented a reusable prompt to save changes component as described in john's blog (http://stegemanoracle.wordpress.com/page/3/). In that blog he mentions some questionable/buggy behavior regarding the dialog framework. Specifically, there's an issue with using something other than partialSubmit="true" on the component that launches the dialog box. Using something other than partialSubmit="true" on the button/link results in not being able to navigate in the return listener of the dialog. I think I'm a victim of a similar issue and wanted to see if there were any ideas/suggestions.
    I'm launching my dialog using partialSubmit = "true" on the commandButton and my navigation (in the return listener) is not working in a certain scenario. I think what is causing the navigation not to work is the fact that on my page I have an input text that fires a value change listener method, which means the autoSubmit property on that inputText is set to 'true'. If the user changes a value in that inputText (w/o tabbing out of that field) and immediately clicks the button that launches the dialog, the navigation after dialog closes doesn't happen. If I change the inputText value, then tab out (firing the autoSubmit), then click the button that launches the dialog, navigation occurs properly when the dialog closes. Am I stuck with this limitation or is there some workaround? I was also curious as to whether this type of thing has been addressed in the latest 11g version, as we're thinking about migrating our apps soon. Thanks.

    Hi kcjim,
    11g has capability for this behaviour out-of-the-box, so no need to use my approach there. I was never able to find a satisfactory solution in 10.1.3.x to the issues described.
    John

  • Error while using Image component to display a child flash file

    Hi
    I'm using Xcelsius version 4.5. I used the "Image Component" to import a child flash file(.swf) into the parent flash file.
    I gave the path "D:\246024\Loblaw\Dashboard Docs\New Folder\trend input.swf" in the general tab of the image component.
    After exporting the .xlf into a flash file , it works fine in the system in which i created it. If i open the same flash file in any other system the parent file opens but the child flash file imported through the image component is not displayed.
    Please help me out in solving this issue
    Thanks
    Anitha

    yes, you will face the same problem as its still looking for the path of the swf.
    you need to have the SWF on specific location which is accessable by the Parent SWF
    usually web page or something which is accessable for all.
    good luck

  • How can I save a page offline? the "complete" option in "save as" produces a folder w/ 36 kb files that will not open.

    the "complete" option in "save as" produces a folder w/ 36 kb files that will not open anything - can't I save the page as a single offline file?

    This is not really an answer just my comments on your question.
    I am sure I recollect efforts being made to get mhtml to work with FF.
    Probably the important thing to remember about .mhtml is that if other browsers do support it they may need addons, and may not necessarily render the content correctly/consistently.
    There are FF addons designed for archiving webpages, you could try them, but that then assumes the recipient has the same software.
    You could simply save the page from FF to your XP pc; then offline open it with and save it using IE, before then emailing using FF, and attaching the .mht or mhtml file that you have now created on your PC.
    As an alternative method, in some cases it could be worth considering taking a screen grab of the required page, then sending that to the recipient as a single email attatchment using either a bitmap or jpeg file format for instance.
    Something such as an airline booking may be designed with a print option, possibly it could be worthwile looking at sending the print file itself as an email attachment.

  • Procedure to save the output of a query into excel file or flat file

    Procedure to save the output of a query into excel file or flat file
    I want to store the output of my query into a file and then export it from sql server management studio to a desired location using stored procedure.
    I have run the query --
    DECLARE @cmd VARCHAR(255)
    SET @cmd = 'bcp "select * from dbo.test1" queryout "D:\testing2.xlsx;" -U "user-PC\user" -P "" -c '
    Exec xp_cmdshell @cmd
    error message--
    SQLState = 28000, NativeError = 18456
    Error = [Microsoft][SQL Server Native Client 10.0][SQL Server]Login failed for user 'user-PC\user'.
    NULL
    Goel.Aman

    Hello,
    -T:
    Specifies that the bcp utility connects to SQL Server with a trusted connection using integrated security. The security credentials of the network user,
    login_id, and password are not required. If
    –T is not specified, you need to specify
    –U and –P to successfully log in.
    -U:
    Specifies the login ID used to connect to SQL Server.
    Note: When the bcp utility is connecting to SQL Server with a trusted connection using integrated security, use the
    -T option (trusted connection) instead of the
    user name and password combination
    I would suggest you take a look at the following article:
    bcp Utility: http://technet.microsoft.com/en-us/library/ms162802.aspx
    A similar thread regarding this issue:
    http://social.msdn.microsoft.com/Forums/sqlserver/en-US/b450937f-0ef5-427a-ae3b-115335c0d83c/bcp-connection-error-sqlstate-28000-nativeerror-18456?forum=sqldataaccess
    Regards,
    Elvis Long
    TechNet Community Support

  • Save As Dialog Different on Exit vs. File - Save As...

    I started by opening a raw file through Camera Raw into a 16 bits/channel document.  My intent was to edit it a little and save as a JPEG.
    Photoshop CS5 Adobe added the ability to save a 16 bits/channel document as a JPEG, without first having to convert to 8 bits/channel.  BRAVO Adobe!  It's been great.
    However that functionality is specifically missing if one tries to exit Photoshop CS5 with an unsaved document.  Quite a lot of stuff is missing from the Save dialog that pops up there, actually.  It's like some kind of minimalist version.  Why?
    If I edit a 16 bits/channel document and try to exit before saving, this is the dialog it puts up:
    However, File - Save As yields this dialog:
    -Noel

    Thanks for clarifying. 
    I understand your thinking - you're trying to watch out for the newbie user and trying not to lose his/her layers, etc.
    The thing is, the way it is now makes it just a bit harder for a power-user who knows what he's doing to use Photoshop.  I've always disliked features that dumb systems down in the guise of protecting the less technical user at the expense of power.  This is not Photoshop Elements, after all!
    My case in point:  I opened a raw file, Camera Raw automatically applied the settings I had chosen and which the software had stored, I downsized the opened image, and wanted to save it as a JPEG.  It had no layers or other "fancy" attributes other than the fact that I always open raw files into 16 bits/channel depth (and I wouldn't want to change THAT default).  Since I don't, as a habit, leave applications open, I thought I would just close Photoshop and save the JPEG on the way out.  The dialog shown above defaulted to PSD, as I expected, but simply didn't allow me the choice to change it to JPEG.  So instead of just being able to blaze through the work in the quickest way, I had to cancel that dialog, choose File - Save As, then exit...
    Break in concentration and extra steps for the user who knows what he's doing.
    It seems to me that the act of prompting him on exit with a Save As dialog is all the notification needed that document information could be lost, and the user actively changing to another (lossy) format is the user's own confirmation that he/she knows what he/she is about to do.
    The more powerful Save As dialog just as it is today would be a perfect match for this.  It's a logical outgrowth of Save As A Copy, and the new feature where you're now allowing Save As JPEG directly from a 16 bit file.  By using the same dialog at the same time as making the product more powerful, you could simplify the implementation and save some future maintenance cost.
    -Noel

  • Set Adobe Acrobat XI Pro. When I want to save the file in WORD, EXCEL or esporta file into ... immediately throws an error "save as failed to process this document no file was created". What's the problem?

    Set Adobe Acrobat XI Pro. When I want to save the file in WORD, EXCEL or esporta file into ... immediately throws an error "save as failed to process this document no file was created".
    What's the problem?
    Any help in finding a solution is greatly appreciated.
    Thank you,

    Installed AcrobatXI PRO 11.0.09  on seven computers and laptops. Two of them gives an error when you try to save a document in WORD, EXCEL, Power Point, or when exporting to... error: Save failed to process this document. No File was created.
    But all good saves in the format of TXT and jpg.
    I have uninstalled and restored and re-installed and updated and registry cleaned and removed using the special utility Cleaner Tool for Acrobat, but nothing helps.
    On one notebook with Windows 8.1 and Microsoft office 2013, on another laptop with Windows 7 and Microsoft office 2010, the same problem, although there are computers with Windows 7 and Microsoft office 2010 and everything works.
    Tell me where to find the problem and how to solve it.
    Thank you.

  • Good day!     On the ultrabook Asus (System Settings: WIN 8.1 64-bit, Core I5-3317U CPU @ 1.70 Ghz, Memory 4 Gb), set Adobe Acrobat XI Pro 11.0.09 When you convert to any format via SaveAs in WORD, EXCEL, or via the Export file in ... throws the error "Un

    Good day!
    On the ultrabook Asus (System Settings: WIN 8.1 64-bit, Core I5-3317U CPU @ 1.70 Ghz, Memory 4 Gb), set Adobe Acrobat XI Pro 11.0.09
    When you convert to any format via SaveAs in WORD, EXCEL, or via the Export file in ... throws the error "Unable to process the document in the module Save As. File not created"

    Hi,
    Was it working fine for you before?
    Is it with some specific documents?
    Are you able to convert the word/excel files to pdf?
    Regards,
    Rave

  • Good day!   On the ultrabook Asus (System Settings: WIN 8.1 64-bit, Core I5-3317U CPU @ 1.70 Ghz, Memory 4 Gb), set Adobe Acrobat XI Pro 11.0.09  When you convert to any format via SaveAs in WORD, EXCEL, or via the Export file in ... throws the error "Una

    Good day!
    On the ultrabook Asus (System Settings: WIN 8.1 64-bit, Core I5-3317U CPU @ 1.70 Ghz, Memory 4 Gb), set Adobe Acrobat XI Pro 11.0.09
    When you convert to any format via SaveAs in WORD, EXCEL, or via the Export file in ... throws the error "Unable to process the document in the module Save As. File not created"

    This happens with any file .
    Send a file with the screen errors and system data . Also send a couple of files PDF.
    Translates only txt format.
    Acrobat установлен: C:\Program Files (x86)\Adobe\Acrobat 11.0\Acrobat\Acrobat.exe
        Версия: 11.0.9.29
      Дата создания: 2014/09/12
        Время создания: 13:43:46
    Браузер по умолчанию:
    Версия BIOS: _ASUS_ - 1072009
    Версия ОС: 6.2.9200 
    Всего виртуальной памяти: 4194176 KB
    Всего физической памяти: 4077252 KB
    Графическая плата: Intel(R) HD Graphics 4000
        Версия: 10.18.10.3412
        Отметить: Не поддерживается
    Доступная виртуальная память: 3638168 KB
    Доступная физическая память: 1689940 KB
    Имя пользователя: Vazgen
    Имя системы: VAZGENTAICHI
    Монитор:
        Название: Intel(R) HD Graphics 4000
        Разрешение: 1920 x 1080 x 60
        Бит на пиксел: 32
    Название ОС: Microsoft Windows Vista
    Папка Windows: C:\WINDOWS
    Папка для временных файлов: C:\Users\Vazgen\AppData\Local\Temp\
    Почтовая программа по умолчанию: Microsoft Outlook
        mapi32.dll
        Версия: 1.0.2536.0 (winblue_rtm.130821-1623)
    Производитель ОС: Microsoft Corporation
    Процессор: Intel64 Family 6 Model 58 Stepping 9 GenuineIntel  ~1696  Mhz
    Сведения о Windows:
       Планшетный ПК: Да
       Начальная версия: Нет
       Media Center Edition: Нет
       Медленный компьютер: Нет
    Сведения о сеансе:
       Тип загрузки: Обычный
       Завершение работы: Нет
       Сеть: Доступно
       Внутри Citrix: Нет
       Внутри VMWare: Нет
       Удаленный сеанс: Нет
       Удаленное управление: Нет
       Использование JAWS: Нет
       Использование Windows-Eyes: Нет
       Использование NVDA: Нет
    Сведения об Acrobat:
       Изолирование программной среды: Отключить
       Связанная программа для чтения: Нет
       Multi-Reader с поддержкой Desktop: Отключить
    Сведения об отображении:
       Ширина экрана: 1920
       Высота экрана: 1080
       Число мониторов: 2
       Число кнопок мыши: 2
       Мышь с колесом прокрутки: Нет
       С маркером Windows: Нет
       Двухбайтовая кодировка: Нет
       С редактором метода ввода: Да
       В программе для чтения с экрана: Нет
    Сведения об учетной записи:
       Права пользователя: Администратор
       Управление учетной записью пользователя: Ограниченное
       Целостность процесса: Не определено
       Тип профиля: Отсутствует
    Установленные приложения:
       Версия Office: Office 2013 32-bit
    Файл подкачки: 4194303 KB
    Часовой пояс: Московское время (зима)
    Язык: Русский (Россия)
    C:\Program Files (x86)\Adobe\Acrobat 11.0\Acrobat\plug_ins\Accessibility.api
        Версия: 11.0.9.29
      Дата создания: 2014/09/12
        Время создания: 13:44:20
    C:\Program Files (x86)\Adobe\Acrobat 11.0\Acrobat\plug_ins\Annots.api
        Версия: 11.0.9.29
      Дата создания: 2014/09/12
        Время создания: 13:44:22
    C:\Program Files (x86)\Adobe\Acrobat 11.0\Acrobat\plug_ins\IA32.api
        Версия: 11.0.9.29
      Дата создания: 2014/09/12
        Время создания: 13:44:18
    C:\Program Files (x86)\Adobe\Acrobat 11.0\Acrobat\plug_ins\PaperCapture.api
        Версия: 11.0.9.29
      Дата создания: 2014/09/12
        Время создания: 13:43:36
    C:\Program Files (x86)\Adobe\Acrobat 11.0\Acrobat\plug_ins\SaveAsRTF.api
        Версия: 11.0.9.29
      Дата создания: 2014/09/12
        Время создания: 13:44:20
    C:\Program Files (x86)\Adobe\Acrobat 11.0\Acrobat\plug_ins\SendMail.api
        Версия: 11.0.9.29
      Дата создания: 2014/09/12
        Время создания: 13:44:20
    C:\Program Files (x86)\Adobe\Acrobat 11.0\Acrobat\plug_ins\Updater.api
        Версия: 11.0.9.29
      Дата создания: 2014/09/12
        Время создания: 13:44:22

  • I am unable to save a keynote file as powerpoint. The 'save as' option is not showing in the files menu

    Hi, I downloaded the Keynote from the App store. I shoudl be able to save the presentation as a powerpoint, but the 'Save as" option is not showing in the file menu. Please help with a solution.

    Export
    If you are using Lion, there is no Save As in iWork apps. It is no longer a menu item.

  • Updated to Oct 2014 version of photoshop CC. since that time cannot save ANY work.  I can work on files but when I hit 'save as" every time it says "photoshop has quit working and needs to close."

    Updated to Oct 2014 version of photoshop CC. since that time cannot save ANY work.  I can work on files but when I hit 'save as" every time it says "photoshop has quit working and needs to close." Need solution now.

    BOILERPLATE TEXT:
    Note that this is boilerplate text.
    If you give complete and detailed information about your setup and the issue at hand,
    such as your platform (Mac or Win),
    exact versions of your OS, of Photoshop (not just "CS6", but something like CS6v.13.0.6) and of Bridge,
    your settings in Photoshop > Preference > Performance
    the type of file you were working on,
    machine specs, such as total installed RAM, scratch file HDs, total available HD space, video card specs, including total VRAM installed,
    what troubleshooting steps you have taken so far,
    what error message(s) you receive,
    if having issues opening raw files also the exact camera make and model that generated them,
    if you're having printing issues, indicate the exact make and model of your printer, paper size, image dimensions in pixels (so many pixels wide by so many pixels high). if going through a RIP, specify that too.
    etc.,
    someone may be able to help you (not necessarily this poster).
    a screen shot of your settings or of the image could be very helpful too.
    Please read this FAQ for advice on how to ask your questions correctly for quicker and better answers:
    http://forums.adobe.com/thread/419981?tstart=0
    Thanks!

  • Why can't I save text I've entered into a PDF file?  When I hit "Save As", only the PDF document is saved, but not the text i typed into the document.  I'm using Windows 8.

    Why can't I save text I've entered into a PDF file?  When I hit "Save As", only the PDF document is saved, but not the text i typed into the document.  I'm using Windows 8.

    THANK YOU!
    Jan Whitfield
    The College Planning Center
    250 Palladio Parkway, Suite 1311
    Folsom, CA 95630
    (916) 985-0453
    www.TheCollegePlanningCenter.com

  • I have Maverick 10.9.1 installed I scanned a photo on my HA D 110 series but it won't let me print or save it: An error has occurred saving the file because it could not be written to.  Check the properties for the file to make sure it is not read-only.

    I have Maverick 10.9.1 installed I scanned a photo on my HP D 110 series but it won't let me print or save it: An error has occurred saving the file because it could not be written to.  Check the properties for the file to make sure it is not read-only.

    Read the user manual that came w/the scanner and/or contact HP Support.
    http://support.apple.com/kb/PH14141 OS X Mavericks: Reset the printing system 
    http://support.apple.com/kb/HT3669 Printer and scanner software available for download 
    A scanner driver you may wish to consider:  VueScan Scanner Software

  • Save as Reduced Size PDF and Save as Optimized PDF do not reduce the file size.  What gives?

    Save as Reduced Size PDF and Save as Optimized PDF do not reduce the file size.  What gives?  I used Acrobat 9 to do this for a long time.  I recently received new laptop loaded with with Acrobat 10 and it does not work the same.  I typically scan 8-10 pages of receipts, combine the files in Acrobat, and then optimize to reduce the size so I can upload with my expense report.  Typically, my files were reduced to 200-400 KB.  I have a 2 MB file that will not reduce at all.

    Bernd, thank you for your attempt to help but the option dialog windows do not contain the same options.  There are numerous other posts on this forum about this issue and there is no answer.  Clearly, there is an issue.  I have submitted this issue to our internal help desk.

Maybe you are looking for

  • Mac Mini is a let down

    Got a phone call from my family again, seems like they are having more trouble with the Mac Mini. I downloaded some demos to my flash-drive using my PC, my connection is faster on my laptop, can download Halo Demo in a few minutes, much faster than w

  • AP Credit memo issue

    AP Credit memo was properly mapped to Sales Returns account.But it got debited to Sales income account instead of the sales returns account.What is the reason behind it?it is to be noted that only two of such returns got posted to sales income accoun

  • Hdmi resolution

    I just purchased MacBook Pro 15inch Retina Display but HDMI connection with my monitor has poor resolution.  Any suggestion?

  • Default Passcodes Verification, Please!

    Apple iPhone 3G S ..... can someone verify these as the correct default passcodes or passwords? SIM PASSCODE 0000 CALL BEARING PASSCODE 0000 PRIVATE ENTRIES PASSCODE 0000 UNLOCK PASSCODE 1234 SECURITY PASSCODE 000000 Are these correct? Also, are ther

  • Org Unit Manager as Part Appraiser

    Hi all, I am creating an appraisal document which will allow different organizational unit's managers evaluate one org unit. I was wondering is there any way that choosing organizational units as part appraisers and allow only managers to evaluate. F