Click here to Skip to main content
15,843,145 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
good day please i have four buttons please i want them to fetch data from the database to a textbox and also the image to show in the picturebox. And can a textbox be non editable, that a user cannot edit a textbox.thanks

What I have tried:

i haven't tried anything i only know how to use the datagridview
Posted
Updated 22-Oct-17 21:24pm

Quote:
can a textbox be non editable
Yes - set the ReadOnly property to true: TextBoxBase.ReadOnly Property (System.Windows.Forms)[^]

We can't tell you how to do the buttons, or display an image exactly - we don't know what your DB contains, or even what type of DB it is (and there are many). But the basics of accessing a DB and retrieving an image are here: Why do I get a "Parameter is not valid." exception when I read an image from my database?[^]
It shows the basic code to fetch an image from an SQL Server DB (the others will be very similar)
 
Share this answer
 
Comments
akinwunmi 22-Oct-17 20:11pm    
i am using sql database

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900