on 03-22-2006 9:43 AM
Hai,
In my webdynpro application , I need a control when i click on the control i need to connect to a html file.
whch control is better linktourl OR linktoaction.
when i click on this link i need to open the html file in another window.
please help me.
regards,
Naga,
If your resource is static and located in component "mimes" folder or this is just a pointer to external web site, then it is better and simpler to use IWDLinkToUrl directly.
If this is a reference to externally hosted document, then just set "reference" attribute directly. If this is HTML file in "mimes" folder, then bind this link "reference" to context attribute, say Url, and write something like this in wdDoInit of view controller:
try
{
wdContext.currentContextElement().setUrl
(
WDURLGenerator.getAbsoluteWebResourceURL
(
wdComponentAPI.getDeployableObjectPart(),
"my-file.html"
);
);
}
catch (final WDURLException ex)
{
wdComponentAPI.getMessageManager().reportException
(
new WDNonFatalException(ex), false
);
}
In both cases set "target" of IWDLinkToUrl to "_BLANK"
Use code from my blog only if you have to display HTML content from some dynamic source (database, RFC call result, dynamically created by application etc.)
Valery Silaev
EPAM Systems
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Naga,
Check Valery`s nice blog /people/valery.silaev/blog/2005/11/23/display-formatted-text-using-webdynpro-for-java describing similar issue.
Best regards, Maksim Rashchynksi.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
25 | |
12 | |
9 | |
6 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.