richciccarella
New Member
- Joined
- Oct 18, 2020
- Messages
- 6
- Office Version
- 365
- Platform
- Windows
Hello everyone,
I have been following this forum for a while but this is my first post. I am stuck on my hyperlink code. I want the user to input data into a userform and then that data is saved in column AA2, 3, 4... on sheet userinputlist. Then it creates a sheet with its name. Then on sheet Summary, I want that name to be in A179, 180, 181... with a hyperlink to its page. When the user clicks done, it resets the form to enter a new data with the same procedure. Right now, everything works except the hyperlink is created on whatever cell its currently active on the summary sheet. and two or more inputs just overwrites the first one. This is the code I have. (I didn't include code to setup the page since its pretty long). Thank you in advance for your help.
I have been following this forum for a while but this is my first post. I am stuck on my hyperlink code. I want the user to input data into a userform and then that data is saved in column AA2, 3, 4... on sheet userinputlist. Then it creates a sheet with its name. Then on sheet Summary, I want that name to be in A179, 180, 181... with a hyperlink to its page. When the user clicks done, it resets the form to enter a new data with the same procedure. Right now, everything works except the hyperlink is created on whatever cell its currently active on the summary sheet. and two or more inputs just overwrites the first one. This is the code I have. (I didn't include code to setup the page since its pretty long). Thank you in advance for your help.
VBA Code:
Sheets("UserInputList").Select
Dim EmptyLine As Long
'
'Finds the next empty line
EmptyLine = Worksheets("UserInputList").Cells(Rows.Count, 27).End(xlUp).Row + 1
'Adds the name value
Cells(EmptyLine, 27).Value = TextBox2.Value
'
'
'Finds the next empty line in Summary sheet
Sheets("Summary").Select
Dim EmptyLine3 As Long
'
EmptyLine3 = Worksheets("Summary").Cells(Rows.Count, 1).End(xlUp).Row + 178
'Adds the name value to the empty cell
Cells(EmptyLine3, 1).Value = TextBox2.Value