on 07-17-2006 6:43 AM
Hi
I want to download a file from my application for that i have used the file download UI element but that file download looks like a link but i want it to look like a button not link for that i tried to change its type property but it don't give me looks like button so please help me out in downloading the file by clicking a button (not link)
Thanks in advance
Hi Ninad,
Insert button, for action handler put something like:
final byte[] content = //get content of the file;
final IWDCachedWebResource resource = WDWebResource.getWebResource(content, WDWebResourceType.<APPROPRIATE_MIME_TYPE>);
try {
final IWDWindow window = wdComponentAPI.getWindowManager().createExternalWindow(
resource.getAbsoluteURL(), "Window title", false);
window.open();
} catch(Exception e) {
wdComponentAPI.getMessageManager().reportException(new WDNonFatalException(e), false);
}
Best reagrds, Maksim Rashchynski.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.