Visual Basic/vb6.0

Advertisement


Question
hello sir,i am create one excel document.eg.the excel documnt 6 coloum have.A,B,C,D,E,F.i make one visual basic form.the form 3 command button have.now i open excel document at the same time open the visual basic form.first i click first commond button.i want the visual basic first command button click ready the excel document coloum A B,automatic hide,then second button click C,D coloum automatic hide,then third Button click E,F coloum automatic hide.please give me the source code.thank you

Answer
i hope your  question is to open a workbook and depending upon the commandbutton on VBform you want specific columns hidden.

i suppose you know how to open the excel workbook from vb. or is it that you are in excel and using Userforms?

if the former you could add


   Columns("B:C").Select
   Selection.EntireColumn.Hidden = True
etc

i hope you know what you are doing

Visual Basic

All Answers


Answers by Expert:


Ask Experts

Volunteer


Ravindra

Expertise

visual basic application programming from design to access information, sql, engineering and commercial applications. access databases, excel.(VB6) basic questions in vb 2008. Optional: 1)a large number of people want me to do work which takes some time and effort. can do projects in vb 2008. Pl.note that i would like to be paid for such work. 2) if you want me to spend quality time and do special work, i expect to be paid a reasonable price for my time. 3) if you are pleased with my reply you could consider a good amount. 4) you can visit my website http://ravindra.coolpage.biz

Experience

programming since the past 15 years. have completed a large number of projects in Industrial applications, finance,accounts, correspondence. excel macros etc

Education/Credentials
engineering, management degrees.

Past/Present Clients
project work for a Norway company,USA company and a Canadian company completed. Freelance Project work and Teaching. helping programmers with their work
teaching vb

©2014 About.com. All rights reserved.