473,417 Members | 1,414 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,417 software developers and data experts.

How to store only imagefile name in database table

11
hi
i m using radiobuttonlist with images like this
Expand|Select|Wrap|Line Numbers
  1. <asp:RadioButtonList ID="rbtnthumb1"   runat="server">
  2.     <asp:ListItem  Value ="News_icon.jpg"> 
  3.         <img src="http://bytes.com/images/News_icon.jpg" alt="News" align="absmiddle"> 
  4.         News
  5.     </asp:ListItem>
  6.     <asp:ListItem  Value ="imageicon.bmp">
  7.       <img src="http://bytes.com/images/imageicon.bmp" alt="Image" align="absmiddle">
  8.       Image
  9.     </asp:ListItem>
  10.     <asp:ListItem Value ="Video97.gif" >
  11.       <img src="http://bytes.com/images/Video97.gif" alt="Video" align="absmiddle">
  12.       Video
  13.     </asp:ListItem>
  14. </asp:RadioButtonList>
In design view it show radiobuttonlist with images but when i use insert query.it stored this value in mytable
Expand|Select|Wrap|Line Numbers
  1. <img src="http://bytes.com/images/News_icon.jpg" alt="News" align="absmiddle"> 
  2. News
but i only want to store News_icon.jpg(image file name)and i m using this way for adding value
Expand|Select|Wrap|Line Numbers
  1.         cmd.Parameters.AddWithValue("@ChooseThumbnail", rbtnthumb1.SelectedItem.Text)
please let me know how to store only imagefile name in database table

regard's
Nov 11 '09 #1

✓ answered by Frinavale

Well, your application is doing exactly what you told it to do.

It's taking the "Text" property of the SelectedItem...and this happens to be the HTML for the Image along with the Text that you are displaying for the item.


What you should be using is the RadioButtonList's SelectedValue property instead.

Happy coding,

-Frinny

2 2437
Frinavale
9,735 Expert Mod 8TB
Well, your application is doing exactly what you told it to do.

It's taking the "Text" property of the SelectedItem...and this happens to be the HTML for the Image along with the Text that you are displaying for the item.


What you should be using is the RadioButtonList's SelectedValue property instead.

Happy coding,

-Frinny
Nov 11 '09 #2
gm000
11
thanks for guiding its working
Nov 12 '09 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Christopher Brandsdal | last post by:
Hi! I have a delicatg problem.... I have made a registration form for adding my friends information in a database. The problem is that I want to connect the persons with companies in the same...
5
by: Roy Gourgi | last post by:
Hi, I am used to working in Visual FoxPro and I would like to be able to create a database and store and retrieve information from it. What is the simplest way to do it and what should I be...
11
by: c676228 | last post by:
Hi everyone, I am just wodering in asp program, if there is anybody writing store procedure for inserting data into database since there are so many parameters need to be passed into store...
4
prabunewindia
by: prabunewindia | last post by:
Hello everybody, here i am going to explain, how to get mails from Outlook express database and store in our own database(local) Initially you have to add the refference Outlook library10.0 or...
3
by: M.-A. Lemburg | last post by:
On 2008-08-07 20:41, Laszlo Nagy wrote: 1 It also very fast at dumping/loading lists, tuples, dictionaries, floats, etc. -- Marc-Andre Lemburg eGenix.com
4
elen
by: elen | last post by:
hi! I wish for your help! I have a form and i want to store the results to my database and show me back what i sent to database,but my php script won't work.Can somebody help me ?I'm new in php ...
2
by: jelle79 | last post by:
Hi all, I'm storing all kind of data stored in objects. Now I want to query my data-source. And I thought LINQ is the right thing for it. Data is stored like: store.Database Queries like...
2
by: Silfheed | last post by:
Heyas So I've been messing around with the PIL and PNG's and came across a little problem with PNG's. So just to clarify, I'm running with the standard ubuntu 8.04 python- imaging package...
8
by: ahilar12 | last post by:
Hi experts, I have a form with many textboxes,listboxes in php.I have a edit button to edit the values in the form.once i click the edit button the existing values should be displayed so that...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.