![]() |
Neurochirurgie minim invazivă
"Primum non nocere" este ideea ce a deschis drumul medicinei spre minim invaziv. Avansul tehnologic extraordinar din ultimele decenii a permis dezvoltarea tuturor domeniilor medicinei. Microscopul operator, neuronavigația, tehnicile anestezice avansate permit intervenții chirurgicale tot mai precise, tot mai sigure. Neurochirurgia minim invazivă, sau prin "gaura cheii", oferă pacienților posibilitatea de a se opera cu riscuri minime, fie ele neurologice, infecțioase, medicale sau estetice. www.neurohope.ro |
VBA-excel
Last Updated: Nov 18 2005 02:32, Started by
marianI
, Nov 14 2005 11:54
·
0

#1
Posted 14 November 2005 - 11:54

salut,
poate e o intrebare tampita,dar sunt incepator Cum pot deschide o pagina de excel din VBA? Edited by marianI, 14 November 2005 - 11:56. |
#2
Posted 15 November 2005 - 03:31

Private Sub Command1_Click() Dim xcl As Excel.Application Set xcl = CreateObject("Excel.Application") If xcl <> "" Then xcl.Workbooks.Add 'adauga un registru la colectie xcl.DisplayAlerts = False End If xcl.Worksheets.Add 'adauga o foaie xcl.Cells(1, 2) = "celula 1,2" ' secventa de mai jos o poti folosi pt cazul in care vrei sa salvezi documentul ' poti deasemenea si redenumi foaia in care lucrezi Dim xlBook As Excel.Workbook Dim xlSheet As Excel.Worksheet Set xlBook = xcl.Workbooks(1) Set xlSheet = xlBook.Worksheets(1) xlSheet.Name = "nume" xcl.Workbooks(1).SaveAs ("c:\MyExcel.xls") xlBook.Close Set xlSheet = Nothing Set xlBook = Nothing ' sfarsit secventa xcl.Visible = True Set xcl = Nothing End Sub obs: tb adaugata referinta al excel |
#3
Posted 15 November 2005 - 07:45

Private Sub Command1_Click() Dim xcl As Excel.Application Set xcl = CreateObject("Excel.Application") If xcl <> "" Then xcl.Workbooks.Add 'adauga un registru la colectie xcl.DisplayAlerts = False End If xcl.Worksheets.Add 'adauga o foaie xcl.Cells(1, 2) = "celula 1,2" ' secventa de mai jos o poti folosi pt cazul in care vrei sa salvezi documentul ' poti deasemenea si redenumi foaia in care lucrezi Dim xlBook As Excel.Workbook Dim xlSheet As Excel.Worksheet Set xlBook = xcl.Workbooks(1) Set xlSheet = xlBook.Worksheets(1) xlSheet.Name = "nume" xcl.Workbooks(1).SaveAs ("c:\MyExcel.xls") xlBook.Close Set xlSheet = Nothing Set xlBook = Nothing ' sfarsit secventa xcl.Visible = True Set xcl = Nothing End Sub obs: tb adaugata referinta al excel |
#4
Posted 15 November 2005 - 08:10

Scuze am copiat postul tau din greseala.Multumesc pt raspuns.Problema este ca am mai incercat asa si nu stiu din ce cauza apare compile error;"user-defined type not defined" referitor la prima linie "Dim xcl As Excel.Application.". SIMT CA INEBUNESC am programul gata si trebuie sa folosesc de aici inainte un soft care preia datele numai in excel.Unde gresesc?Presupun ca este o chestie f simpla,banala.
|
Anunturi
▶ 0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users