+ Start a Discussion
MaxxumMaxxum 

Bad Link Definition ERROR while saving S-Control - Please help

Does any one know what this means?

Message Edited by Maxxum on 08-22-2005 08:21 AM

DevAngelDevAngel
I think this has something to do with the syntax of the scontrol.  Make sure that it is well formed html, especially if you are using any embed tags.
MaxxumMaxxum
Surprisingly, when I try to create a new s-control by copyint HTML code from one of the existing s-controls, I get the same error.
I am unable to save the existing control as well. I just tried a simple change to the exsting code and tried to save it.
Does it have anything to do with the sice?
DevAngelDevAngel
????
MaxxumMaxxum
DevAngel,

In your first post you had mentioned:



DevAngel wrote:
I think this has something to do with the syntax of the scontrol. Make sure that it is well formed html, especially if you are using any embed tags.



What I am trying to say is that when I tried to create a new s-control using HTML code save in existing s-control, I got the same error. Now since the previous s-control was saved successfully, I don't think there was any issue with the HTML.

Hence I asked the question - can size of the HTML code cause this error. The s-control that I have is very big.
DevAngelDevAngel

It is very possible that this is the case.  I don't know what the maximum size is.

You can place a lot of your javascript into a separate file and upload the file as part of the scontrol.  You would need to add a script tag to reference this file.  The tag is

<script src="{!{!Scontrol_URL}" type="text/javascript"></script>

PKDevGuyPKDevGuy

Hi, let me correct that URL:

<script src="{!Scontrol_URL}" type="text/javascript"></script>

and qualify what "a lot of" means. By trial and error, I've discovered that you can't include any jscript that has {!variable} callouts. This hasn't been a problem for me so far; I have a single initpage() function which contains any such variables that need to be referenced, and I use

<body onload="initPage();">

to kick things off.

  - Mike

JoyceJoyce

Maxxum,

Try this - it will work.  Enter only a few HTML tags into the body like

<html>
<head>
<script type="text/javascript">

</body>
</html>

Save it, then go back Edit the SControl, and add the original code.   This worked for me and the only way I could create one of my controls

MarkerVMarkerV
Not sure if anyone is still reading these, but I encountered this issue and resolved it by fixing one of my tags:

My  {!Contact_HomePhone} should have been {!Contact_HomePhone1} - I had my field name typed wrong.

that change adding "1" resolved it.