Working with ImportWebPart function I hit a problem where the call would fail with Could Not Import WebPart error. The webpart would import to the page manually so nothing wrong with SafeControls or the actual web-part code.
Nothing in the event log, nothing in the SharePoint log, no debugView trace - nothing.
Ended up working through the code of the web-part, commenting out everything and then re-introducing a section at a time.
Turned out the problem was a ScriptLink reference in the controls declarations. The control wasn't even in use. Removing the ScriptLink control from the web-part allowed Import to work.
Subscribe to:
Post Comments (Atom)
Feedburner RSS
No comments:
Post a Comment