Skip to main content

Conas ainm cluaisín bileog a dhéanamh cothrom le luach cille in Excel?

I roinnt cásanna, b’fhéidir go mbeidh ort bileog oibre a athainmniú bunaithe ar luach cille sonraithe. San Airteagal seo, taispeánfaimid duit modhanna chun ainm cluaisín bileog a dhéanamh cothrom le luach cille in Excel.

Déan ainm cluaisín bileog cothrom le luach cille le cód VBA
Déan ainm cluaisín bileog atá cothrom le luach cille le Kutools for Excel


Déan ainm cluaisín bileog cothrom le luach cille le cód VBA

Leis an gcód VBA seo a leanas, is féidir leat ainm cluaisín bileog atá cothrom le luach cille a dhéanamh go huathoibríoch.

1. Cliceáil ar dheis ar an táb bileog ar mhaith leat ainm na bileoige a dhéanamh comhionann le luach cille, ansin cliceáil Féach an cód ón roghchlár cliceáil ar dheis. Féach an pictiúr:

2. Cóipeáil agus greamaigh an cód thíos i bhfuinneog an Chóid, agus ansin brúigh Eile + Q eochracha ag an am céanna chun an fhuinneog Microsoft Visual Basic for Applications a dhúnadh.

Cód VBA: Déan cluaisín bileog cothrom le luach cille

Private Sub Worksheet_Change(ByVal Target As Range)
'Updated by Extendoffice 20230130
    On Error Resume Next
    If Not Intersect(Target, Range("A1")) Is Nothing Then
        ActiveSheet.Name = ActiveSheet.Range("A1")
    ElseIf Not Intersect(Target.Dependents, Range("A1")) Then
        ActiveSheet.Name = ActiveSheet.Range("A1")
    End If
End Sub

nótaí: Sa chód, is é A1 an chill ina bhfuil an luach a chaithfidh tú a úsáid mar ainm bileog. Is féidir leat é a athrú de réir mar is gá duit.

As seo amach, nuair a athrófar an luach i gcill A1, athrófar ainm an chluaisín leatháin go cothrom freisin.


Déan ainm cluaisín bileog atá cothrom le luach cille le Kutools for Excel

Sa chuid seo, tugaimid an Athainmnigh Bileoga Oibre Il fóntais de Kutools le haghaidh Excel. Leis an bhfóntas seo, is féidir leat bileoga oibre le luach cille áirithe in Excel a athainmniú go héasca.

Roimh iarratas a dhéanamh Kutools le haghaidh Excel, Le do thoil é a íoslódáil agus a shuiteáil ar dtús.

1. cliceáil Kutools Plus > Bileog Oibre > Athainmnigh Bileoga Oibre Il. Féach an pictiúr:

2. Sa Athainmnigh Bileoga Oibre Il bosca dialóige, ní mór duit a dhéanamh mar a leanas.

1). Seiceáil ainmneacha na mbileog oibre is mian leat a athainmniú sa Bileoga oibre bosca (is féidir leat bileog amháin nó bileoga iolracha a roghnú).
2). Roghnaigh Cuir ainm an bhileog bhunaidh in ionad bosca sa Athainmnigh Roghanna alt seo.
3). Más mian leat bileog oibre nó bileoga oibre iolracha a athainmniú le luach sonraithe cille, roghnaigh an Ó raon sonrach rogha, agus roghnaigh an raon cealla ar mhaith leat na bileoga a athainmniú bunaithe ar.
4). Cliceáil ar an OK cnaipe. Féach an pictiúr:

Feiceann tú go n-athainmnítear na bileoga oibre roghnaithe de réir an luacha raon sonraithe díreach mar atá thíos an pictiúr a thaispeántar.

nótaí:

1. Is féidir leat an scagairí feidhm chun an bhileog oibre riachtanach a scagadh go héasca má tá go leor bileoga oibre ann.
2. Más mian leat iliomad bileoga oibre a athainmniú le luach cille áirithe i ngach bileog. Mar shampla, beidh bileog1 cothrom le luach a chill A1, agus beidh bileog2 cothrom le luach a chill A1 freisin. Roghnaigh bileoga oibre sa Bileoga oibre bosca, ansin roghnaigh an Athainmnigh bileoga oibre le cill ar leith rogha, agus sonraigh cill A1 sa bhosca.

3. Ní athrófar ainm na bileoige go huathoibríoch leis na hathruithe ar luach na cille.

  Más mian leat triail saor in aisce (30 lá) a bheith agat ar an bhfóntas seo, cliceáil le do thoil chun é a íoslódáil, agus ansin téigh chun an oibríocht a chur i bhfeidhm de réir na gcéimeanna thuas.


Déan ainm cluaisín bileog atá cothrom le luach cille le Kutools for Excel

Uirlisí Táirgiúlachta Oifige is Fearr

🤖 Kutools AI Aide: anailís sonraí a réabhlóidiú bunaithe ar: Forghníomhú Chliste   |  Gin Cód  |  Cruthaigh Foirmlí Saincheaptha  |  Anailís a dhéanamh ar Sonraí agus Cairteacha a Ghin  |  Feidhmeanna Kutools a agairt...
Gnéithe Coitianta: Faigh, Aibhsigh nó Aithnigh Dúblaigh   |  Scrios Sraitheanna Bána   |  Comhcheangail Colúin nó Cealla gan Sonraí a Chailleadh   |   Babhta gan Foirmle ...
Cuardaigh Super: Ilchritéir VLookup    VLookup Illuachanna  |   VLookup Trasna Ilbhileoga   |   Amharc doiléir ....
Liosta anuas Casta: Go tapa Cruthaigh Liosta Anuas   |  Liosta anuas Cleithiúnach   |  Liosta Buail Isteach Ilroghnacha ....
Bainisteoir Colún: Cuir Líon Sonrach Colún leis  |  Colúin Bog  |  Scoránaigh Stádas Infheictheachta na gColún Ceilte  |  Déan comparáid idir Raonta & Colúin ...
Gnéithe Réadmhaoin: Fócas Eangaí   |  Amharc Dearaidh   |   Barra Mór na Foirmle    Leabhar Oibre & Bainisteoir Bileog   |  Leabharlann Acmhainní (Uaththéacs)   |  Piocálaí Dáta   |  Comhcheangail Bileoga Oibre   |  Criptigh/Díchriptigh Cealla    Seol Ríomhphost trí Liosta   |  Scagaire Super   |   Scagaire Speisialta (scagaire trom/iodálach/stailc tríd...) ...
Barr 15 Uirlisí12 Téacs uirlisí (Cuir Téacs, Bain Carachtair,...)   |   50 + Cairt cineálacha (Cairt Gantt,...)   |   40+ Praiticiúil Foirmlí (Ríomh aois bunaithe ar lá breithe,...)   |   19 Insertion uirlisí (Cuir isteach Cód QR, Ionsáigh Pictiúr ón gCosán,...)   |   12 Tiontú uirlisí (Uimhreacha le Focail, Comhshó Airgeadra,...)   |   7 Cumaisc & Scoilt uirlisí (Sraitheanna Comhcheangail Casta, Cealla Scoilt,...)   |   ... agus eile

Supercharge Do Scileanna Excel le Kutools le haghaidh Excel, agus Éifeachtúlacht Taithí Cosúil Ná Roimhe. Kutools le haghaidh Excel Tairiscintí Níos mó ná 300 Ardghnéithe chun Táirgiúlacht a Treisiú agus Sábháil Am.  Cliceáil anseo chun an ghné is mó a theastaíonn uait a fháil ...

Tuairisc


Tugann Tab Oifige comhéadan Tabbed chuig Office, agus Déan Do Obair i bhfad Níos Éasca

  • Cumasaigh eagarthóireacht agus léamh tabbed i Word, Excel, PowerPoint, Foilsitheoir, Rochtain, Visio agus Tionscadal.
  • Oscail agus cruthaigh cáipéisí iolracha i gcluaisíní nua den fhuinneog chéanna, seachas i bhfuinneoga nua.
  • Méadaíonn do tháirgiúlacht 50%, agus laghdaíonn sé na céadta cad a tharlaíonn nuair luch duit gach lá!
Comments (30)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
Good
It was the same thing I was looking for. But now I have a question:
After these steps were done, I created several sheets, I locked the sheet, but when I lock the book and enter a value in the cell, the name of the sheet does not change. In other words, it only changes with the spreadsheet unlocked and I would like to keep the spreadsheet locked
This comment was minimized by the moderator on the site
Boas
Era mesmo isto que estava a procurar. Mas agora tenho uma questão:
Após esses passos feitos, criei várias sheet, bloqueei a folha, mas quando bloqueio o livro e digito um valor na célula, o nome da sheet não muda. Ou seja, só muda com a sheet desbloqueada e gostaria de manter a sheet bloqueada
This comment was minimized by the moderator on the site
bonjour,
que voulez-vous dire par appuyer autre autre+q dans le code vba après avoir collé.
J'ai simplement fermé la page après avoir collé et ça ne marche pas
merci
This comment was minimized by the moderator on the site
worked beautifully!
This comment was minimized by the moderator on the site
Hi Crystal,

When i paste in your code it comes back with error "user-defined type not defined"?

Thanks.
This comment was minimized by the moderator on the site
Hi Tom J,
Make sure these three options are checked in the References - VBAProject dialog box.
https://www.extendoffice.com/images/stories/comments/comment-picture-zxm/error.png
This comment was minimized by the moderator on the site
This worked perfectly for my first worksheet, but not for the second or third etc (I have up to about 20 worksheets that all need this function). Am I missing something?
This comment was minimized by the moderator on the site
Hi A Owen,
This code only works for one worksheet per time. Sorry for the inconvenience.
This comment was minimized by the moderator on the site
What is the highest nr of worksheets, that can be changed names via Kutools Plus? because the excel letting me only 17 names to changes, and that's it
This comment was minimized by the moderator on the site
I'm using your exact code from the above for VBA code which works perfectly for what I need. However, I have a bunch of macros on a sheet called Job Template that gets copied and reused for every new job. I designed all my macros based on a new copied version called Job Template (2). Once the sheet name is changed to the new job name, the macros no longer work and have to manually do it. I would like to be able to use any of my Macro buttons at any point instead of only using them before I change the sheet name.

Is there a way for the VBA code to always refer to the sheet name before running the rest of the code functions?
This comment was minimized by the moderator on the site
How can I reference two cells. for example name and id number?
This comment was minimized by the moderator on the site
This is exactly what I need, but I need the tab to recreate a date and it isn't working... I assume this is something to do with the way excel works out date and time, can anyone suggest a workaround?
This comment was minimized by the moderator on the site
Hi Nick,
Excel does not support typing the sheet name containing special characters. If the date you type contains the character /, it won't allow you to create the sheet name with that date.
There are no comments posted here yet
Load More
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations