Da ich ab und zu auf Amazon.co.uk einkaufe brauche ich immer den Aktuellen Wechselkurs deshalb habe ich mal ein kleines Script gebastelt was automatisch den
neusten Kurs ermittelt
Spoiler anzeigen
#include <array.au3>
#include <string.au3>
#include <inet.au3>
#include <ButtonConstants.au3>
#include <ComboConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
$gui_GoogleKurs = GUICreate("GoogleKurs", 231, 103, 431, 257)
$kurs_input = GUICtrlCreateCombo("", 8, 8, 97, 25)
GUICtrlSetData(-1,"GBP|EURO|USD|yen","EURO")
$kurs_output = GUICtrlCreateCombo("", 128, 8, 97, 25)
GUICtrlSetData(-1,"GBP|EURO|USD|yen","USD")
$mony_input = GUICtrlCreateInput("1", 8, 32, 97, 21,BitOR($ES_AUTOHSCROLL,$ES_NUMBER))
$btn_start = GUICtrlCreateButton("Start", 128, 32, 97, 21, $WS_GROUP)
$mony_output = GUICtrlCreateLabel("Ergebniss: create by Rodny_le_Lude", 8, 72, 213, 17)
GUICtrlSetColor(-1, 0x000000)
GUISetState(@SW_SHOW)
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $btn_start
get_kurs(GUICtrlRead($kurs_input),GUICtrlRead($kurs_output),GUICtrlRead($mony_input))
EndSwitch
WEnd
Func get_kurs($k_inp,$k_out,$wert)
$update="http://www.google.de/search?hl=de&q="&$wert&$k_inp&"+in+"&$k_out&"&aq=f&aqi=&aql=$op=&gs_rfai="
$read=_INetGetSource($update)
$str=StringRegExp($read,'138%"[^"]+\</b>',3)
If IsArray($str) then
$str=_StringBetween($str[0],"<b>","</b>")
$str=StringRegExp($str[0],"\d*[,.]*\d+",3)
GUICtrlSetData($mony_output,"Ergebniss:"&$wert&" "&$k_inp&"="&$str[1]&" "&$k_out)
Else
GUICtrlSetData($mony_output,"Ergebniss:kann nicht ermittelt werden")
EndIf
EndFunc