Hi,
I have a question about tool tip in RadUpload. After selecting a file and putting mouse over a text box, a tool tip with file name is displayed. I'd like to change this text(text should be dependent on selected file name ) or disabled this functionality. Is it possible ?
I have a question about tool tip in RadUpload. After selecting a file and putting mouse over a text box, a tool tip with file name is displayed. I'd like to change this text(text should be dependent on selected file name ) or disabled this functionality. Is it possible ?
5 Answers, 1 is accepted
0
Shinu
Top achievements
Rank 2
answered on 14 Jun 2010, 02:11 PM
Hello Diana,
You can use OnClientFileSelected event of RadUpload to change the Tooltip text. Check out the following code snippet.
ASPX:
Java Script:
Regards,
Shinu.
You can use OnClientFileSelected event of RadUpload to change the Tooltip text. Check out the following code snippet.
ASPX:
<telerik:RadUpload ID="RadUpload1" runat="server" OnClientFileSelected="checkExtension"> |
</telerik:RadUpload> |
Java Script:
<script type="text/javascript"> |
function checkExtension(radUpload, eventArgs) { |
radUpload._fileInput.title = "tooltip"; |
} |
</script> |
Regards,
Shinu.
0
Diana
Top achievements
Rank 1
answered on 23 Jun 2010, 12:07 PM
Hi,
This solution didn't solve a problem completely - there is still a problem in IE8. I setted tootip on empty string (radUpload._fileInput.title = ""). Generally it works ok, but sometimes, full path is showed instead of empty text (I can't tell, when it is happened). There is one really strange bug - full path is showed always, when mouse is over bottom border of text box. Can you solve this problem ?
This solution didn't solve a problem completely - there is still a problem in IE8. I setted tootip on empty string (radUpload._fileInput.title = ""). Generally it works ok, but sometimes, full path is showed instead of empty text (I can't tell, when it is happened). There is one really strange bug - full path is showed always, when mouse is over bottom border of text box. Can you solve this problem ?
0
Hello Diana,
You can use the following JavaScript to workaround this problem:
Sincerely yours,
Genady Sergeev
the Telerik team
You can use the following JavaScript to workaround this problem:
function
clientFileSelected(sender, args) {
var
$ = $telerik.$;
var
parent = args.get_fileInputField().parentNode;
$(
".ruFakeInput, .ruFileInput"
, parent)
.attr(
"title"
,
"test"
);
}
<
telerik:RadUpload
runat
=
"server"
ID
=
"RadUpload1"
MaxFileInputsCount
=
"1"
ControlObjectsVisibility
=
"None"
OnClientFileSelected
=
"clientFileSelected"
>
Sincerely yours,
Genady Sergeev
the Telerik team
Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Public Issue Tracking
system and vote to affect the priority of the items
0
Diana
Top achievements
Rank 1
answered on 05 Jul 2010, 09:17 AM
In my application I used Telerik in version 2008.3.1105.35. Solution from your post doesn't work for this version - it gives javascript errors. Is it possible to solve this problem for this older version ?
0
Hi Diana,
The version of the controls that you use does not have jQuery hence the issue that you experience. This is the same code without jQuery (it should work with the version that you use)
Sincerely yours,
Genady Sergeev
the Telerik team
The version of the controls that you use does not have jQuery hence the issue that you experience. This is the same code without jQuery (it should work with the version that you use)
<
script
type
=
"text/javascript"
>
function clientFileSelected(sender, args) {
var parent = args.get_fileInputField().parentNode;
parent.childNodes[0].title = "test";
parent.childNodes[1].title = "test";
}
</
script
>
<
telerik:RadUpload
runat
=
"server"
ID
=
"RadUpload1"
OnClientFileSelected
=
"clientFileSelected"
>
</
telerik:RadUpload
>
Sincerely yours,
Genady Sergeev
the Telerik team
Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Public Issue Tracking
system and vote to affect the priority of the items