Jump to content

Import data from Excel


Recommended Posts

Hi,

Not been doing any scripts for a couple of years, and my head is totaly empty.

I would appriciate if someone could point me in the right direction when it comes to importing

data from an excel sheet.

I have built a GUI, with several "filters" that users can define before pressing button "view"

When they press view, it should go to the excel sheet and import the filtered data.

Example of the excel sheet

Name    Class     Spec       Role       Talents     Raw gear    Buff gear   Warn
Adema   Druid   Feral DPS   DPS 0/50/11 153.90  161.29  4
Albino  Druid   Feral Tank  Tank    0/47/14 142.14  157.65  2
Andraste  Druid Restorat    Healer  7/0/54  146.65  150.44  3
Ashien  Druid   Restorat    Healer  11/0/50 156.91  171.46  2
Catzap  Druid   Feral DPS   DPS 0/43/18 129.91  146.43  3

In the GUI you can for example chose "Role" and "Class", and when you then click view it should pop-up

a new window showing all data based on the filter.

Below is the GUI code i created so far.

#include <GUIConstants.au3>

#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("NoD", 534, 200, 213, 278)
$Label1 = GUICtrlCreateLabel("Spec", 16, 96, 29, 17)
$Label2 = GUICtrlCreateLabel("Class", 168, 96, 29, 17)
GUICtrlCreateCombo("", 168, 112, 145, 25)
GUICtrlSetData(-1, "|Druid|Hunter|Mage|Paladin|Priest|Rogue|Shaman|Warlock|Warrior")
GUICtrlCreateCombo("", 16, 112, 145, 25)
GUICtrlSetData(-1, "|Feral DPS|Feral Tank|Restoration|Balance")
$Label3 = GUICtrlCreateLabel("Role", 320, 96, 26, 17)
GUICtrlCreateCombo("", 320, 112, 145, 25)
GUICtrlSetData(-1, "|DPS|Tank|Healer")
$View = GUICtrlCreateButton("View", 344, 160, 75, 25, 0)
$Reset = GUICtrlCreateButton("Reset", 424, 160, 75, 25, 0)
$Label4 = GUICtrlCreateLabel("Minimum Gear", 16, 144, 71, 17)
GUICtrlCreateInput("", 16, 160, 73, 21)
GUICtrlSetTip(-1, "Enter the lowest imba value you wanna search for.")
$Label5 = GUICtrlCreateLabel("Maximum Gear", 96, 144, 74, 17)
GUICtrlCreateInput("", 96, 160, 73, 21)
GUICtrlSetTip(-1, "Enter the highest imba value you wanna search for.")
$Label6 = GUICtrlCreateLabel("Activity", 184, 144, 38, 17)
GUICtrlCreateCombo("", 184, 160, 145, 25)
GUICtrlSetData(-1, "|>1 day|1 week|1 month|< 1month")
GUICtrlSetTip(-1, "Look for people that have been away less then....")
$Pic1 = GUICtrlCreatePic("C:\Documents and Settings\xpx8963\My Documents\ge\wrapper.jpg", 0, -8, 532, 204, BitOR($SS_NOTIFY,$WS_GROUP,$WS_CLIPSIBLINGS))
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit

EndSwitch
WEnd

I'm not asking anyone do this for me, just need some help to get started.

Yes, i have looked around in the forum, but have not found anything related to this.

Thanks in advance

Were ever i lay my script is my home...

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...