1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42
|
Imports OXL = Microsoft.Office.Interop.Excel
Imports System.IO
Imports System.Data.OleDb
Imports System.Math
Public Class Formcomp1m
Dim ValUCDVA1M, ValS1M, ValUCNVA1M, ValC1M, ValA1M, ValK11M, ValK21M, ValQI1M, ValUCDVA1M2, ValUCNVA1M2, ValS1M2, ValC1M2, ValA1M2, ValK11M2, ValK21M2, ValQI1M2 As Double
Private AppExcel As OXL.Application
Private xlWorkbook As OXL.Workbook
'feuille 1
Private xlWorkSheetThree As OXL.Worksheet
Private appPath As String = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)
Private Sub Formcomp1m_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
DecimalSeparator = Application.CurrentCulture.NumberFormat.NumberDecimalSeparator
UCDVA1M.Text = String.Format("{0:0.00}", ValUCDVA1M2)
UCDVA1M.Refresh()
UCDVA1M.BackColor = Color.Purple
End Sub
Private Sub UCDVA1M_GotFocus(ByVal sender As Object, ByVal e As System.EventArgs) Handles UCDVA1M.GotFocus
UCDVA1M.Text = String.Format("{0:0.00}", ValUCDVA1M2)
UCDVA1M.Refresh()
UCDVA1M.BackColor = Color.Purple
End Sub
Private Sub UCDVA1M_LostFocus(ByVal sender As Object, ByVal e As System.EventArgs) Handles UCDVA1M.LostFocus
UCDVA1M.BackColor = Color.LightSlateGray
End Sub
Private Sub UCNVA1M_GotFocus(ByVal sender As Object, ByVal e As System.EventArgs) Handles UCNVA1M.GotFocus
UCNVA1M.Text = String.Format("{0:0.00}", ValUCDVA1M2)
UCNVA1M.Refresh()
UCNVA1M.BackColor = Color.Purple
End Sub
Private Sub UCNVA1M_LostFocus(ByVal sender As Object, ByVal e As System.EventArgs) Handles UCNVA1M.LostFocus
UCNVA1M.BackColor = Color.LightSlateGray
End Sub
Private Sub S1M_GotFocus(ByVal sender As Object, ByVal e As System.EventArgs) Handles S1M.GotFocus
S1M.Text = String.Format("{0:0.00}", ValS1M2)
S1M.Refresh()
S1M.BackColor = Color.Purple
End Sub
Private Sub S1M_LostFocus(ByVal sender As Object, ByVal e As System.EventArgs) Handles S1M.LostFocus
S1M.BackColor = Color.LightSlateGray
End Sub |
Partager