Hello again
I am using Excel 2007 and I want that some cells and graphs only appear after the user fill some other cells.
How can i do that?
Tks for the help
Hello again
I am using Excel 2007 and I want that some cells and graphs only appear after the user fill some other cells.
How can i do that?
Tks for the help
Last edited by Sonyk; 04-14-2009 at 07:37 AM.
you can use vlook up commnd
could you be more specific please? where is that comand? My excel is not in english
can you attach some sample file with your requirements so that i can write it over there as I'm still confuse .... do you want to link data in other sheet ????
\1
see the jpeg
For example i have a row
1 2 3 4 5 6 7 8 9 TOTAL
I want that ONLY AFTER filling the row, the TOTAL appears
AND
one sheet appears available to see BUT ONLY AFTER filling the cells
Last edited by Sonyk; 04-02-2009 at 06:01 AM.
First part you can do something like:
in O14 put formula:
=IF(COUNT(C14:N14)=10;SUM(C14:N14);"")
And same for rows 15,16 etc...
But for new sheet I don't know. Someone more skilled will help you..
sorry i can't see the file as its blocked by our company. ..............
Suppose you have data in A2:A11 Cells and when ever you'll skip some cells then it will hide sheet2 else will take you to sheet2 .... You can run macro by clicking button ..... I"ll automate you after getting green signal from your side ......
=IF(COUNT(A2:A11)=10,SUM(A2:A10),"FILL")
Sub Macro1()
'
If Range("A12").Value <> "FILL" Then
MsgBox "Now you can see sheet2"
Sheet2.Visible = xlSheetVisible
Sheets("Sheet2").Select
Range("B13").Select
Else
MsgBox "Now sheet2 will be hide "
Sheet2.Visible = xlSheetHidden
Sheets("Sheet1").Select
Range("a12").Select
End If
End Sub
the first part is solved
but the second part:
i have to click the button (CHECK MACRO) for that thing work... I want it to be automatically
sorry for the trouble
Here we are now ....... I've attached the auto sheet ...... you can remove messages boxes from the code as its only for your guideline and further work ........
Private Sub Worksheet_Calculate()
If Range("A12").Value <> "FILL" Then
MsgBox "Now you can see sheet2"
Sheet2.Visible = xlSheetVisible
Sheets("Sheet2").Select
'Range("B13").Select
Else
MsgBox "Now sheet2 will be hide "
Sheet2.Visible = xlSheetHidden
Sheets("Sheet1").Select
Range("a12").Select
End If
End Sub
ok it works in that file but i want it to work on my file, so what i did was (remeber it is the first time i work with excel in my life):
-Visual Basic
-Insert Module
-
Sub Macro1()
If Range("C8").Value <> "" Then - This says that if C8 is in blank then... right?
MsgBox "works"
analise.Visible = xlSheetVisible The sheet i want visible is called analise
Sheets("analise").Select
Range("B13").Select - What does this command?
Else
MsgBox "Now sheet2 will be hide "
analise.Visible = xlSheetHidden
Sheets("APRen").Select - APRen is the first sheet
Range("C8").Select
End If
End Sub
Then I saved and appeared one message box saying that the book dont have permission for Macros BUT IT DOES cause i clicked to allow it
I clicked YES anyway but nothing happened, what am i doing wrong?
In ultimate case, i will edit your sheet and try to see if it can works
thanks very much
i edited your file and was alright, changed the code like i wanted it to be and everythng was smooth but i still dont know how to create more of that, to work with other sheets and cells...
tell me pleae how do you created that macro and how in gods name i make excel quiet about macros and security (i clicked in security macros and still it says that is protected against macros)
First of all allow macro to run thru
Excel Option > Trust Center > Trust Center Setting > Macro Settings > click Enable All Macros ....
Now macros will run on your computer ...
2nd Part ....
Press Alt + F11, Visual basic editor will apear.
on Left side you can see your sheets
Now double click any sheet
on Right side you will see two drop down 1. General 2. Declaration
Click General and accept work sheet
now click on declaration, you will see lot of options
select Calculation and enter the code there. now what ever be the changes it will run ......
what is in red is solved, however, the thing about macros was that i have to save as a "file allowed by macros", although the security was off.
2nd part
i see the drop downs but when i change to General nothing happen. Where is the Calculation thing?
And...
i must place the macro in the code of the specific page right? like you did in your macro
hey man i figured out a easy way for me to do this!
like this:
If Range("m53").Value <> "" Then
MsgBox "now you can see"
Worksheets("sheet2").Visible = True
Sheets("sheet2").Select
Else
MsgBox "now you dont"
Worksheets("sheet2").Visible = False
Sheets("sheet1").Select
End If
End Sub
this works for now but i will run tests before i say it is solved
ok it works great that way i said
thanks for the help
SOLVED
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks