Jump to content

virhonestum

Members
  • Posts

    13
  • Joined

  • Last visited

Recent Profile Visitors

136 profile views

virhonestum's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. Thank You!!!! This worked!
  2. Thanks, but how exactly do I implement it? Just adding this line of code does nothing, and adding it and using $NULL in the _ReplaceInFile() call doesn't work either, since it is essentially the same as I already tried.
  3. And how do I get rid of the NUL characters?Both _ReplaceStringInFile ($f, " ", "") and _ReplaceStringInFile ($f, Chr(0), "") do not seem to work. Thank you - virhonestum
  4. Hey, I've coma accross a very odd problem. I want to download a CSV-File, and process the contents. This is the extremely simplyfied AutoIT-Code, given the file is already downloaded: $f= @ScriptDir & "\TestFile.csv" $file = FileOpen($f,0) Local $line = FileReadLine($file) MsgBox(0,"",$line) The downloaded CSV file I want to process contains something like this: Artikelnummer;EAN-Code;Artikelname;Artikelgewicht;Beschreibung;Kurzbeschreibung;Eigenschaften;Technische-Daten;Bild1;Bild2;Bild3;Bild4;Bild5;Bild6;Bild7;Bild8;Lieferbar;"Lieferbar Ab";Versandzeit;"UVP-Preis inkl. MwSt.";"Preis1";"Preis2";Hersteller L7335272;5420025602129; Mini Light XLR ;0.1000; JB Systems Schwanenhalsleuchte mit XLR Anschluss. ;;;;http://www.example.com/media/images/org/pic20070114153500a.jpg;;;;;;;;JA;; 1-3 Tage ;12,90;12,90;6,57; JB Systems L3320502;540207025601636; Mini Light LED BNC ;0.1000; JB Systems LED Schwanenhalsleuchte mit BNC Anschluss. ;;;;http://www.example.com/media/images/org/pic20061231171705a.jpg;;;;;;;;JA;; 1-3 Tage ;29,90;25,89;15,26; JB Systems L1332254;542002556023143; Mini Light LED XLR ;0.1000; JB Systems LED Schwanenhalsleuchte mit XLR Anschluss. ;;;;http://www.example.com/media/images/org/pic20061231171728a.jpg;;;;;;;;JA;; 1-3 Tage ;29,90;25,89;15,26; JB Systems L8302591;504200256280277; Spiegelkugel 10cm ;0.5000; JB Systems Spiegelkugel 10cm Durchmesser mit einer hohen Dichte durch 10 x 10 mm Echtglasspiegel. ;;;;http://www.example.com/media/images/org/pic20060324214825a.jpg;;;;;;;;JA;; 1-3 Tage ;5,50;4,90;2,81; JB Systems L7302932;542000256510222; Spiegelkugel 20cm ;0.8400; JB Systems Spiegelkugel 20cm Durchmesser mit einer hohen Dichte durch 10 x 10 mm Echtglasspiegel. ;;;;http://www.example.com/media/images/org/pic20060324214907a.jpg;;;;;;;;JA;; 1-3 Tage ;12,90;11,50;6,58; JB Systems L2350293;534200562064239; Spiegelkugel 30cm ;2.1300; JB Systems Spiegelkugel 30 cm Durchmesser mit einer hohen Dichte durch 10 x 10 mm Echtglasspiegel. ;;;;http://www.example.com/media/images/org/pic20060324214956a.jpg;;;;;;;;JA;; 1-3 Tage ;26,90;23,00;13,72; JB Systems L3302984;545200252024246; Spiegelkugel 40cm ;3.5000; JB Systems Spiegelkugel 40cm Durchmesser mit Sicherungsring und einer hohen Dichte durch 10 x 10 mm Echtglasspiegel. ;;;;http://www.example.com/media/images/org/pic20060324215050a.jpg;;;;;;;;JA;; 1-3 Tage ;54,90;49,00;28,00; JB Systems L9302495;542205056225600; Spiegelkugel 50cm ;5.3900; JB Systems Spiegelkugel 50cm Durchmesser mit Sicherungsring und einer hohen Dichte durch 10 x 10 mm Echtglasspiegel. ;;;;http://www.example.com/media/images/org/pic20060324215122a.jpg;;;;;;;;JA;; 1-3 Tage ;89,00;79,00;45,39; JB Systems But the message box that pops up after FileReadLine contains this: 䅲瑩步汮畭浥爻䕁中䍯摥㭁牴楫敬湡浥㭁牴楫敬来睩捨琻䉥獣桲敩扵湧㭋畲穢敳捨牥楢畮朻䕩来湳捨慦瑥渻呥捨湩獣桥ⵄ慴敮㭂楬搱㭂楬搲㭂楬搳㭂楬搴㭂楬搵㭂楬搶㭂楬搷㭂楬搸㭌楥晥牢慲㬢䱩敦敲扡爠䅢∻噥牳慮摺敩琻≕噐ⵐ牥楳⁩湫氮⁍睓琮∻≐牥楳ㄢ㬢偲敩猲∻䡥牳瑥汬敲ੌ㜳㌵㈷㈻㔴㈰〲㔶〲ㄲ㤻M楮椠䱩杨琠塌刀㬰⸱〰〻J䈠卹獴敭猠卣桷慮敮桡汳汥畣桴攠浩琠塌删䅮獣桬畳献;㬻㭨瑴瀺⼯睷眮數慭灬攮捯洯浥摩愯業慧敳⽯牧⽰楣㈰〷〱ㄴㄵ㌵〰愮橰朻㬻㬻㬻㭊䄻㬀ㄭ㌠呡来;ㄲⰹ〻ㄲⰹ〻㘬㔷㬀䩂⁓祳瑥浳 I've attached both files I use. My guess is, that there's something wrong with the encoding, but I'm not sure how to fix it. Thank you very much for your help - virhonestum Encodingtester.au3 TestFile.csv
  5. Very useful! But is it possible to use it for a programatically changed label that aligns the text to the right? Here's an example: #Include <GUIConstants.Au3> #include <ButtonConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #include <GUIScrollBars_Ex.au3> #include <StringSize.au3> Global $Display_String = 'TestTestTestTestTestTestTest' $hGUI = GUICreate("Test", 300, 90) $Button = GUICtrlCreateButton("Add Text", 10, 60, 280, 20) GUISetState() $Wrapper = GUICreate("Scroll", 280, 30, 10, 10, $WS_POPUP, $WS_EX_MDICHILD, $hGUI) $Display = GUICtrlCreateLabel($Display_String, 0, 0, 280, 40, $SS_RIGHT) GUICtrlSetFont(-1, 10, 400, 0, "Arial") GUISetState() While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE Exit Case $Button _Update_Display() EndSwitch WEnd Func _Update_Display() $Display_String = $Display_String & "Test" GUICtrlSetData($Display, $Display_String) $Return = _StringSize($Display_String, 10, 400, 0, "Arial") If $Return[2] > 265 Then _GUIScrollbars_Generate($Wrapper, $Return[2], 0) EndIf EndFunc In this example, the label still scrolls to the right, even though the remaining text is on the left, and thus just revealing empty space. Thank you very much
  6. @JohnOne Thanks, that's what I needed! @reb Definitely gonna save that for later but in this case I don't want it to be draggable everywhere on the window
  7. Nvermind, I changed it to UTF8, not to UTF8+BOM, so it works now! Thank you very much!
  8. That works for the arrow, but unfortunately there's no square root in neither one of the wingigns nor webdings Im not sure how to write the characters in UTF8 encoding. Other special characters in my code changed to text in a red box (For example ± changed to xB1 as white text in a red box ) When I just use the character "√" it displays as "√" ()
  9. I want to have the Square Root (√) and an Arrow (←) character in a label. But when I copy and paste them from the Windows Character Map, the arrow turns into a question mark and the square root into a 'v'. How can I have those special characters in labels / buttons / anywhere in AutoIt? Thank you very much
  10. I just realized that you cannot drag the window around either, so I added another question (I edited the whole topic) How am I able to drag the window around?
  11. This is how it looks for me: On this one the window just disappears And this is how I want it (I removed the $WS_POPUP here) On this one it shrinks, fades out, and retracts to the task bar
  12. Sorry for the late response, but this the important part of what I'm currently working with: #Include <GUIConstants.Au3> #include <ButtonConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> $Calculator = GUICreate("", 298, 100, 556, 260, $WS_POPUP) GUISetBkColor(0xFFFFFF) $Button_Exit = GUICtrlCreateLabel("×", 256, 0, 41, 17, BitOR($SS_CENTER, $SS_CENTERIMAGE)) GUICtrlSetBkColor(-1, 0xDC0000) GUICtrlSetColor(-1, 0xF2F2F2) $Button_Minimize = GUICtrlCreateLabel("_", 224, 0, 25, 17, BitOR($SS_CENTER, $SS_CENTERIMAGE)) GUICtrlSetBkColor(-1, 0x1E1E1E) GUICtrlSetColor(-1, 0xF2F2F2) GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Button_Exit Exit Case $Button_Minimize GUISetState(@SW_MINIMIZE) EndSwitch WEnd
  13. Edit: Now I'm going to expand the question, how do I create a custom title bar? So you have custom buttons (I already have those), but also have a part at the top, with which you can drag the window around. I don't need an icon or a title, so the only thing I need is this draggable part. Original Question: I want to make a GUI, which doesn't use the Windows buttons and has custom minimize/close-buttons. But when I add the $WS_POPUP style to my GUI, and have the minimize button execute GUISetState(@SW_MINIMIZE) the window has no minimize animation, where the window shrinks and retracts into the task bar. Is there any way I can remove the border and the upper bar but still have the animation? Thank you very much Virhonestum (Vir)
×
×
  • Create New...