title: Converting Date with Time in PST into UTC format
body: <p>i am having a variable str(string type)having "28-Nov-2013 09:15 AM" as its value.How to convert it into UTC format(the above mentioned time in str variable is in PST, hence UTC should be 8 hours more than that).I am using flex 2.Find below is following code which is not working:-</p>
  
  <pre><code> txtDate.text= formatDateUTC(txtDate.text); //here txtDate.text=28-Nov-2013 09:15 AM
  
      private function formatDateUTC(originalDate:String):String
      {
          Alert.show('original '+originalDate);
          var dtValue:Date = new Date(Date.parse(originalDate.replace("-"," ")));
          var editedDate:String=pstFormatter.format(dtValue);
          Alert.show('edited '+editedDate);
  
  
          return (dateFormatter.format(dateAdd("hours",8,dtValue))).toString();
  
      }
      private function dateAdd(datepart:String = "", number:Number = 0, date:Date = null):Date
              {
          if (date == null) {
              date = new Date();
          }
  
          var returnDate:Date = new Date(date);;
  
          switch (datepart.toLowerCase()) {
              case "fullyear":
              case "month":
              case "date":
              case "hours":
              case "minutes":
              case "seconds":
              case "milliseconds":
                  returnDate[datepart] += number;
                  break;
              default:
                  /* Unknown date part, do nothing. */
                  break;
          }
         return returnDate;
      }
  </code></pre>