Forum Discussion
Create a new table selecting info from an existing table in Excel vba
- Dec 11, 2020
The major problem: you changed cmdCancel_Click to cmdCancel_Click3 and cmdOK_Click to cmdOK_Click3. That won't work: Click is the name of the event, you can't just change that.
Other problems: the headers are now in row 1 instead of row 2, and your column offsets for the context and activity were off by 1.
See the attached version.
Okay! Starting to understand better! This code is really impressive and cool.
I tried it on my new worksheet (because I had to add things) (and adapting the code to it), but when I select the languages, nothing happens. I don't even get an error message. There is just nothing.
In the file attached to this message, there are the headers I am using and their positions in the worksheet. I thought I changed everything I needed to make it work, but does not seem to give me results.
Do you think you could have a look at the changes I made to your code and identify what I've missed?
I marked all the changes in green with this " ' "
Cheers!
The major problem: you changed cmdCancel_Click to cmdCancel_Click3 and cmdOK_Click to cmdOK_Click3. That won't work: Click is the name of the event, you can't just change that.
Other problems: the headers are now in row 1 instead of row 2, and your column offsets for the context and activity were off by 1.
See the attached version.
- dfhidromodMar 11, 2021Copper Contributorit does! thank you!!
- HansVogelaarDec 18, 2020MVP
Hopefully, this works better.
- dfhidromodDec 18, 2020Copper Contributor
okay, I see! thanks for the explanation!
Another last thing, do you know how to define the width of the 2nd column in the new sheet created?
Because, i get super wide columns and the text does not fit in it.
Attached, there is a picture illustrating better what I'm trying to explain.
All the best,
Déborah