11 Replies Latest reply: Feb 8, 2011 12:17 AM by Chris McLaughlin RSS

    Does new XML create empty XML variable

    Chris McLaughlin Community Member

      Hi,

       

      I have an XML variable with a bit of content and I want to completely overwrite that content.  I thought by calling "new XML" that I'd have an empty variable and could replace the content.  Is that not the case?  If it's not what method would I use to overwrite the variable content?

       

      Best regards,

       

       

      Chris McLaughlin

        • 1. Re: Does new XML create empty XML variable
          kglad MVP

          reassign the variable.  if you only want to ready the variable for gc, assign it to null.

          • 2. Re: Does new XML create empty XML variable
            Chris McLaughlin Community Member

            The method suggest by kglad works to create an empty XML variable.  But calling new XML also appears to work.  The problem I was seeing (as so often happens) was ocurring elsewhere where a string was retaining it's value.

            • 3. Re: Does new XML create empty XML variable
              Chris McLaughlin Community Member

              Hi kglad,

               

              As always thanks.  Would it be possible to ask you a question unrelated to this thread?  It's in regard to an idea I have for a forum?

               

              Best,

               

              Chris

              • 4. Re: Does new XML create empty XML variable
                kglad MVP

                sure,  ask away.

                • 5. Re: Does new XML create empty XML variable
                  Chris McLaughlin Community Member

                  Hi kglad,

                   

                  I notice that you and Ned Murphy are usually the people who suggest solutions to the questions posted by me and others.  I don't know whether this means that you are employed by Adobe but I imagine you have some relationship with them.  Please correct me if I'm way off base.  Anyway . . . I have an idea for a forum.  I suppose it is nothing more than a discussion but as I think that it is something that could benefit a lot of programmers, I'm wondering:

                   

                  1. If there is a way to propose such an idea to Adobe in the interest of creating a more high profile scheduled event

                  2. If there is a way to have veteran problem solvers such as yourself and Ned (and others) on board

                   

                  Anyway, I'd appreciate your thoughts-- even if they are that I'm barking up the wrong tree.

                   

                  Thanks,

                   

                   

                  Chris

                  • 6. Re: Does new XML create empty XML variable
                    kglad MVP

                    i've had absolutely no relationship with adobe until a few months ago.   in the past few months, i've been asked (by an adobe employee) to moderate some community help areas (which i've been doing) and i've been asked (by another employee) my opinion about some flash related issues (which i gave).

                     

                    i received 2 adobe gifts (~$50 total) for both those.  but i'm not paid for anything in these forums nor for community help work.   this is strictly voluntary.  i'm pretty sure ned is not receiving any benefits from adobe for his contributions, either.

                     

                    so, i'm not in a position to help implement your suggestions.   i would recommend posting your suggestions in the forum comments section.  i'm not sure if you'll get a response but this would be a good place to start:

                     

                    http://forums.adobe.com/community/general/forum_comments?view=discussions&start=0

                    • 7. Re: Does new XML create empty XML variable
                      Ned Murphy MVP

                      Even though I wasn't asked, since my name came up... I have no relationshiip with Adobe.  Everything I do in these forums is voluntary (helps keep my brain from drying up).

                       

                      I was once approached by someone claiming to be an employee who wanted my input for something.  He was offering something in the way of a gift for my help, but, being suspiscious I decided I best look for help of my own.  It took someone else who I knew was an employee (an administrator of these forums) more than half a year to reply to tell me that person was indeed an employee.  So that gives you some idea of how much pull any of us have around here.

                      • 8. Re: Does new XML create empty XML variable
                        Chris McLaughlin Community Member

                        Hi kglad,

                         

                        You've helped me so many times and I imagine than I'm like a grain of sand compared to the multitudes who have benefited from your advice.  Thanks again for doing what you do.  It's awesome!

                        • 9. Re: Does new XML create empty XML variable
                          Chris McLaughlin Community Member

                          Hi Ned,

                           

                          Thanks for chiming in.  I suppose it says something that I wouldn't even guess that what you do is strictly voluntary.  It's truly amazing that you contribute so much of your time to help people on these forums and others (as I've seen your name pop-up elsewhere).  For my part, I'm grateful for all the assistance that you've given.

                           

                          Best,

                           

                          Chris

                          • 10. Re: Does new XML create empty XML variable
                            Ned Murphy MVP

                            If I was to say I do this solely for the benefit of others I'd be lying--I am not that saintly.  Although it's nice to feel like you've helped someone, helping here helps me to fill in idle time... In my current situation I'm a freelancer and seldom have a full plate of work in front of me. 

                             

                            Helping here also provides me with lots of opportunities to learn new things.  I don't consider myself anywhere near being an expert with this stuff, but in trying to help, I have opportunities to try things I never did and to keep alot of the things I've learned fresh in my mind.

                             

                            Another way helping here helps me is in learning how to deal with different people.  Being human (like most folks that come here), I have my faults, and helping disgruntled posters here sometimes tests my ability to handle a bad interaction and to develop my skills in managing conflict.

                             

                            And don't feel like you are but a grain of sand to anyone here.  Folks that visit these forums with any amount of regularity leave impressions and are remembered.  There are those I look forward to helping and there are some I avoid.

                            • 11. Re: Does new XML create empty XML variable
                              Chris McLaughlin Community Member

                              Hi Ned,

                               

                              Thanks for giving me the larger picture.  I know what you mean about idle time.  One way that I've filled in the gaps is by taking on elance projects and for the same reasons, namely that they would push me to try new things, solve different problems, and deal with a variety of different personalities.  All of that has held true, and I think I've learned more in the past year than in the past five as a result. 

                               

                              The downside is that the money is usually not great, and sometimes awful, but if I'm killing idle time . . .

                               

                              Though it's not always true, I sometimes have work to spare and would definitely be willing to send some your way when I do. But we may wish to continue that conversation outside of the forum.

                               

                              My email is: chris@medxmedia.com

                               

                              I appreciate your comments with respect to the impressions left by posters and in my limited experience it holds true.  You'll do something fairly time consuming to help one person and never hear a word, and the simplest thing for another and receive effusive thanks.  Hopefully, I have continued to demonstrate my gratitude as it is sincerely felt and as I have mentioned I associate your name (and kglad's) with the helping.

                               

                              Best,

                               

                               

                              Chris