473,671 Members | 2,269 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

how to open the file browser dailog osing button click

15 New Member
Hi Frnds
I am working on c#.
I want the information about to click the button in textbox How to
Open the file browser dailog.
Sep 8 '06 #1
1 2495
angi the dark angel
11 New Member
this is to open a file dialong wiht imae fies

With OpenFileDialog1
.Filter = "(*.BMP;*.JPG;* .JPEG)|*.BMP;*. JPG;*.JPEG|All files (*.*)|*.* "
If .ShowDialog = DialogResult.OK Then
If Not (.OpenFile() Is Nothing) Then
.Title = "Select The Image"
TextBox1.Text = .FileName
TextBox2.Text = .FileName
curfilename = .FileName ' this for the variable
PictureBox1.Ima ge = Image.FromFile( TextBox1.Text)
Else
MessageBox.Show ("No File Selected", "Select a file", MessageBoxButto ns.OK)
End If
End If
End With
Sep 26 '06 #2

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

Similar topics

1
6206
by: Gabriel Froes | last post by:
Hy, I try to open mht file generated by ASP use the Content-Type = "application/msword". When the browser show de "dowload dialog" and I click in the Save button the file open perfectly, but if I try to click in the Open button, the browser show the "downloading dialog" and stay perpetual trying to open the file. My problem is, I cant save the file in the local machine, I need the Open only in memory. tanks.
3
3705
by: VbUser25 | last post by:
hi.. i have a form i accept some user inputs in the form. there is a link on the form from where i open the excel file in the same browser (not in a new page...simply using a href. i am also accepting input from the user in the excel. now i want to save the data in excel as well as on asp form. i can save directly thru vba code in excel to the db. but suppose the
3
3136
by: Leonard | last post by:
I have a button on my web app, that opens a help html page. I use this code: HttpContext.Current.Response.Write("<script>") HttpContext.Current.Response.Write("window.open('" & sUrl & "','_new')") HttpContext.Current.Response.Write("</script>") This works ok, the html page opens in a new browser window, but when I close the help, click on a different menu item in my app, and then click the back button, the help window opens up again....
4
5097
by: John | last post by:
Hi, I generate a report in a comma delimited file and give it a name like MyReport.csv . I then set a Hyperlink control to point tp the file HyperLink1.text = "Download" Hyperlink1.NavigateUrl = "MyReport.csv" When the user clicks the HyperLink I would always like to
2
2936
by: carlor | last post by:
Hi there, I have a form that contains a link button. When the user clicks the link button I need to enable a couple of other buttons on the page and open a new browser window giving it focus (keeping it on top). I have most of it working but I can't get it all working. I can either have the window open and disable the buttons with the new window in the background, or I can have the new window in the foreground but not be able to disable...
6
21400
by: shil | last post by:
I have a server side button that needs to do some preperation and afterwards, if everything goes well, open a new browser with a specific url. I know how to execute javascript from a server side control, adding the javascript to the attributes. I need to open the browser window AFTER the code behind event is finished. For example I have two text boxes on the form, whose values I want to send as parameters to the URL that I want to...
5
1398
by: nashak | last post by:
Hello, I have a aspx page on which I have a button. In the click event method in code-behind I do some processing and now need to open a new window in another browser and pass a couple of parameters. I included in my aspx file, the following js function: function OpenChecklist(strCaseID) {
7
2007
by: jonathandrott | last post by:
sorry newbie question probably. i'm trying to open an specific folder. open each file with in the folder individually and process each one. all the processing code has been written. i'm looking for sample code to open the folder and start grabbing files. thanks.
3
1618
by: premMS143 | last post by:
Hi, I' developing a VB application. When user clicks on 'Tools' option from the Main Form, a dailog box will appear, which is developed using another VB form itself. But while the dailog box is visible in front of Main Form, if user clicks on accidentally the backside appearing Main Form, this Dialog box will goes back which is invisible. But I don't want to this to happen. Until the user responds either OK or CANCEL button in dailog box the...
0
8476
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8393
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8917
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
7437
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6229
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5696
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4225
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2812
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2051
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.