Hi,
hast du schon mal geguckt, ob nicht vielleicht doch etwas unteschiedlich ist? Excel Version Spracheinstellungen etc.?
Mega
Hi,
hast du schon mal geguckt, ob nicht vielleicht doch etwas unteschiedlich ist? Excel Version Spracheinstellungen etc.?
Mega
Die gleiche Antwort hatte ich dir bereits schon gegeben. Bitte reiß dich in Zukunft ein bißchen zusammen, ansonsten werde ich dich verwarnen.
Hi,
wenn die Funktionen in Autoit verfügbar sind, dann heißt das nicht, dass sie in Scite verfügbar sind mit Tooltips usw.! Diese müßtest du selbst nachpflegen. Such mal danach, ich meine Bugfix hat für seine Fkt mal beschrieben wie sowas geht.
Mega
Das wage ich zu bezweifeln. Außerdem nutzt das ja nix. Du wirst schon debuggen müssen. Ansonsten lad mal ein zip mit allem hoch was ich zum Nachstellen brauche.
Mega
So, ist es viiiiel schöner und flexibler ![]()
Hi,
klar! Du kannst dir einen Treeview aufbauen und dann die Ordner und Dateien einlesen. Ist natürlich etwas Aufwand!
Such mal nach Explorer oder Holger Kotsch.
Mega
Hi,
einfach mal in der Hilfe die Funktionen durchgucken. (überfliegen) Übersetzen Laufwerk = Drive also mal bei den Funktionen mit Drive gucken.
Du schaffst das. ![]()
Mega
Hi,
na dann musst du eins nach dem anderen machen
$zeile=_ExcelReadSheetToArray($datei,8,1)
hast du im Code. Dann laß die die Dinge vorher anzeigen. Vielleicht sind ja gar keine 8 Einträge vorhanden.
Immer alles anzeigen lassen u prüfen.
Mega
#include <GuiListView.au3>
#include <ListViewConstants.au3>
$GUI = GUICreate("Items einfärben", 400, 400)
GUISetState()
Dim $Array[3]
$Array[0] = "Test1"
$Array[1] = "Test2"
$Array[2] = "Test3"
Dim $Array2[4]
$Array2[0] = "Test1"
$Array2[1] = "Test2"
$Array2[2] = "Test3"
$Array2[3] = "Test4"
$List = GUICtrlCreateListView("Spalte 1", 0, 0, 400, 200)
_GUICtrlListView_SetColumnWidth($List, 0, $LVSCW_AUTOSIZE_USEHEADER)
$List2 = GUICtrlCreateListView("Spalte 1", 0, 200, 400, 200)
_GUICtrlListView_SetColumnWidth($List2, 0, $LVSCW_AUTOSIZE_USEHEADER)
For $i = 0 To UBound($Array, 1) - 1
GUICtrlCreateListViewItem($Array[$i], $List)
GUICtrlSetBkColor(-1, 0xFF00000)
Next
For $i = 0 To UBound($Array2, 1) - 1
GUICtrlCreateListViewItem($Array2[$i], $List2)
GUICtrlSetBkColor(-1, 0x00FF00)
Next
Do
$msg = GUIGetMsg()
Until $msg = -3
HI,
werte mal den Rückgabewert aus bzw. @error
[autoit]$oExcel = _ExcelBookOpen($sFilePath1)
[/autoit][autoit][/autoit][autoit]If @error = 1 Then
MsgBox(0, "Error!", "Unable to Create the Excel Object")
Exit
ElseIf @error = 2 Then
MsgBox(0, "Error!", "File does not exist - Shame on you!")
Exit
EndIf
Mega
Fehlermeldung? Code?
BEstimmt, nutze ich aber leider nie. Musst mal nach Parentdrag oder so suchen.
#include <GUIConstantsEx.au3>
#include <SendMessage.au3>
#region - GUI Create
$GUI = GUICreate('dd',-1,-1,-1,-1,BitOR($WS_POPUPWINDOW, $WS_THICKFRAME), BitOR($WS_EX_CLIENTEDGE, $WS_EX_TOOLWINDOW))
GUICtrlCreateLabel("Label",10,10,100,200)
GUICtrlSetBkColor(-1,0x999999)
GUICtrlCreateButton("Btn",10,220,50,25)
;~ GUISetOnEvent($GUI_EVENT_PRIMARYDOWN,"_Prim")
GUISetState()
#endregion
#region - GUI SelectLoop
While 1
$msg = GUIGetMsg()
Select
Case $msg = $GUI_EVENT_CLOSE
Exit
Case $msg = $GUI_EVENT_PRIMARYDOWN
_SendMessage($GUI,$WM_SYSCOMMAND,0xF012,0)
EndSelect
WEnd
#endregion
Hmmh, sieht okay aus.
Wenn das Bild im ScripDir ist, dann brauchst du gar keinen Pfad angeben. Einfach nur den Dateinamen.
Am besten du machst einfach sowas
If DirCopy = 0 Then _FileWriteLog .... das Verzeichnis
Mega
Okay, dies ist der 5000 post. Dafür habe ich mal eben schnell was zusammekopiert ![]()
#include <GDIPlus.au3>
#include <FontConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
Opt("OnExitFunc", "endscript")
Global Const $Pi = 3.1415926535897932384626
Global Const $width = @DesktopWidth+ 100
Global Const $height = @DesktopHeight+100
Global $hGUI, $hWnd, $hGraphic, $ParticleBitmap, $ParticleBuffer, $hBrush0, $hBrush1, $hBrush2, $Pen
Global $starting_point, $i, $j, $k, $xcoord1, $ycoord1, $xcoord2, $ycoord2, $size, $red, $green, $blue, $start
; Create GUI
$hGUI = GUICreate("", $width, $height, -50, -50, $WS_POPUP, $WS_EX_TOOLWINDOW + $WS_EX_TOPMOST)
$hWnd = WinGetHandle($hGUI)
Send("#m")
GUISetState()
ControlHide("Program Manager", "", "[CLASSNN:SHELLDLL_DefView1]")
Global $s = TimerInit()
[/autoit] [autoit][/autoit] [autoit]; Draw an ellipse
_GDIPlus_Startup()
$hGraphic = _GDIPlus_GraphicsCreateFromHWND($hWnd) ;create graphic
$ParticleBitmap = _GDIPlus_BitmapCreateFromGraphics($width, $height, $hGraphic) ;create bitmap
$ParticleBuffer = _GDIPlus_ImageGetGraphicsContext($ParticleBitmap) ;create buffer
$hBrush1 = _GDIPlus_BrushCreateSolid(0x7F777777)
AntiAlias($ParticleBuffer, 4)
_GDIPlus_GraphicsClear($ParticleBuffer) ;clear buffer
$start = -25
$i = $start
$starting_point = 0
; Loop until user exits
Do
$red = ((Sin(2 ^ 0 * $i / 2 ^ 5) + 1) / 2) * 256
$green = ((Sin(2 ^ 0 * $i / 2 ^ 7) + 1) / 2) * 256
$blue = ((Sin(2 ^ 0 * $i / 2 ^ 9) + 1) / 2) * 256
$hBrush1 = _GDIPlus_BrushCreateSolid("0x0F" & Hex($red, 2) & Hex($green, 2) & Hex($blue, 2))
$Pen = _GDIPlus_PenCreate("0xEF" & Hex($red, 2) & Hex($green, 2) & Hex($blue, 2), 1)
_GDIPlus_GraphicsClear($ParticleBuffer) ;clear buffer
$k = 2 ^ 9
$starting_point -= 0.05
For $j = 1 To $k Step 8
$size = $i - $j
$xcoord1 = $width / 2 - (($i - $j) / 2) + Sin($starting_point) * - Sin(($i - $j) * $Pi / 90) * 64
$ycoord1 = $height / 2 - (($i - $j) / 2) + - Cos($starting_point) * Cos(($i - $j) * $Pi / 90) * 32
$xcoord2 = $width / 2 - (-($i - $j) / 2) + Sin($starting_point) * - Sin(($i - $j) * $Pi / 90) * 64
$ycoord2 = $height / 2 - (($i - $j) / 2) + - Cos($starting_point) * Cos(($i - $j) * $Pi / 90) * 32
_GDIPlus_GraphicsDrawRect($ParticleBuffer, $xcoord1, $ycoord1, $size, $size, $Pen)
;~ _GDIPlus_GraphicsFillRect($ParticleBuffer, $xcoord1, $ycoord1, $size, $size, $hBrush1)
Next
_GDIPlus_GraphicsDrawImageRect($hGraphic, $ParticleBitmap, 0, 0, $width, $height) ;copy to bitmap
$i += 2
If $i > $k + 2 ^ 9 Then $i = $start
Sleep(20)
Until GUIGetMsg() = $GUI_EVENT_CLOSE Or TimerDiff($s) > 8000
; Clean up resources
_GDIPlus_GraphicsDispose($hGraphic)
_GDIPlus_BitmapDispose($ParticleBitmap)
_GDIPlus_GraphicsDispose($ParticleBuffer)
_GDIPlus_BrushDispose($hBrush1)
_GDIPlus_Shutdown()
GUIDelete($hGUI)
Sleep(500)
$hWnd = GUICreate("Text Region", $width, $height, 10, @DesktopHeight / 2 - 150, $WS_POPUP, $WS_EX_TOOLWINDOW + $WS_EX_TOPMOST)
GUISetBkColor(0x00FF00)
GUISetState()
While 1
$rgn = CreateTextRgn($hWnd, 5000 & "Posts", 250, "Arial", 1000)
SetWindowRgn($hWnd, $rgn)
Sleep(500)
If TimerDiff($s) > 15000 Then Exit
WEnd
Func endscript()
ControlShow("Program Manager", "", "[CLASSNN:SHELLDLL_DefView1]")
EndFunc ;==>endscript
Func SetWindowRgn($h_win, $rgn)
DllCall("user32.dll", "long", "SetWindowRgn", "hwnd", $h_win, "long", $rgn, "int", 1)
EndFunc ;==>SetWindowRgn
Func CreateTextRgn(ByRef $CTR_hwnd, $CTR_Text, $CTR_height, $CTR_font = "Microsoft Sans Serif", $CTR_weight = 1000)
Local Const $ANSI_CHARSET = 0
Local Const $OUT_CHARACTER_PRECIS = 2
Local Const $CLIP_DEFAULT_PRECIS = 0
Local Const $PROOF_QUALITY = 2
Local Const $FIXED_PITCH = 1
Local Const $RGN_XOR = 3
If $CTR_font = "" Then $CTR_font = "Microsoft Sans Serif"
If $CTR_weight = -1 Then $CTR_weight = 1000
Local $gdi_dll = DllOpen("gdi32.dll")
Local $CTR_hDC = DllCall("user32.dll", "int", "GetDC", "hwnd", $CTR_hwnd)
Local $CTR_hMyFont = DllCall($gdi_dll, "hwnd", "CreateFont", "int", $CTR_height, "int", 0, "int", 0, "int", 0, _
"int", $CTR_weight, "int", 0, "int", 0, "int", 0, "int", $ANSI_CHARSET, "int", $OUT_CHARACTER_PRECIS, _
"int", $CLIP_DEFAULT_PRECIS, "int", $PROOF_QUALITY, "int", $FIXED_PITCH, "str", $CTR_font)
Local $CTR_hOldFont = DllCall($gdi_dll, "hwnd", "SelectObject", "int", $CTR_hDC[0], "hwnd", $CTR_hMyFont[0])
DllCall($gdi_dll, "int", "BeginPath", "int", $CTR_hDC[0])
DllCall($gdi_dll, "int", "TextOut", "int", $CTR_hDC[0], "int", 0, "int", 0, "str", $CTR_Text, "int", StringLen($CTR_Text))
DllCall($gdi_dll, "int", "EndPath", "int", $CTR_hDC[0])
Local $CTR_hRgn1 = DllCall($gdi_dll, "hwnd", "PathToRegion", "int", $CTR_hDC[0])
Local $CTR_rc = DllStructCreate("int;int;int;int")
DllCall($gdi_dll, "int", "GetRgnBox", "hwnd", $CTR_hRgn1[0], "ptr", DllStructGetPtr($CTR_rc))
Local $CTR_hRgn2 = DllCall($gdi_dll, "hwnd", "CreateRectRgnIndirect", "ptr", DllStructGetPtr($CTR_rc))
DllCall($gdi_dll, "int", "CombineRgn", "hwnd", $CTR_hRgn2[0], "hwnd", $CTR_hRgn2[0], "hwnd", $CTR_hRgn1[0], "int", $RGN_XOR)
DllCall($gdi_dll, "int", "DeleteObject", "hwnd", $CTR_hRgn1[0])
DllCall("user32.dll", "int", "ReleaseDC", "hwnd", $CTR_hwnd, "int", $CTR_hDC[0])
DllCall($gdi_dll, "int", "SelectObject", "int", $CTR_hDC[0], "hwnd", $CTR_hOldFont[0])
DllClose($gdi_dll)
Return $CTR_hRgn2[0]
EndFunc ;==>CreateTextRgn
Func AntiAlias($hGraphics, $iMode)
Local $aResult
$aResult = DllCall($ghGDIPDll, "int", "GdipSetSmoothingMode", "hwnd", $hGraphics, "int", $iMode)
If @error Then Return SetError(@error, @extended, False)
Return SetError($aResult[0], 0, $aResult[0] = 0)
EndFunc ;==>AntiAlias
Mega
Hi,
kein Problem. Einfach suchen. Solche Dinge werden ja nicht zum ersten Mal gefragt ![]()
Mega
Kannst du den Code so posten, dass man schnell testen kann?