Inserting non-serializable objects

Is there any way to insert non-serializable objects into a database? (Or to convert them to bytes?)

Is there any way to insert non-serializable objectsinto a database?
A joke right?No, it's not a joke. It would be a pretty bad one if it were.
Yes, there is a way. Create a table that corresponds
to the object where each attribute in the object
corresponds to field in the object. Add a unique key
if one doesn't exist.I wish it were that simple. I don't have access to those attributes...
>
To create an object insert a row into the table. To
load the object use the unique key to query for the
row. To 'delete' the object delete the row from the
table.BTW, the object in question is the java.awt.geom.Area object (http://java.sun.com/j2se/1.3/docs/api/java/awt/geom/Area.html ).
The only way I can think of to insert an object that doesn't map to a SQL type is to convert it to bytes through serialization, and insert it as RAW data.
I've extended Area to add a name and made my class serializable. However, since Area is not serializable, the only data I can retrieve after deserializing is the name I added (from my understanding of serialization, I have to save Area's data myself, but can't since I don't have access to it, so the deserialization process calls the Area() constructor which initializes the object to empty).

Similar Messages

  • Sending Non-Serializable Objects

    I'm trying to make my server program send a non-serializable object to the client program. But I'm getting a 'java.io.NotSerializableException'. Is there any way to send a non-serializable object through an ObjectOutputStream, or through some other type of stream object?
    Thanks.
    ~jon

    I have some experience before, here is one solutions:Well, nice to know, but its not a solution to the problem discussed in this topic though.
    >
    >
    using toByteArray to get a byte[] and a length of the
    array
    then using the following format to send through
    sockets,
    [bytearray.length][byte array content]
    It really works in a project of a MMS system I have
    worked on.

  • Serialializing non serializable objects

    Hi guys,
    I have to serialize (and then send through socket) a class which implements java.io.Serializable. This class also has some reference with other classes, which should be serialized togheter.
    But when I run the main class (which only serializes) , java.io.NotSerializableException is thrown.
    How do I recognize if a class is effectively serializable?
    How do I serialize too even with non-serializable objects?
    (I need all these objects)
    note : In the class I have only put the marker "implements java.io.Serializable",should I have to do somenthing else?
    Thank You for your great help!

    Hi guys,
    I have to serialize (and then send through socket)a
    class which implements java.io.Serializable. This
    class also has some reference with other classes,
    which should be serialized togheter.
    But when I run the main class (which onlyserializes)
    , java.io.NotSerializableException is thrown.
    How do I recognize if a class is effectively
    serializable?
    How do I serialize too even with non-serializable
    objects?
    (I need all these objects)
    note : In the class I have only put the marker
    "implements java.io.Serializable",should I have todo
    somenthing else?
    Thank You for your great help!I wish there was a utility that could inspect a
    Class, traverse its containment tree and flag
    serializability issues. This could be more powerful
    if generics are used.
    To solve your problem besides the marker, implement
    methods writeObject and readObject and serializing
    the contained object that is not serializable by
    hand. For example if your class is X which contains Y
    that is not serializable then you need to serialize
    fields Y in X.writeObject and construct a Y object in
    X.readObject:
    class Y { // not serializable and you cannot modify
    it
    int i;
    int j;
    Y(int i, int j)
    class X implements Serializable {
    String xyz;
    Y y;
    private void writeObject(ObjectOutputStream out)
    throws IOException{
    out.writeObject(xyz);
    out.writeInt(y.getI());
    out.writeInt(y.getJ());
    private void readObject(ObjectInputStream in)
    throws IOException{
    xyz = (String) in.readObject();
    int i = in.readInt();
    int j = in.readInt();
    y = new Y(i, j);Remember to maintain the same order in readObject and
    writeObject.
    Hi guys,
    I have to serialize (and then send through socket)a
    class which implements java.io.Serializable. This
    class also has some reference with other classes,
    which should be serialized togheter.
    But when I run the main class (which onlyserializes)
    , java.io.NotSerializableException is thrown.
    How do I recognize if a class is effectively
    serializable?
    How do I serialize too even with non-serializable
    objects?
    (I need all these objects)
    note : In the class I have only put the marker
    "implements java.io.Serializable",should I have todo
    somenthing else?
    Thank You for your great help!I wish there was a utility that could inspect a
    Class, traverse its containment tree and flag
    serializability issues. This could be more powerful
    if generics are used.
    To solve your problem besides the marker, implement
    methods writeObject and readObject and serializing
    the contained object that is not serializable by
    hand. For example if your class is X which contains Y
    that is not serializable then you need to serialize
    fields Y in X.writeObject and construct a Y object in
    X.readObject:
    class Y { // not serializable and you cannot modify
    it
    int i;
    int j;
    Y(int i, int j)
    class X implements Serializable {
    String xyz;
    Y y;
    private void writeObject(ObjectOutputStream out)
    throws IOException{
    out.writeObject(xyz);
    out.writeInt(y.getI());
    out.writeInt(y.getJ());
    private void readObject(ObjectInputStream in)
    throws IOException{
    xyz = (String) in.readObject();
    int i = in.readInt();
    int j = in.readInt();
    y = new Y(i, j);Remember to maintain the same order in readObject and
    writeObject.

  • Returning Non Serializable Objects

    Is it possible in anyway to return non serializable objects from the remote method of an EJB, for instance return a result set. Everytime i try, i get a CORBA marshalling exception, i tried to put the resultset in a serilized object such as an enumeration or vector but got the same error when retreiving it from the enumeration or vector. Help is needed and appreciated. Thanx.

    Is it possible in anyway to return non serializable objects from the remote method of an EJB, for instance return a result set. Everytime i try, i get a CORBA marshalling exception, i tried to put the resultset in a serilized object such as an enumeration or vector but got the same error when retreiving it from the enumeration or vector. Help is needed and appreciated. Thanx.

  • Non Serializable Objects

    I am working on a java project and I have to serialize a class (created by me) which has many references to other classes that should be serialized too.
    I add the marker "implements serializable" to all the necessary classes, but when I run I get a non serializable exception.
    Maybe one ore more objects are non serializable, but how do I identify them?
    I've read that If I have to serialize non serializable objects, I need to write my own writeObject(ObjectOutputStream out)throws IOException and readObject(ObjectInputStream in) , but I don't know how to implement and us them.
    note : I can't use transient beacuse I need everything to be serialized!
    Thanks a lot. Bye!

    Now I'll post my code, If anyone knows how to serialize (and then deseserialize) the class "AgentMessage" , and its subclasses "StaticPart" and "DynElement" from the main class , I'll be grateful.. It's about 2 days I'm working on it and I continue getting "nonserialializable exception" ...
    thank you guys
    package agentsLibrary;
    //some imports
    public class AgentMessage implements Serializable{
         private static final long serialVersionUID = 1L;
         private StaticPart sp;
         private DynElement de;
         public AgentMessage(String agent,byte[] code,String mainclass,Certificate signerId,PrivateKey priv,String configuration,Serializable dclear,byte[] dsecret,PathEl[] dpath,byte[] c){ //costruttore
              sp=new StaticPart(agent,code,mainclass,signerId,priv,configuration);
              de=new DynElement(dclear,dsecret,c,dpath);
         public StaticPart getSp(){
              return sp;
         public DynElement getDe(){
              return de;
         private void writeObject(java.io.ObjectOutputStream out) throws IOException{
              System.out.println("class implements writeObject( )");
              //depends on the method to store out all the important state
              //out.defaultWriteObject();//perform the default serialization(va sempre fatto il default)
              out.writeObject(sp);
              out.writeObject(de);
         private void readObject(java.io.ObjectInputStream in)throws ClassNotFoundException, IOException {
              System.out.println("class implements readObject( )");
              //in.defaultReadObject();
              sp=(StaticPart)in.readObject();
              de=(DynElement)in.readObject();
    package agentsLibrary;
    public class StaticPart implements Serializable{
         private static final long serialVersionUID = 1L;
         private String agent="";
         private byte[] code=null;
         private String mainclass="";
         private Certificate signerid=null;
         private PrivateKey priv=null;
         private Calendar timestamp=null;
         private Signature sig=null;
         private byte[] buffertotale=null;
         private byte[] firma=null;
         private String configuration="";
         public StaticPart(String agent, byte[] code, String mainclass, Certificate signerid, PrivateKey priv,String configuration){
              this.configuration=configuration;
              this.code=code;
              this.mainclass=mainclass;
              this.agent=agent;
              this.priv=priv;
              this.signerid=signerid;
              timestamp=Calendar.getInstance();
              Date time=new Date();
              time=timestamp.getTime();//Gets this Calendar's current time.
              try {
                   byte[] nomeagent=agent.getBytes("8859_1");//converto stringa
                   byte[] mainclas=mainclass.getBytes("8859_1");//converto stringa
                   byte[] signer=signerid.getEncoded();
                   byte[] priva=priv.getEncoded();
                   byte[] dat=null;
                   dat=time.toString().getBytes("8859_1");
                   buffertotale=new byte[nomeagent.length+mainclas.length+signer.length+priva.length+dat.length+code.length];
                   System.arraycopy(nomeagent, 0, buffertotale, 0, nomeagent.length);
                   System.arraycopy(code, 0, buffertotale, nomeagent.length, code.length);
                   System.arraycopy(mainclas, 0, buffertotale, code.length, mainclas.length);
                   System.arraycopy(signer, 0, buffertotale, mainclas.length, signer.length);
                   System.arraycopy(priva, 0, buffertotale, signer.length, priva.length);
                   System.arraycopy(dat, 0, buffertotale, priva.length, dat.length);
              } catch (UnsupportedEncodingException e) {
                   e.printStackTrace();
                   System.exit(1);
              } catch (CertificateEncodingException e) {
                   e.printStackTrace();
                   System.exit(1);
              try {
                   sig = Signature.getInstance(priv.getAlgorithm());
                   sig.initSign(priv);
                   sig.update(buffertotale, 0, buffertotale.length);
                   firma=sig.sign();
              } catch (SignatureException e) {
                   e.printStackTrace();
                   System.exit(1);
              } catch (InvalidKeyException e) {
                   e.printStackTrace();
                   System.exit(1);
              } catch (NoSuchAlgorithmException e) {
                   e.printStackTrace();
                   System.exit(1);
         public boolean verify() {
              try{
                   PublicKey pub=signerid.getPublicKey();
                   Signature sig = Signature.getInstance(pub.getAlgorithm());
                   sig.initVerify(pub);
                   sig.update(buffertotale, 0, buffertotale.length);
                   return sig.verify(firma);
              } catch (SignatureException e) {
                   e.printStackTrace();
                   System.exit(1);
              } catch (InvalidKeyException e) {
                   e.printStackTrace();
                   System.exit(1);
              } catch (NoSuchAlgorithmException e) {
                   e.printStackTrace();
                   System.exit(1);
              return false;
         public String getAgentName() {
              return agent;
         public byte[] getCode() {
              return code;
         public String getClassName() {
              return mainclass;
         public PrivateKey getPrivate() {
              return priv;
         public Certificate getId() {
              return signerid;
         public byte[] getSignature(){
              return firma;
         public String getConfiguration(){
              return configuration;
    package agentsLibrary;
    import java.io.Serializable;
    public class DynElement implements java.io.Serializable{
         private static final long serialVersionUID = 1L;
         private Serializable dclear=null;
         private byte[] dsecret=null;
         private PathEl[] dpath=null;
         private byte[]c=null;
         public DynElement(Serializable dclear,byte[] dsecret,byte[]c,PathEl[] dpath){
              this.dclear=dclear;
              this.dsecret=dsecret;
              this.c=c;
              this.dpath=dpath;
         public byte[] getC() {
              return c;
         public Serializable getDclear() {
              return dclear;
         public PathEl[] getDpath() {
              return dpath;
         public byte[] getDsecret() {
              return dsecret;
    //finally the following is the main class that should serialize
    AgentMessage msg=new AgentMessage(name,code,mainclass,signerId,privata,configuration,dclear,dsecret,dpath,c);
              try {
                   System.out.println("Sending Agent Message to Server "+ip+":"+port);
                   Socket s = new Socket(ip,port);
                   ObjectOutputStream out=new ObjectOutputStream(s.getOutputStream());
                   out.writeObject(msg);
                   out.flush();
                   s.close();
              } catch (Exception e) {
                   return false;
              return true;
         }

  • Non-Serializable objects in webservice

    Hi everyone,
    I'm writing a webservice that connects and performs update on a third-party
    data repository (document management system) through the vendor provided
    framework.
    Some of the objects used in the framework are not serialized, and WebLogic
    Workshop 7.0 won't compile my services because they contain non-serializable
    objects. Those objects are not used as messages or method parameters, rather
    are the member variables of the services.
    My question is how would I go about using non-serialized objects in a
    webservice class with WebLogic Workshop 7.0? I've seen some Apache AXIS
    webservice examples that does the similar thing, but some of the services
    works with non-serializable objects. Do I need to create an EJBcontrol that
    masks non-serializable objects to be used with the webservice?
    Any input is greatly appreciated. I'm still new at webservice programming.
    Thank you,
    Makoto

    Hi everyone,
    I'm writing a webservice that connects and performs update on a third-party
    data repository (document management system) through the vendor provided
    framework.
    Some of the objects used in the framework are not serialized, and WebLogic
    Workshop 7.0 won't compile my services because they contain non-serializable
    objects. Those objects are not used as messages or method parameters, rather
    are the member variables of the services.
    My question is how would I go about using non-serialized objects in a
    webservice class with WebLogic Workshop 7.0? I've seen some Apache AXIS
    webservice examples that does the similar thing, but some of the services
    works with non-serializable objects. Do I need to create an EJBcontrol that
    masks non-serializable objects to be used with the webservice?
    Any input is greatly appreciated. I'm still new at webservice programming.
    Thank you,
    Makoto

  • Failed to replicate non-serializable object  Weblogic 10 3 Cluster environ

    Hi,
    We have problem in cluster environment, its showing all the objects in Session needs to be serialized, is there any tool to find what objects in session needs to be serialized or any way to find. There was no issue in WLS 8 when the application again setup in WLS 10, we are facing the session replication problem.
    The setup is there are two managed server instance in cluster, they are set to mulicast(and also tried with unicast).
    stacktrace:
    ####<Jun 30, 2010 7:11:16 PM EDT> <Error> <Cluster> <userbser01> <rs002> <[ACTIVE] ExecuteThread: '1' for queue: 'weblogic.kernel.Default (self-tuning)'> <<anonymous>> <> <> <1277939476284> <BEA-000126> <All session objects should be serializable to replicate. Check the objects in your session. Failed to replicate non-serializable object.>
    ####<Jun 30, 2010 7:11:19 PM EDT> <Error> <Cluster> <userbser01> <rs002> <[ACTIVE] ExecuteThread: '1' for queue: 'weblogic.kernel.Default (self-tuning)'> <<anonymous>> <> <> <1277939479750> <BEA-000126> <All session objects should be serializable to replicate. Check the objects in your session. Failed to replicate non-serializable object.>
    Thanks,

    Hi
    Irrespective of WLS 8.x or WLS 9.x, 10.x, in general any objects that needs to be synced/replicated across the servers in cluster should be Serializable (or implement serializable). The object should be able to marshall and unmarshall. Simple reason why it did not showed in WLS 8.x is may be in that version they could not show these details like Error. May be they showed as Info or Warn or Just Ignored it. Weblogic Server became more and more stable and more efficient down the lines like from its oldest version 4.x, 5.x, 6.x, 7.x to latest 10.x. So my guess is they added more logic and more functionality to capture all possible errors and scenarios. I did worked on WLS 8.1 SP4 to SP6 long time back. Could not remember if I saw or did not see these errors for cluster domain with non-serializabe objects. I vaguley remember seeing it for Portal Domains but not sure. I do not have 8.x installed, otherwise I would have given a quick shot and confirm it.
    So even though it did not showed up in WLS 8.x, still underneath rule is any object that needs to be replicated that is getting replicated in cluster needs to implement Serializable interface.
    Thanks
    Ravi Jegga

  • URGENT : Pass non-serializable objects over sockets

    I am working with a non-serializable class.I can't change it to serializable(since it's an API class).I can't create a subclass either as I need to pass the same exact Object .I have tried wrapping it in a serializable class (as transient )but then the particular object that I need is not serialized.Is there a way to pass non-serializable objects over sockets?.Some other way of doing this?. Should i use RMI or Externalize?. Any help would be appreciated.

    {snip}
    Like this:
    public class SerializableLibraryClass extends
    LibraryClass implements Serializable {
    }Then you've got a class that is exactly the same as
    LibraryClass, but is now serializable.Not quite. The base class still isn't Serializable. Take, for example, the following code:
    public class A
        public int a1;
    public class B extends A implements Serializable
        public int b1;
    B beforeSend = new B();
    beforeSend.a1 = 1;
    beforeSend.b1 = 2;
    objectOutputStream.writeObject(b);
    B afterSend = (B)(objectInputStream.readObject());Both beforeSend and afterSend have fields a1 and b1. For beforeSend, a1 = 1 and b1 = 2. For afterSend, b1 = 2 but a1 = 0. The superclass wasn't Serializable; therefore, its members weren't Serialized and, when the object was created on the other side of the stream, a1 was left at its initial value.
    In short, you can't just Serialize the subclass. That Serialization won't apply to its superclasses.

  • Pass non-serializable objects over sockets

    I am working with a non-serializable class.I can't change it to serializable(since it's an API class).I can't create a subclass either as I need to pass the same exact Object .I have tried wrapping it in a serializable class (as transient )but then the particular object that I need is not serialized.Is there a way to pass non-serializable objects over sockets?.Some other way of doing this?.

    Have you considered leaving it in situ and using RMI to manipulate it remotely ?
    To be a little pedantic, if you need the "same exact object" then there's no technique that will work for you, since you can only copy an object between JVMs, not move it.
    D.

  • Store non-serializable object in session

    Dears,
    I am storing an object in the session but after some requests the object gets null. A friend told me that happens because that object is not serializable.
    Is that true? and how to fix this?
    Thanks in advance
    BISO

    biso wrote:
    I am storing an object in the session but after some requests the object gets null. A friend told me that happens because that object is not serializable.
    Is that true? Only if the application server is configured to persist the sessions on shutdown and it is been restarted while you was using/testing the webapp. But you should have seen a NotSerializableException in the application server logs, which is fairly self-explaining.
    and how to fix this?Implement [java.io.Serializable|http://java.sun.com/javase/6/docs/api/java/io/Serializable.html].
    Or just don't restart the appserver while you're testing on the same session.

  • How to store a Non Serializable Java Object ?

    Hi..
    I have a non serializable java object which I want to store in the Oracle database and retrieve it. Can anyone help me with how to go about doing this ?
    many thanks in advance
    Ragavan

    If you share the same JVM then its possible, but I doubt that is the case. If you don't share the JVM then its
    impossible to share an object between two apps.
    But if all your attempting to do is duplicate the object in the other app then I spose it is possible, as long as
    you can reconstruct the object from information that you can interegate from the object.
    For example, if you have App A, and App B. WIthin App A is a Double d object. Then you could get the
    value of the Double by doing:
    d.doubleValue()
    write the double to a file/socket/stream, read the file/socket/stream at the other end, create a new Double
    via Double d = new Double(parsedValue);
    Now the two Apps will have a Double d object that represent the same value via a a.equals(b) == true, but
    they will not refer to the same object within memory/jvm.
    James.

  • Object (which has non-serializable attr.) serialization

    i could not solve object serialization problem in anyway. how can this be performed without "java.io.NotSerializableException"?
    import java.awt.Image;
    import java.awt.Toolkit;
    import java.io.ByteArrayOutputStream;
    import java.io.IOException;
    import java.io.ObjectOutputStream;
    import java.io.Serializable;
    public class Object2ByteArray {
        public static void main(String[] args) {
            Object2ByteArray obj2ba = new Object2ByteArray();
            AnObject anObj = obj2ba.new AnObject();
            try {
                ByteArrayOutputStream baos = new ByteArrayOutputStream();
                //FileOutputStream fos = new FileOutputStream("C:\\obj.file");
                ObjectOutputStream oos = new ObjectOutputStream(baos); //or (fos)
                baos.writeTo(oos);
                oos.writeObject(anObj);
                oos.flush();
                byte[] objInBytes = baos.toByteArray();
                System.out.println("An object (which has a non-serializable element[Image]) is written to ObjectOutputStream.");
            } catch (IOException e) {
                e.printStackTrace();
        public class AnObject implements Serializable {
            Image img = Toolkit.getDefaultToolkit().getImage("C:\\anil.jpg");
            int c = 10;
            String desc = null;
    }

    Hi,
    No, transient means that the attribute won't be sent over the stream. You usually declare fields that you don't want to send, or can't send as transient.
    /Kaj

  • Returning a serializable object from a java stored procedure

    [Server : Oracle 8.1.6 on WinNT4 server. Client : java 1.2.2 on WinNT4 workstation.]
    I am attempting to use a java stored procedure to build a complex serializable java object on the database (to minimise number of requests/queries on the network) and then return this object in response to the original query.
    I have it writing a BLOB by means of
    OutputStream os = retval.getBinaryOutputStream();
    ObjectOutputStream oos = new ObjectOutputStream(os);
    oos.writeObject(v);
    return retval;
    where retval is a blob selected from a dummy table (created for this purpose) and v is a vector containing only serializable objects.
    However, on the client side when I attempt to recover the object by
    OracleResultSet rs = (OracleResultSet)stmt.executeQuery("SELECT javatest FROM DUAL");
    oracle.sql.BLOB blob=rs.getBLOB(1);
    InputStream inp = blob.getBinaryStream();
    ObjectInputStream oinp = new ObjectInputStream(inp);
    Vector retval = (Vector)oinp.readObject();
    I get an exception telling me that the input stream does not contain an object at the line containing new ObjectInputStream(inp);
    The full exception is :
    java.io.StreamCorruptedException: InputStream does not contain a serialized object
    at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:731)
    at java.io.ObjectInputStream.<init>(ObjectInputStream.java:165)
    at eRespond.DBLayer.JavaStoredProcedures.testdbobj.test2(testdbobj.java:143)
    at eRespond.DBLayer.JavaStoredProcedures.testdbobj.main(testdbobj.java, Compiled Code)
    I've checked that the returned blob is non-null, and that oracle.sql.BLOB is used throughout.
    Any thoughts?
    Thanks,
    mark.

    Firstly I guess to be able to new B() as a Thread, B
    should extends Thread.
    Secondly the constructor should not have any return
    type:
    public B(String cmd)
    instead of
    public void B(String cmd)
    Lastly there is no need to override the start() method
    if all it does is to call the superclass. The subclass
    automatically inherits the method.
    Hope this helps.thanks for replying so soon...
    yes, you are right, it should extends Thread and it is, i forgot to out in this example... my mistake!
    i'll try the construnctor thing to see if it works. bare in mind that i working with java stored procedures, it should work even so, right?
    thanks

  • [NSUserDefaults setObject:forKey:]: Attempt to insert non-property valu

    Hi all
    I have been writting classes at work in Xcode 4.? SL 10.6.8 and every thing has been working fine. When I bring a copy home to work on under Lion in Xcode 4.3.2 I get issues (Lots of them)
    While I have solved or worked around most I am unsure why I am getting an error with my NSUserDefaults.
    I have a method that I run in a singleton
    + (void)setSaveLocation : (NSString *) saveLocation
        NSMutableDictionary * ccLogManagerDictionaryFromUserDefaults = [[NSMutableDictionary alloc] initWithDictionary:[[NSUserDefaults standardUserDefaults] valueForKey:@"CCLogManager"]];
        [ccLogManagerDictionaryFromUserDefaults setObject:saveLocation forKey:@"Save Location"];
        [[NSUserDefaults standardUserDefaults] setObject:ccLogManagerDictionaryFromUserDefaults forKey:@"CCLogManager"];
        [ccLogManagerDictionaryFromUserDefaults release];
        // Post a notification to inform other classes that the savelocation has changed
        NSNotificationCenter *notification = [NSNotificationCenter defaultCenter];
        [notification postNotificationName:@"CCLogManagerNotificationSaveLocation" object:self];
    This worked fine before. The only change I have made is to the method in a different class that send the information :
    - (IBAction)changeSaveLocation: (id)sender
        NSOpenPanel* openDlg = [NSOpenPanel openPanel];
        [openDlg setCanChooseFiles:NO];
        [openDlg setCanChooseDirectories:YES];
        if ( [openDlg runModal] == NSOKButton )
            NSArray* files = [openDlg URLs];
            int i;
            for( i = 0; i < [files count]; i++ )
                NSString* fileName = [files objectAtIndex:i];
                [CCLogManager setSaveLocation:fileName];
    I had to change two lines due to depreciation:
        if ( [openDlg runModalForDirectory:nil file:nil] == NSOKButton )
    and
            NSArray* files = [openDlg filenames];
    What I dont understand is that I am still passing a NSString as required. And if in the first method I simpy insert a @"" string like so
        [ccLogManagerDictionaryFromUserDefaults setObject:
    @"file://localhost/Volumes/MacPro%20RAID/Home%20Folder/Downloads/8-tileable-meta l-textures/"  forKey:@"Save Location"];
    Then it works
    Any assistance would be most appreciated.
    Cheers
    Steve
    Oh and the error is:
    2012-06-14 22:41:31.843 ProControl[3630:403] *** -[NSUserDefaults setObject:forKey:]: Attempt to insert non-property value '{
        "Logging Enabled" = 1;
        "Save Location" = "file://localhost/Volumes/MacPro%20RAID/Home%20Folder/Downloads/8-tileable-meta l-textures/";
    }' of class '__NSCFDictionary'.  Note that dictionaries and arrays in property lists must also contain only property values.
    And it don't save to the User Defaults.

    Hi etresoft, thanks for the reply.
    Do you mean the number 1 pertaining to "Loggining Enabled" = 1?
    If so this should be a   [NSNumber numberWithBool: YES] which is already in the userdefauts.plist. before copying the original dictionary.
    The method save should be copying a dictionary from the .plist and only changing the dictionary entry for "Save Location" which is a NSString. It shouldn't be doing anything to the "Logging Enabled" entry which as I say should already be a NSNumber numberWithBool . Plus seeing as you can change the line
    [ccLogManagerDictionaryFromUserDefaults setObject:saveLocation forKey:@"Save Location"];
    to
    [ccLogManagerDictionaryFromUserDefaults setObject:
    @"file://localhost/Volumes/MacPro%20RAID/Home%20Folder/Downloads/8-tileable-meta l-textures/"  forKey:@"Save Location"];
    and still not touch the "Loggining Enabled" = 1 I don't that the 1 is an issue.
    Sorry if I'm being dense.

  • Non serializable class in biztalk

    Is it possible to have a non serializable class in a biztalk application?
    Christiane

    Hi Christiane,
    Yes, it can be used in orchestration but in an atomic scope only.
    Steps to call a Non-Serializable .NET Helper Class inside an Expression Shape(The DLL that contains the class must be strongly signed and placed in the GAC):
     1.Add a reference to that class.
     2.Add an Atomic scope.
     3.Create an Orchestration variable of that class inside the scope.
     4.Create an instance on that object inside the scope.
     5.Call the method.
    Maheshkumar S Tiwari|User Page|Blog|BizTalk
    Server : How Map Works on Port Level

Maybe you are looking for

  • How can I get rid of the mac partition and leave windows?

    My 2009 MacPro is currently partition into MacOSX 10.7.5 and Windows 7.  I would like to delete the mac side completely and just leave windows on. I want to do this so I can regain the memory into the windows side and have this laptop be windows ONLY

  • Lock box facility

    hi experts,i want to know about:what is lock box facility?can any body tell me the configation steps for that

  • ABAP Mapping Program

    Hello Friends, Can any one give me small example how the ABAP mapping look like. Thank You & Regards Satish

  • HT201303 How do I change my security question?

    This is the first time I am using my new MacBook to purchase Ox s mountain  lion. I had a $50 itune card redeemed into my itune account. When I tried to make that purchase, a window pop up saying"because this is the first making a purchase on this co

  • Printer for Mac OS system 7.6.1?

    What printer or printers are compatable with a Mac OS computer with system 7.6.1? os   Mac OS 8.6 or Earlier   system 7.6.1 os   Mac OS 8.6 or Earlier   system 7.6.1