HttpService with JSON from server - help please
Hi!
I am trying to pass back a JSON object to flex using
HttpService. The scenario is like this - using HttpService I am
calling an action since i am using Struts 2.0 . This action is
supposed to return a string in JSON format. When i am passing back
the data in XML format the data is properly displayed with the
required hierarchail structure. But when I am passing back the JSON
string it is not displaying anything.
This is the call to server
<mx:HTTPService id="srv" url="...... /
myaction/getSomeData.action"/>
the srv value is coming as null.
I am a total newbie to flex.
Thanks for any help in advance,
Rohit
The code is as follows:
<?xml version="1.0"?>
<mx:Application xmlns:mx="
http://www.adobe.com/2006/mxml"
xmlns:ilog="
http://www.ilog.com/2007/ilog/flex"
layout="absolute" creationComplete="srv.send()">
<mx:HTTPService id="srv" url="
http://192.168.103.128:8081/ManageMe/manageme/generateXMLForGantt.action"/>
<mx:Style>
GanttSheet
borderStyle:none;
rowPadding: 4;
TaskItemRenderer {
borderColor: "0x388F24";
backgroundColor: "0xB5D021";
rollOverColor: "0xFDF621";
borderRollOverColor: "0xF4C811";
selectedColor: "0xFDB201";
borderSelectedColor: "0xFF9201";
selectedRollOverColor: "0xFDF621";
borderSelectedRollOverColor: "0xF4C811";
textPosition: "right";
v-align: "top";
barTopMargin: 0.3;
barBottomMargin: 0.3;
.milestone {
startSymbolBorderColor: "0x24598a";
startSymbolColor: "0x4422EE";
.summary {
borderColor: "0x000000";
backgroundColor: "0x22ee56";
endSymbolBorderColor: "0x000000";
endSymbolColor: "0x000000";
startSymbolBorderColor: "0x000000";
startSymbolColor: "0x000000";
</mx:Style>
<mx:Script>
<![CDATA[
import mx.collections.ArrayCollection;
import mx.collections.HierarchicalData;
[Bindable]
public var tasks:HierarchicalData = new
HierarchicalData(srv);
//[Bindable]
// public var tasks:HierarchicalData = null;
[Bindable]
public var constraints:ArrayCollection = new
ArrayCollection([
{ fromId:"T2", toId:"T3", kind:"endToStart" },
{ fromId:"T3", toId:"T4", kind:"endToStart" },
{ fromId:"T5", toId:"T6", kind:"endToStart" },
{ fromId:"T6", toId:"T7", kind:"endToStart" },
{ fromId:"T7", toId:"T8", kind:"endToStart" },
{ fromId:"T7", toId:"T8", kind:"endToStart" }
]]>
</mx:Script>
<mx:VBox width="100%" height="100%">
<mx:ApplicationControlBar id="toolBar" width="100%"
height="40">
<mx:HBox>
<mx:Button toolTip="Expand All Items" width="30"
height="28" click="myDataGrid.expandAll()"
icon="@Embed(source='../resources/expanded.png')"/>
<mx:Button toolTip="Collapse All Items" width="30"
height="28" click="myDataGrid.collapseAll();"
icon="@Embed(source='../resources/unhierarchical.png')"/>
<mx:Button toolTip="Zoom In" width="30" height="28"
icon="@Embed(source='../resources/zoom in5.png')"/>
<mx:Button toolTip="Zoom Out" width="30" height="28"
icon="@Embed(source='../resources/zoom out7.png')"/>
<!--<mx:Button toolTip="Expand Chart" width="30"
height="28" click="myGanttSheet.showAll(margin=10);"
icon="@Embed(source='../resources/zoom fit6.png')"/> -->
</mx:HBox>
</mx:ApplicationControlBar>
<ilog:TaskChart id="taskChart" width="100%" height="100%"
taskDataProvider="{srv.lastResult}"
taskItemStyleName="TaskItemRenderer" >
<ilog:dataGrid>
<ilog:GanttDataGrid id="myDataGrid" rowHeight="24">
<ilog:columns>
<mx:AdvancedDataGridColumn dataField="id"
headerText="ID"/>
<mx:AdvancedDataGridColumn dataField="name"
headerText="NAME"/>
<mx:AdvancedDataGridColumn dataField="baselineStart"
headerText="START TIME"/>
<mx:AdvancedDataGridColumn dataField="baselineEnd"
headerText="END TIME"/>
</ilog:columns>
</ilog:GanttDataGrid>
</ilog:dataGrid>
<ilog:ganttSheet>
<ilog:GanttSheet id="myGanttSheet"
taskItemRenderer="TaskChartCustomTaskItemRenderer"
moveEnabled="false" resizeEnabled="false"/>
</ilog:ganttSheet>
</ilog:TaskChart>
</mx:VBox>
</mx:Application>
Similar Messages
-
Hello.I wanted to upgrade my iPad 1 to iOS 5.1 Over the Air.I was running iOS 5.0.1.It said it had an error connecting to server.It is already 5 hours i cant install this update.I also have an iPhone 4 with iOS 5.0.1 with the same issues.Help please!
You're probably running into the servers simply being swamped. Thousands of people are all going for the software update at the same time. Give it a try again and if that doesn't work, then try plugging it into your computer and trying it that way.
I didn't get a notion of the size, it doesn't seem to be as big as the 700 meg 5.0 update, but it did take me 20+ minutes to download via cable internet so it's a large file. That in and of itself takes a while.
If you're trying to download it directly to your iPhone, you'll need to be on wifi since I'm sure it's well over the 20 meg file size limit for 3G. -
Failed to load properties from server. Please try again
I'm getting this message from the win32, in the property dialog
window.
"failed to load properties from server. Please try again"
In june 1 2001, thread was created
http://forums.oracle.com/forums/message.jsp?id=442131
The last message was
According to the metalink admin, this issue describes a known
bug with no current fix.
Was this not fixed in 1.2 for win32?
MitchI'm getting this message from the win32, in the property dialog
window.
"failed to load properties from server. Please try again"
In june 1 2001, thread was created
http://forums.oracle.com/forums/message.jsp?id=442131
The last message was
According to the metalink admin, this issue describes a known
bug with no current fix.
Was this not fixed in 1.2 for win32?
Mitch -
I have been trying to access my iCloud account for more than a week...looking to drop it to the 5GB from current 7GB. I always get the same answer any advice appreciated. System Preferences clcik on clous = Account status: An error was returned from server. Please try again later
I have tries later many many times.
Thanks,
SophieI don't know why you can't access it, but if you were a MobileMe subscriber with the free extra storage this has now been removed and your account will have reverted to 5GB.
-
can't log on to macbookpro goes to flashing file with ? in middle help please
A flashing question mark or globe appears when you start your Mac
Question (?) Mark, Blinking Folder, or Gray Screen at Startup
These are related but not identical issues. Their causes are outlined in Intel-based Mac- Startup sequence and error codes, symbols. Solutions may be found in:
A flashing question mark appears when you start your Mac
Mac OS X- Gray screen appears during startup
In most cases the problems may be caused by one or more of these:
a. Problem with the computer's PRAM - See Resetting your Mac's PRAM and NVRAM.
b. Boot drive's directory has been corrupted - Repair with Disk Utility.
c. Critical system files are damaged or deleted - Reinstall OS X.
d. The disk drive is physically non-functional - Replace the hard drive.
Note that the information I have provided is what Apple recommends, If other users suggest different solutions than found here, then be sure what they recommend does not impact on your warranty, if any, or ability to get continuing Apple service.
Please don't start removing drives or changing cables unless you know what you are doing and have exhausted other non-invasive alternatives outlined here. If you perform any work yourself that is unapproved by Apple, then you will void any warranty you may have and lose all further Apple Support.
Repair the Hard Drive and Permissions
Boot from your Snow Leopard Installer disc. After the installer loads select your language and click on the Continue button. When the menu bar appears select Disk Utility from the Utilities menu. After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list. In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive. If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported click on the Repair Permissions button. Wait until the operation completes, then quit DU and return to the installer.
If DU reports errors it cannot fix, then you will need Disk Warrior and/or Tech Tool Pro to repair the drive. If you don't have either of them or if neither of them can fix the drive, then you will need to reformat the drive and reinstall OS X.
The main difference if you are using Lion or Mountain Lion is that you must first boot from the Recovery HD. Simply boot from the Recovery HD to perform the above.
Reinstall Snow Leopard Without Erasing The drive
1. Repair the Hard Drive and Permissions
Boot from your Snow Leopard Installer disc. After the installer loads select your language and click on the Continue button. When the menu bar appears select Disk Utility from the Utilities menu. After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list. In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive. If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported click on the Repair Permissions button. Wait until the operation completes, then quit DU and return to the installer.
If DU reports errors it cannot fix, then you will need Disk Warrior and/or Tech Tool Pro to repair the drive. If you don't have either of them or if neither of them can fix the drive, then you will need to reformat the drive and reinstall OS X.
2. Reinstall Snow Leopard
If the drive is OK then quit DU and return to the installer. Proceed with reinstalling OS X. Note that the Snow Leopard installer will not erase your drive or disturb your files. After installing a fresh copy of OS X the installer will move your Home folder, third-party applications, support items, and network preferences into the newly installed system.
Download and install Mac OS X 10.6.8 Update Combo v1.1.
Reinstalling Lion/Mountain Lion Without Erasing The Drive
Boot to the Recovery HD: Restart the computer and after the chime press and hold down the COMMAND and R keys until the menu screen appears. Alternatively, restart the computer and after the chime press and hold down the OPTION key until the boot manager screen appears. Select the Recovery HD and click on the downward pointing arrow button.
Repair the Hard Drive and Permissions: Upon startup select Disk Utility from the main menu. Repair the Hard Drive and Permissions as follows.
When the recovery menu appears select Disk Utility. After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list. In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive. If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported click on the Repair Permissions button. Wait until the operation completes, then quit DU and return to the main menu.
Reinstall Lion/Mountain Lion: Select Reinstall Lion/Mountain Lion and click on the Continue button.
Note: You will need an active Internet connection. I suggest using Ethernet if possible because it is three times faster than wireless. -
My iMac 24 can no longer be paired with the keyboard; it doesn't recognise any keyboard at boot up, even the one it is paired with. Can anyone help, please?
Thank. SimonBrian - The batteries are fine and there has only every been one keyboard paired with it. We have tried my MacPro keyboard as well, and it will not even recognise that there is a discoverable keyboard nearby.
Thanks, Simon -
"Unable to load workflow actions from server. Please contact your server."
I get the following error message when I want to create or open a workflow in SharePoint Designer 2007
"unable to load workflow actions from server. Please contact your server
administrator."
I don't receive this error as a site collection administrator, but one of my contributors gets the error.What Chris mentioned is kind of abnormal situation described in
http://office.microsoft.com/en-us/sharepointdesigner/HA102379121033.aspx#20.
However, normally, you won’t be able to create SPD workflow if you only have Contribute permission level. I give the user Design permission level then he can
create SPD workflow.
There are other factors affecting permission to create SPD workflow:
1.
According to
http://office.microsoft.com/en-us/sharepointdesigner/HA101005871033.aspx#4
, the SPD workflows are stored in a site-level hidden document library called Workflows. You should make sure that user have permission in this document library so that the created workflow can be saved successfully.
http://blogs.msdn.com/sharepointdesigner/archive/2008/11/25/locking-down-sharepoint-designer.aspx
describe the method to manage permission for this hidden Workflows document library: open the site in SharePoint Designer >> right-click the Workflows library >> click Properties >> click the Security tab >> click the link “Manage
permissions using the browser”
2.
SharePoint Designer contributor setting (http://office.microsoft.com/en-us/sharepointdesigner/HA101174691033.aspx
) can also block the user from being able to create workflows. -
TS3510 Can't receive emails or messages with FaceTime can anyone help please thanks
Can't receive emails or messages with FaceTime can anyone help please thanks
Using FaceTime http://support.apple.com/kb/ht4319
Troubleshooting FaceTime http://support.apple.com/kb/TS3367
The Complete Guide to FaceTime + iMessage: Setup, Use, and Troubleshooting
http://tinyurl.com/a7odey8
Troubleshooting FaceTime and iMessage activation
http://support.apple.com/kb/TS4268
iOS: About Messages
http://support.apple.com/kb/HT3529
Set up iMessage
http://www.apple.com/ca/ios/messages/
Troubleshooting Messages
http://support.apple.com/kb/TS2755
Setting Up Multiple iOS Devices for iMessage and Facetime
http://macmost.com/setting-up-multiple-ios-devices-for-messages-and-facetime.htm l
FaceTime and iMessage not accepting Apple ID password
http://www.ilounge.com/index.php/articles/comments/facetime-and-imessage-not-acc epting-apple-id-password/
Cheers, Tom -
I am unable to update iOS 6 or 6.0.1 on my Iphone, even with wifi ON! Help please...
Connect to iTunes on the computer you usually Sync with and “ Check for Updates “...
If an Update Appears Install it... if not... you are up to date for your particular Device...
See the Using iTunes Section Here...
How to update your iPhone, iPad, or iPod touch -
Error when create JLabel with ImageIcon from server
Hi!
When I run applet that contain JLabel(String, ImageIcon, int) from server I get follow error: "java.security.AccessControlException: access denied (java.io.FilePermission middle-1.gif read)". .gif-file and .class-file are located in the same directory. From local disk this applet run successfully. Who can help me?
Thanks.Look at the docs for Applet class, and use getImage()
from there. Running in browser is quite different
than to run locally...
Better yet to pack image and classes in jar file,
and read from there with getResourceAsStream()
( search forums, there were examples ) -
Trouble with importing .NEF files, help please?!?!
I am trying to import my .NEF files into Lightroom and keep getting a message that pops up stating "The files are not recognized by the raw format support in Lightroom.". I have never had a problem importing .NEF files before. Does anyone know why I keep getting this message? Help, please and thank you!
Either the NEF files are from a camera newer than your LR version – each camera must be supported explicitly, OR your NEFs have been corrupted by using new camera NEFs with older Nikon software.
So either upgrade your LR to a new version or stop using obsolete Nikon software with your NEFs. You can use the following utility to fix the corrupted caused by obsolete Nikon software:
http://owl.phy.queensu.ca/~phil/exiftool/fix_corrupted_nef.html -
Novice. Creating a DVD from camcorder - help please..
Hi all,
I am tasked with creating a DVD from some of my dads camcorder tapes. Can anyone provide a simple advice list. I assume that iDVD (which i have never used) will be the software to use?
Look forward to hearing from you helpful and intelligent people out there.
From a complete simpleton.
Kind regards,
AlanHello, Alan,
First, you need to determine if these tapes are digital or not. If they are not digital, you will need to convert them into a digital media format that your version of iMovie can accept. (For example, iMovie 6 can accept only DV footage).
Does your dad have the camcorder that he used to record the tapes? If his tapes are not digital, you can connect his camcorder to a digital camcorder and record each tape to digital miniDV tape. I think it is easier to use iMovie 6 for your movie-making, especially if you are thinking about editing this footage, cropping out bad parts, adding titles, effects and/or audio clips. That is why I am recommending recording to miniDV tapes.
Having the original footage on miniDV digital tapes is also a good way to store the originals, takes up very little space.
If his tapes are some other format, post back for info regarding how to proceed,
What version of iMovie do you have? I am assuming that you have iMovie08 since you are posting in iDVD08. As stated, I recommend that you do this project in iMovie 6. If you don't have it on your computer, you can download it here:
http://www.apple.com/support/downloads/imovieHD6.html
And, I recommend viewing this tutorial: http://www.apple.com/support/imovie/tutorial/
Once you have the footage on the miniDV tapes, you can connect your digital camcorder to your computer's Firewire port, open a new iMovie project and import the footage. You should limit each iMovie to about an hour and a half, if possible. A single-layer DVD can hold about 2 hours of content maximum. It doesn't matter what the size of the iMovie is in GB, only its length matters for iDVD.
After you import the footage you want, you can edit the clips and place them on iMovie's timeline in the order you wish. You can choose to add titles, transitions, effects and audio. iMovie has one video and two audio tracks so you can easily see what you are doing. If you want to have different chapters(scenes), you mark them in iMovie. Another advantage of iMovie 6 over iMovie 8 is that you can put chapter markers where you want them, not just at specified intervals.
After your movie is finished, close iMovie.
Open iDVD, create a new project in which to place your movie.
You should do this tutorial before you begin to work in iDVD:
http://www.apple.com/ilife/tutorials/#idvd-create-63
Once you get your first iDVD project ready to burn, do a 'save as disk image' and then burn the actual DVD from the disk image using Disk Utility. You will need to use a good brand of DVD-R disks, such as Verbatim or Maxell. Memorex has been problematic for many, and don't use a cheap store brand. Select a slow burn speed, 4x or less.
That's a brief summary.....
Post back if you need further information! Good luck with your task! -
hey my iphone was working perfectly and then i sent it to check up and it came back with the itunes icon and data cable on it. so i tried plugging it in the computer and a message on itunes came up saying theres a problem with your phone and it may be damaged and cannot be activated. HELP PLEASE!!
Why on earth send a Worning phone for service sounds like cutting up a Heaththy PET to see how it looks on the inside
-
I tried to update to IPad 5.1, but when it finished and tried to restore the backup, it shows me that Itunes could not back up because a session could not be started with iPad. need your help please
This has happened to me a couple of times and what I do is quit iTunes and restart my Mac and then try again and then it will work.
If iTunes has already created the backup, you should still be able to restore from the backup when you are connected to iTunes. Right click on the iPad name on the left side of iTunes and select restore from backup. After the process completes, sync with iTunes to transfer all of your apps, music, photos and other media back onto the iPad. -
My iPod doesn't work with iTunes 10. Help please!
Greetings to all!
Help please! I updated to iTunes10, and now my ipod nano 4th generation doesn't work with it. Actually the "Devices" menu doesn't show up, although the operating system recognizes it. What should i do? I refuse to buy another one. Should i install an older version of itunes? If i do so, may i loose my musics and stuff that i have in library?
Thanks a lot in advance.
Laters,You should always have backup of your iTunes folder.
Downgrading to iTunes 9 will not cause you to lose your music etc.
Have you checked via Software Update in the System Preferences for any updates.
Have you tried the 5 R's for the iPod?
MJ
Maybe you are looking for
-
How do i fix my minamize on a mac from a square back to the regular one
how do i fix my minamize thing for my macbook from a little square back to the original one.
-
Excel 2013 crash - related to digital signature?
This is a cross-posting of a thread originally started in Microsoft Answers (Office- Excel) forum, advised to post in this forum by MS support engineer Mohan Suryanarayan (link to other forum: here). I have a VB macro in file A (which otherwise conta
-
My photosmart is printing pink instead of red
When printing from photoshop my printer is printing in pink something that is clearly red. I have cleaned the printhead and there is no change
-
I am having a problem reistalling adobe photoshop elements and premiere 9
I am having a problem reinstalling adobe photoship elements and premiere 9. my laptop had to be re configured and it was removed not i cannot reinstall.? Please help
-
Surrogate identfier at higher levels
Hi I am only able to create surrogate keys at the lowest level of a dimension in OWB10gR2. At the higher levels, I can only create attributes as null or business identifier. Has anybody done this with success, and what did you do ? Thanks in advance.