Save and open the remote aspx file on the device
Hello.
IM developing a widget that opens up to a distance of webfilehttp://11.11.11.11/myHtmlPage.aspx. I need it to be available offline that I have but I would like to put the HTML on my SD card.
My question is. How to save the file with all its html and how can I open it so that it opens as a Web page.
Here is a code snippet which does not really. (he opens the file stored on the sd card, all right but with the text http://11.11.11.11/myHtmlPage.aspx instead of the html code that was in the original file
var
filePath = file:///SDCard/myDataFile.html;
function
openFile() {}
blackberry.io.file.readFile (filePath, readFile);
}
function
{saveFile()}
object var blackberry.utils.stringToBlob = blob ('http://11.11.11.11/myHtmlPage.aspx'); ("' saved file");
blackberry.io.file.saveFile (filePath, blob);
}
I think the problem lies in the following snippet:
var blob = blackberry.utils.stringToBlob('http://11.11.11.11/myHtmlPage.aspx');"file saved");
stringToBlob does not have an HTTP request for the value you provide. It turns out some string that is received in a blob object.
You will need to use XmlHttpRequst to make a Web request to the given page and then use the results of this HTTP response in the call to the stringToBlob method.
Does that make more sense?
See you soon!
Adam
Tags: BlackBerry Developers
Similar Questions
-
DW CS6 file save and open the Question
I noticed this glitch in DWCS6 and also Flash CS6, for example, if I crop an image in Photshop and save in a folder, open the folder and see the file inside. Now, I open Dreamwever and go to add the file (which is a jpg file) to an html page. But when I open and navigate to the folder that the file is located in he's not here.
I tried a few times and have no idea why this is.
I'm a Lion as mentioned 10.7 DWCS6 running
any help that slows me down.
RD
Permissions of suffocating, resolved!
-
Windows media player does not automatically open a video file on a Web site but I save it and open the file with Windows media player to play the video or audio recording. I used to be able to play any video or audio file in any site!
Hello
Try resetting the default associations for WMP and IE.
How to set default Associations for a program under Vista
http://www.Vistax64.com/tutorials/83196-default-programs-program-default-associations.html
How to associate a file Type of Extension to a program under Vista
http://www.Vistax64.com/tutorials/69758-default-programs.htmlIf necessary:
How Unassociate a Type of Extension file in Vista - and a utility to help
http://www.Vistax64.com/tutorials/91920-unassociate-file-extention-type.html
Restore the Type Associations by default Vista file extensions
http://www.Vistax64.com/tutorials/233243-default-file-type-associations-restore.html
How to view and change an Extension of filename on Vista
http://www.Vistax64.com/tutorials/103171-file-name-extension.html====================================
Also follow these steps:
Follow these steps to remove corruption and missing/damaged file system repair or replacement.
Run DiskCleanup - start - all programs - Accessories - System Tools - Disk Cleanup
Start - type in the search box - find command top - RIGHT CLICK – RUN AS ADMIN
sfc/scannow
How to analyze the log file entries that the Microsoft Windows Resource Checker (SFC.exe) program
generates in Windows Vista cbs.log
http://support.Microsoft.com/kb/928228Then, run checkdisk - schedule it to run at next boot, then apply OK your way out, then restart.
How to run the check disk at startup in Vista
http://www.Vistax64.com/tutorials/67612-check-disk-Chkdsk.html------------------------------------------------------------
Then, if necessary:
Have you recently installed another player?
Reset your associations for WMP and IE.
How to set default Associations for a program under Vista
http://www.Vistax64.com/tutorials/83196-default-programs-program-default-associations.html
How to associate a file Type of Extension to a program under Vista
http://www.Vistax64.com/tutorials/69758-default-programs.html---------------------------------------------
Do this to reregister the Jscript.dll and Vbscript.dll files.
Start - type in the search box - find command top - RIGHT CLICK – RUN AS ADMIN
type or copy and paste-> regsvr32 jscript.dll
Press entertype or copy and paste-> regsvr32 vbscript.dll
Press enterRestart and if all goes well, it will run now.
--------------------------------------------------------------
Have you recently added stores or ANY application from Stardock?
Using 64-bit Vista?
Can you think of recent things you did in WMP which could be the cause? You added another
reader recently or an add-on for WMP?When I try to use Windows Media Player 11, the program does not start, or some UI elements
are empty - a Mr Fixit
http://support.Microsoft.com/kb/925704/en-usMaybe something here
http://msmvps.com/blogs/chrisl/articles/17315.aspx
and here
http://msmvps.com/blogs/chrisl/Archive/2004/10/30/17399.aspxCheck here the news of WMP11
http://zachd.com/PSS/PSS.htmlI hope this helps.
I hope this helps.
Rob - bicycle - Mark Twain said it is good.
-
I get videos from cell phones of the people with a type of file like 3GP. I need to know how to save and change the format so I can open them.
Trying to convert to the. WMV format:
There are many converters available on the net... some
free... some detail.The following freeware converter is just one example:
(FWIW... it's always a good idea to create a system)
Restore point before installing software or updates)Format Factory (freeware)
http://www.videohelp.com/tools/Format_Factory
(the 'direct link' is faster download)
(the file you want to download is: > FFSetup295.zip<>
(FWIW... installation..., you can uncheck
('all' boxes on the final screens)
(Windows XP / Vista / 7)First, you will need to decompress the file or just open the
Drag > FFSetup295.exe< out="" of="" the="">
and drop it on your desktop. To install left click.Next, after the download and installation of Format
Factory... you can open the program and
left click on the toolbar, the "Option" button and
"Select an output folder to" / apply / OK.
(this is where you find your files after they)
are converted)Drag and drop your video clips on the main screen...
Select "all to WMV" / OK...
Click on... Beginning... in the toolbar...
That should do it...
Good luck...
-
original title: Windows Mail ate my file
I opened a word from Windows Mail document, changed using Word 2007, you press on save and close the document. Now I can not find where he saved. I tried the search function in Vista, but it can not find the file either. I tried to re - open the file in the email, but I just get the original version. Can anyone suggest where it might be?
Thank you very much
Eamonn
Once you open a Word attachment in an email, you must save it to your HARD drive until you make changes. If you do not, the changes are lost, but the original attachment is still with the e-mail.
-
Download the pdf or jpg file and save it on the device for consultation offline
Hello
Publication of an AIR for iOS app via Flash CS5.5, anyone know if it is possible to download a pdf or jpg file and save it on the device for consultation offline?
If so, could you give me some advice on the relevant categories?
Thank you
Mark
Save the content of the loader in byte array, and then send this byte array to FileStream
Something like:
mcLoader = new URLLoader();
mcLoader.dataFormat = URLLoaderDataFormat.BINARY;
var req:URLRequest = new URLRequest (file);
mcLoader.addEventListener (Event.COMPLETE, contentLoaded);
mcLoader.load (req);
private void contentLoaded(e:Event):void {}
var dataContent:ByteArray = new ByteArray();
dataContent = e.target.data;
var fileName:String = "mylocal.pdf".
var f: File = File.applicationStorageDirectory.resolvePath (fileName);
Save the file in the local space
If (f.exists == false) {}
trace ("file does not exist. Record file');
var fs:FileStream = new FileStream();
FS. Open (f, FileMode.WRITE)
fs.writeBytes (dataContent);
FS. Close();
trace ('saved');
}
}
-
I export to PDF, but can't seem to download and open the PDF files. I need to download something?
Hi Lisa,
To download PDF files, you have nothing else except a web browser.
However, to open the pdf file that is downloaded, you certainly need to download Acrobat Reader: Adobe - Adobe Acrobat Reader DC DistributionKind regards
Rahul
-
Hi im quite new for first pro and I'm having a problem when I opened my project and it is unable to locate the files. I find the files that are 'missing' and open the project. Everytime I open the project everything I see is all that media have these red, pink, blue, green, yellow lines, where pictures should be. And there is also the title of my pictures in the upper left corner. No one knows what it is and how I could fix this?
[title published by mod]
[Please do not double post, deleted the other]
Right-click on the images in the project window: recharge or replace it.
-
Original title: day after my laptop was vista2012 virus
my laptop was vista2012 virus, I managed to get rid of him remove the registry concerned (that I found on a website), since then im even worse problems. program what ever I try and open the request for the program to open with, and even internet Explorer does not work? I tried restoring the system from the back to the top, but they have been erased any help?
Hi Jarnold55,
Method 1: Run the fixit available in the article below and then check if it makes a difference
When you run an .exe on a Windows Vista-based or Windows 7 computer file, the file may start another program
http://support.Microsoft.com/kb/950505
Important This section, method, or task contains steps that tell you how to modify the registry. However, serious problems can occur if you modify the registry incorrectly. Therefore, make sure that you proceed with caution. For added protection, back up the registry before you edit it. Then you can restore the registry if a problem occurs. For more information about how to back up and restore the registry, click on the number below to view the article in the Microsoft Knowledge Base.
How to back up and restore the registry in WindowsMethod 2: Run Microsoft Security scanner (MSS) to remove the infection rest of the computer
http://www.Microsoft.com/security/scanner/en-us/default.aspx
Note: Infected files can be deleted from your computer; There is a chance of data loss.
-
Windows 7 64 bit
I want desperately to upgrade Firefox to version 10 of version 9, but whenever I try, I'm stuck with FF10 control addons for compatibility and opening the homepage whenever I starts the browser. I keep having to go back to version 9 to solve this problem.Sorry to be a while back! It tried unsuccessfully so this AM, gritted my teeth and deleted the FF programs folder and downloaded and installed FF 10.01. He was still struggling with the same problem. Went in the appdata folder and two files sessionstore.js there. Delete both, restarted the browser and no verification of the compatibility of the modules was done at first upward and the additional tab for welcome to FF was the opening is no longer all seems to work as it should and I did not lose any of my settings... Thanks for trying to help, and I hope that my solution helps someone else who could this experience in the future. Hoping that the next update will smoother!
-
I have windows 7 when I right click on my desktop and open the Customize says error unspesified
I have windows 7 when I right click on my desktop and open the Customize says error unspesified
Hi Marion,
Thanks for posting your question in the Microsoft Community.
I imagine the inconvenience that you are experiencing. I will certainly help the question of fixing.
To help you suggest several steps to solve the problem, I would appreciate if you could answer the following questions:
1 have you ever done any recent hardware or exchange of software on your computer before the show?
2. What is the error message that is accurate or complete?
Please follow the methods and mark the question below:
Method 1:
You need to perform a clean boot to prevent any third party conflicting application from interfering with your computer.
To put the computer in a clean boot state, you must follow the steps in the article mentioned below and check with the question.
How to troubleshoot a problem by performing a clean boot in Windows Vista or Windows 7:
http://support.Microsoft.com/kb/929135Note: You must follow step 3 of the article mentioned above to recover your computer to a Normal startup after you complete all the steps.
Method 2:
Scan your computer by using the Microsoft Safety Scanner by clicking Download now to check if there is no virus infected:
http://www.microsoftsafetyscanner.com/
Note: The data files that are infected must be cleaned only by removing the file completely, which means that there is a risk of data loss.
Method 3:
I suggest you to perform SFC (System File Checker) analyze and check if TI the problem persists. To do this, please see the following article.
The SFC/SCANNOW command analyzes all protected system files and replaces incorrect versions with appropriate Microsoft versions and troubleshoots missing or damaged system files in Windows.
For more information how to make SFC / scan, please follow this link:
How to use the System File Checker tool to fix the system files missing or corrupted on Windows Vista or Windows 7:
http://support.Microsoft.com/kb/929833
Method 4:
Try to create a new user account and see if the problem still occurs because the user account might have corrupted.
Create a user account:
http://Windows.Microsoft.com/en-in/Windows7/create-a-user-account
If the new user account works fine without any problem, then follow the link below to fix a corrupted user profile and transfer your data from the old account to the new account files.
The difficulty of a user profile is corrupted:
http://Windows.Microsoft.com/en-us/Windows7/fix-a-corrupted-user-profile
Your response is very important for us to ensure a proper resolution. Please get back to us with the information above to help you accordingly.
-
My students use the filling and the signature on a package of .pdf tool I'm going to fill them, but when they record and open the next day their text boxes, that they created with the bucket fill tool and sign all went and many are overlapping.
Hi chbradshaw,
Instead of filling & signature, tool, use the text comment comment tool, KB doc option. using comments in the PDF, Adobe Acrobat DC files (keyword: Add a text comment).
Kind regards
Nicos
-
I've just updated the 13.0.1 and immediately noticed on www.rottentomatoes.com when you hold down the control key and click with the mouse it not only opens a new tab with this link which is what I want. It also opens the link in the tab that I've watched. Now the SHIFT key to launch the link in a new session did the same thing. Launches the new session and opens the link in the existing session.
I'm looking at this particular site:
http://www.rottentomatoes.com/top/bestofrt/?year=2011Excessive use of unnecessary spaces is there in the code of the page.
It happens in Firefox 3.6.x and Google Chrome as well.
-
In outlook express when receiveing an email he has highlighted in the email and opens the content. How can I stop it opening in case there is a virus. I want to delete something which I think is a problem. I can't find a way to stop this. I want to double click to open only e-mail I recognize
original title: outlook express 6Go to view | Layout and turn off the preview pane. You can then double-click to open it.
Steve
-
Win 7 bypass login screen and opens the local administrator account
Having a laptop computer on the school network. During the initialization of the logon screen is bypassed, and opens the local administrator account, which is not well with the children concerned. Even in Safe Mode. Laptop configured from an image by using Hyper-V, all others ok
Hello
Thanks for the reply.
If you have any other questions relating to computers on the domain network, you can post questions in the Forums TechNet Networking Windows 7: http://social.technet.microsoft.com/Forums/en-US/w7itpronetworking/threads
Thank you.
Maybe you are looking for
-
Keyboard no longer works in the terminal until I click the mouse in the OSX terminal
Somehow the last week I have big fingers something while working in a terminal and the keyboard does not show anything when I type until I click on the mouse button. I tried the reset command, but it does not solve the problem. It's so weird, I don't
-
Why doesn't firefox displays correctly icons in websites such as github and great police?
I use firefox on linux (opensuse 12.3) 20 and it does not display correctly some site...What it looks like: Great police https://www.dropbox.com/s/fyfvrjvsgp6wnyy/font%20Awesome%2c%20The%20iconic%20font%20designed%20For%20Bootstrap%20-%20Chromium.PNG
-
My computer seems to hang because the screen went black. I had to do a hard reboot by using the power button. What I get is a grey screen with a cursor. I tried to start in safe mode, or at least, I think that I did by holding down the SHIFT key whil
-
When I cut or copy a photo jpg, dough, it then becomes a "scrap" file that cannot be opened. This can be corrected? * original title - what makes an average of file scrap.shs *.
-
Bengali fonts problem in Windows
Hello I am from Bangladesh. Until recent years, we were quite used to do everything in the internet in English. But things have changed a lot now there are a lot of sites on the web in our own language. People really like read and write in Bengali in