Previous in Forum: Microsoft Advantage Problems   Next in Forum: MS Excel query
Close
Close
Close
12 comments
Rate Comments: Nested
Member

Join Date: Aug 2008
Posts: 9

Visual Basic - Getting Started

01/08/2009 12:37 AM

hi!!

basically i am a beginner in Visual Basic.

my question is this:-

i have scanned some files on to my computer.i want to develop a program in VB or in VBA that will allow me to open these files whenever i click a button on the form.these files are basically image files(.JPEG)

how do i go about doing this??

any help is greatly appreciated.

Register to Reply
Pathfinder Tags: Visual Basic
Interested in this topic? By joining CR4 you can "subscribe" to
this discussion and receive notification when new comments are added.

Good Answers:

These comments received enough positive votes to make them "good answers".
Guru
United Kingdom - Member - Not a New Member Hobbies - Musician - New Member Hobbies - Fishing - New Member

Join Date: May 2006
Location: Reading, Berkshire, UK. Going under cover.
Posts: 9684
Good Answers: 468
#1

Re: programming in VB

01/08/2009 4:12 AM

Do you want to open the file in a control within your application (e.g. Image or PictureBox control), or with another application (e.g. Paint or Photoshop)?

__________________
"Love justice, you who rule the world" - Dante Alighieri
Register to Reply
Member

Join Date: Aug 2008
Posts: 9
#2
In reply to #1

Re: programming in VB

01/08/2009 12:02 PM

the files consist of a few graphs.

i would like to open them wherever they are seen best.maybe in paint / photoshop.

awaiting your reply.

Register to Reply
2
Guru
United Kingdom - Member - Not a New Member Hobbies - Musician - New Member Hobbies - Fishing - New Member

Join Date: May 2006
Location: Reading, Berkshire, UK. Going under cover.
Posts: 9684
Good Answers: 468
#3
In reply to #2

Re: programming in VB

01/08/2009 6:34 PM

Bit busy at present, but the quick-n-dirty way is to use the shell function.

e.g. (adapted from VB help)

'******************

' Specifying 1 as the second argument opens the application in normal size and gives it the focus.

Dim RetVal

RetVal = Shell("C:\WINDOWS\system32\mspaint.exe mypic.jpg", 1) ' Run Paint, & open mypic.jpg

'******************

I think this'll work, but I haven't tried it - if you're still stuck, I'll see if I've got some time at the weekend to muck about.

__________________
"Love justice, you who rule the world" - Dante Alighieri
Register to Reply Good Answer (Score 2)
Member

Join Date: Aug 2008
Posts: 9
#4
In reply to #3

Re: programming in VB

01/09/2009 12:57 AM

the technique works,

thanks a lot for your help, sir.

Register to Reply
Guru
Popular Science - Weaponology - New Member Netherlands - Member - New Member Fans of Old Computers - Commodore 64 - New Member

Join Date: Sep 2007
Location: Japan
Posts: 2703
Good Answers: 38
#5

Re: Visual Basic - Getting Started

01/09/2009 1:18 AM

answered already, by the way are you using visual basic 6.0 or visual basic net?

__________________
From the Movie "The Big Lebowski" Don't pee on the carpet man!
Register to Reply
Member

Join Date: Aug 2008
Posts: 9
#6

Re: Visual Basic - Getting Started

01/23/2009 2:04 AM

hi there!

1 more question

how can i put minimise and maximise buttons on the form??

Register to Reply
Guru
Popular Science - Weaponology - New Member Netherlands - Member - New Member Fans of Old Computers - Commodore 64 - New Member

Join Date: Sep 2007
Location: Japan
Posts: 2703
Good Answers: 38
#7
In reply to #6

Re: Visual Basic - Getting Started

01/23/2009 2:20 AM
__________________
From the Movie "The Big Lebowski" Don't pee on the carpet man!
Register to Reply
Associate

Join Date: Dec 2008
Posts: 41
#8

Re: Visual Basic - Getting Started

04/23/2009 12:49 AM

Dear friends,

I want visual basic 6 soft free. can you help me.

Register to Reply
Guru
Engineering Fields - Electromechanical Engineering - Technical Services Manager Canada - Member - Army brat Popular Science - Cosmology - What is Time and what is Energy? Technical Fields - Architecture - Draftsperson Hobbies - RC Aircraft - New Member

Join Date: Sep 2006
Location: Clive, Alberta, Canada
Posts: 5916
Good Answers: 204
#10
In reply to #8

Re: Visual Basic - Getting Started

04/23/2009 1:23 AM

for learning purposes,

i recommend using vba in excel, which is free with the program.

anything you learn in that environment is transferable to vb6.

otherwise you asking for help with theft.. good luck

Chris

Register to Reply
Guru
Popular Science - Weaponology - New Member Netherlands - Member - New Member Fans of Old Computers - Commodore 64 - New Member

Join Date: Sep 2007
Location: Japan
Posts: 2703
Good Answers: 38
#11
In reply to #8

Re: Visual Basic - Getting Started

04/23/2009 1:35 AM

Just download visual basic net express edition from microsoft free, it is visual basic the next generation, and it is a big improvement over VB6 considering that it is fom MS

__________________
From the Movie "The Big Lebowski" Don't pee on the carpet man!
Register to Reply
Guru
Engineering Fields - Electromechanical Engineering - Technical Services Manager Canada - Member - Army brat Popular Science - Cosmology - What is Time and what is Energy? Technical Fields - Architecture - Draftsperson Hobbies - RC Aircraft - New Member

Join Date: Sep 2006
Location: Clive, Alberta, Canada
Posts: 5916
Good Answers: 204
#9

Re: Visual Basic - Getting Started

04/23/2009 1:21 AM

this is my favourite vb helper site

http://www.vb-helper.com/index_categories.html

it will give you the code and description for most anything you want to do.

If you have vb6, you can place a button on a form, and either load the jpg directly into the form as the 'form picture', or use a picture box, and load it into that. you can also make a simple file manager with the vb file, dir, and drive controls.. filter the file control for the file type you want (ie. *.jpg)

you will find all the code on the vb-helper site.

Chris.

Register to Reply
Anonymous Poster
#12
In reply to #9

Re: Visual Basic - Getting Started

08/22/2009 5:43 AM

Wheather this is a free site ??

I mean that can I download the files from that site ??

Register to Reply
Register to Reply 12 comments

Good Answers:

These comments received enough positive votes to make them "good answers".
Copy to Clipboard

Users who posted comments:

Anonymous Poster (1); chrisg288 (2); dharam_ver9 (1); Epke (3); JohnDG (2); sargam (3)

Previous in Forum: Microsoft Advantage Problems   Next in Forum: MS Excel query

Advertisement