Jump to content

ShaneHale

Members
  • Posts

    13
  • Joined

  • Last visited

Everything posted by ShaneHale

  1. Definately! Thank you. I was soooo close. I have some kind of mental block with 'ubound' just not clear on how or when to use it. i think I learned something wrong at some point i you knw what I mean. That's very possibly true since i am my teacher....... Ha! Thanks again so much..... Shane Hale Tuacahn center for the Arts
  2. Hi, Been a while since I needed to ask for help, guess that means I am getting this stuff a little better. Anyways, I am trying to read from a ini file that is going to have dynamically changing information for the section names - actually written form another script on client computers in a student lab into netlogon. It has information such as @computername, @username and other varible information I am collecting in order to restrict and monitor computer usage. So I can read the information from the ini and I can have it looped through an array and spit out into information on buttons in a gui - BUT - that is where I get stumped. I can not get my select cases to dicern from one button to the next because my variable is just called $button. What I think I need is a way to go through the loop and load arrayed info from the ini into variables as i am doing but each time rename the $button variable to another name like some way to say $button after it is loaded can be combined with $a_number to become $button1 and $button2 and so on BUT the information I entered INTO $button on this time around the loop woud not be changed. So then later in the gui while loop I could call these new variables and use information that was loaded on each specific pass of the for loop by calling $button1 or $button2 and so on. I bet someone knows what I mean and I bet some one has already done something simular. In fact it could be that I am thinking too hard and it is easy to do what I want. Although i do suppose Easy is a relative term. At any rate here is what I have and it works all the way up to the point where I want to add events to the button clicks: CODE#include <GUIConstants.au3> $var0 = IniReadSectionNames("enabled.ini") $Form1 = GUICreate("Lab Monitor Console", 310, 563, 220, 70) $n = 0 For $i = 1 To $var0[0] MsgBox(0,"",$var0[$i]) $var1 = IniRead("enabled.ini", $var0[$i], "USER", "NotFound") $var2 = IniRead("enabled.ini", $var0[$i], "COMPUTER", "NotFound") $var3 = IniRead("enabled.ini", $var0[$i], "MONITOR", "NotFound") $var4 = IniRead("enabled.ini", $var0[$i], "RECORD", "NotFound") $var5 = IniRead("enabled.ini", $var0[$i], "ALERT", "NotFound") $var0[$i] = GUICtrlCreateButton($var1 & " " & $var2 & " " & $var3 & " " & $var4 & " " & $var5, 0, $n, 309, 20, 0) $n = $n + 20 Next GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd Any help or suggestions would be appreciated......
  3. Ok Changed the order of input as suggested and the lay out is now different than befor. Now I am stuck on how to show the data in a listview list as list view items so I can add and remove them. I am not sure if this is the best way to do this but I feel like I have to be able to manipulat the data after I show it. For example if someone orders 2 popcorns but then decided the only whanted 1 than how would I remove that from plain old list? So list view seemed like a better choice but it seems to be outside the scope of my ability to 1) submit the next item as the next item to put in the list because each seems to need to be prenamed, and 2) manipulate those items after they are submited to change the quanity - since I dont know where that item was submitted or what it was submited as. this is getting confusing. Man need to remae it to complex POS instead of simple POS Here is the changes I have made to the layout and what I have attemped to do with the listview so far. Some one please help me with something encouraging, I feel like this can be done still. Regards, Shane Hale #include <GUIConstants.au3> #Region ### START Koda GUI section ### Form=c:\security\koda_1.6.0.2\forms\aform2.kxf $Form1_1 = GUICreate("Simple POS", 618, 586, 209, 116) $Tab1 = GUICtrlCreateTab(8, 8, 601, 569) $TabSheet1 = GUICtrlCreateTabItem("REGISTER") $Group1 = GUICtrlCreateGroup("", 20, 32, 577, 529) GUICtrlSetColor(-1, 0xFFFF00) $ListView = GUICtrlCreateListView("Item|Quanity", 36, 112, 249, 374) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") GUICtrlSetColor(-1, 0x00FFFF) GUICtrlSetBkColor(-1, 0x000000) GUICtrlCreateGroup("", -99, -99, 1, 1) $Label1 = GUICtrlCreateLabel("", 36, 48, 249, 60, BitOR($SS_CENTER,$SS_CENTERIMAGE,$SS_SUNKEN,$WS_BORDER)) GUICtrlSetFont(-1, 22, 800, 0, "Lucida Console") GUICtrlSetColor(-1, 0xFFFF00) GUICtrlSetBkColor(-1, 0x008000) $Button1 = GUICtrlCreateButton("1", 292, 384, 75, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button2 = GUICtrlCreateButton("2", 364, 384, 75, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button3 = GUICtrlCreateButton("3", 436, 384, 75, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button4 = GUICtrlCreateButton("4", 292, 336, 75, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button5 = GUICtrlCreateButton("5", 364, 336, 75, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button6 = GUICtrlCreateButton("6", 436, 336, 75, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button7 = GUICtrlCreateButton("7", 292, 288, 75, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button8 = GUICtrlCreateButton("8", 364, 288, 75, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button9 = GUICtrlCreateButton("9", 436, 288, 75, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button10 = GUICtrlCreateButton("0", 292, 432, 147, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button11 = GUICtrlCreateButton("+", 508, 288, 75, 97, 0) GUICtrlSetFont(-1, 28, 400, 0, "Lucida Console") $Button12 = GUICtrlCreateButton("-", 508, 384, 75, 49, 0) GUICtrlSetFont(-1, 28, 400, 0, "Lucida Console") $Button13 = GUICtrlCreateButton("LG SODA", 292, 48, 75, 49, 0) $Button14 = GUICtrlCreateButton("BURGER", 292, 96, 75, 49, 0) $Button15 = GUICtrlCreateButton("COCOA", 292, 144, 75, 49, 0) $Button16 = GUICtrlCreateButton("LG CANDY", 292, 192, 75, 49, 0) $Button17 = GUICtrlCreateButton("RG SODA", 364, 48, 75, 49, 0) $Button18 = GUICtrlCreateButton("HOTDOG", 364, 96, 75, 49, 0) $Button19 = GUICtrlCreateButton("CAPPICINO", 364, 144, 75, 49, 0) $Button20 = GUICtrlCreateButton("SM CANDY", 364, 192, 75, 49, 0) $Button21 = GUICtrlCreateButton("WATER", 436, 48, 75, 49, 0) $Button22 = GUICtrlCreateButton("POPCORN", 436, 96, 75, 49, 0) $Button23 = GUICtrlCreateButton("ICE", 436, 144, 75, 49, 0) $Button24 = GUICtrlCreateButton("CHIPS", 508, 144, 75, 49, 0) $Button25 = GUICtrlCreateButton("CHILL", 508, 48, 75, 49, 0) $Button26 = GUICtrlCreateButton("NACHOS", 508, 96, 75, 49, 0) $Button27 = GUICtrlCreateButton("CHIPS", 508, 192, 75, 49, 0) $Button28 = GUICtrlCreateButton("MUFFINS", 436, 192, 75, 49, 0) $Button29 = GUICtrlCreateButton("CANCEL", 36, 496, 99, 41, 0) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") $Button30 = GUICtrlCreateButton("CREDIT CARD", 292, 496, 145, 41, 0) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") $Button31 = GUICtrlCreateButton("TENDER CASH", 436, 496, 147, 41, 0) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") $Button32 = GUICtrlCreateButton("TOTAL", 436, 432, 147, 49, 0) GUICtrlSetFont(-1, 18, 800, 0, "MS Sans Serif") $Button33 = GUICtrlCreateButton("X", 292, 240, 291, 49, 0) GUICtrlSetFont(-1, 36, 400, 0, "Lucida Console") $TabSheet2 = GUICtrlCreateTabItem("TRANSACTIONS") GUICtrlSetState(-1,$GUI_SHOW) $Group2 = GUICtrlCreateGroup("", 20, 32, 577, 529) $Date1 = GUICtrlCreateDate("2007/06/06 17:04:58", 212, 56, 186, 21) $ListView1 = GUICtrlCreateListView("", 166, 95, 285, 432) GUICtrlCreateGroup("", -99, -99, 1, 1) $TabSheet3 = GUICtrlCreateTabItem("BATCH") $Group3 = GUICtrlCreateGroup("", 20, 32, 577, 529) $Date2 = GUICtrlCreateDate("2007/06/06 17:15:22", 212, 56, 186, 21) GUICtrlCreateGroup("", -99, -99, 1, 1) GUICtrlCreateTabItem("") GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Button1 GuiCtrlSetData($Label1, "1") Case $Button2 GuiCtrlSetData($Label1, "2") Case $Button3 GuiCtrlSetData($Label1, "3") Case $Button4 GuiCtrlSetData($Label1, "4") Case $Button5 GuiCtrlSetData($Label1, "5") Case $Button6 GuiCtrlSetData($Label1, "6") Case $Button7 GuiCtrlSetData($Label1, "7") Case $Button8 GuiCtrlSetData($Label1, "8") Case $Button9 GuiCtrlSetData($Label1, "9") Case $Button10 GuiCtrlSetData($Label1, "0") Case $Button11 GuiCtrlSetData($Label1, "+") Case $Button12 GuiCtrlSetData($Label1, "-") Case $Button13 GuiCtrlSetData($ListView, "LARGE SODA|") GuiCtrlSetData($Label1, "3.00") Case $Button14 GuiCtrlSetData($ListView, "HAMBURGER|") GuiCtrlSetData($Label1, "3.00") Case $Button15 GuiCtrlSetData($ListView, "HOT COCOA|") GuiCtrlSetData($Label1, "3.00") Case $Button16 GuiCtrlSetData($ListView, "LARGE CANDY|") GuiCtrlSetData($Label1, "3.00") Case $Button17 GuiCtrlSetData($ListView, "REGULAR SODA|") GuiCtrlSetData($Label1, "2.00") Case $Button18 GuiCtrlSetData($ListView, "HOTDOG|") GuiCtrlSetData($Label1, "3.00") Case $Button19 GuiCtrlSetData($ListView, "CAPPICINO|") GuiCtrlSetData($Label1, "3.00") Case $Button20 GuiCtrlSetData($ListView, "SMALL CANDY|") GuiCtrlSetData($Label1, "2.00") Case $Button21 GuiCtrlSetData($ListView, "WATER|") GuiCtrlSetData($Label1, "2.00") Case $Button22 GuiCtrlSetData($ListView, "POPCORN|") GuiCtrlSetData($Label1, "3.00") Case $Button23 GuiCtrlSetData($ListView, "CUP OF ICE|") GuiCtrlSetData($Label1, "1.00") Case $Button24 GuiCtrlSetData($ListView, "CHIPS|") GuiCtrlSetData($Label1, "1.00") Case $Button25 GuiCtrlSetData($ListView, "CHILL|") GuiCtrlSetData($Label1, "3.00") Case $Button26 GuiCtrlSetData($ListView, "NACHOS|") GuiCtrlSetData($Label1, "3.00") Case $Button27 GuiCtrlSetData($ListView, "CHIPS|") GuiCtrlSetData($Label1, "1.00") Case $Button28 GuiCtrlSetData($ListView, "MUFFINS|") GuiCtrlSetData($Label1, "3.00") Case $Button29 GuiCtrlSetData($ListView, "|") Case $Button30 GuiCtrlSetData($ListView, "|") Case $Button31 GuiCtrlSetData($ListView, "|") Case $Button32 GuiCtrlSetData($ListView, "|") Case $Button33 GuiCtrlSetData($ListView, "|") EndSwitch WEnd
  4. I Like it, I will change the layout......
  5. @tAKTelapis, I like the idea and have updated the code accordingly and did a slight change to it - see below - but I am realizing there does not seem to be a way to update specific line items. using this method. I think that would make [POPCORN] [X] [3] not able to update only a single item to make it say in the display ($list1) that POPCORN x 3 or the order has 3 popcorns, rather than POPCORN POPCORN POPCORN. I am therefore looking into the listview gui function as perhaps a better alternative. (used these "[" and "]" to indicate a button press in this forum) for now here is what I have.... Note I added a label below the list to indicat the subtotal .... I am working on the list view and the math as a single issue. Any help or suggestions are still immensely appreciated... Shane Hale #include <GUIConstants.au3> #Region ### START Koda GUI section ### Form=c:\security\koda_1.6.0.2\forms\aform1.kxf $Form1_1 = GUICreate("Simple POS", 674, 586, 340, 359) $Tab1 = GUICtrlCreateTab(8, 8, 657, 569) $TabSheet1 = GUICtrlCreateTabItem("REGISTER") $Group1 = GUICtrlCreateGroup("", 20, 40, 633, 521) GUICtrlSetColor(-1, 0x989898) $List1 = GUICtrlCreateList("", 38, 55, 597, 165, BitOR($SS_RIGHT,$SS_CENTERIMAGE,$SS_SUNKEN,$WS_BORDER)) GUICtrlSetFont(-1, 12, 400, 0, "Lucida Console") GUICtrlSetColor(-1, 0xFFFF00) GUICtrlSetBkColor(-1, 0x008000) $Label1 = GUICtrlCreateLabel("", 185, 212, 293, 40, BitOR($SS_CENTER,$SS_CENTERIMAGE,$SS_SUNKEN,$WS_BORDER)) GUICtrlSetFont(-1, 22, 800, 0, "Lucida Console") GUICtrlSetColor(-1, 0xFFFF00) GUICtrlSetBkColor(-1, 0x008000) $Button1 = GUICtrlCreateButton("1", 412, 360, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button2 = GUICtrlCreateButton("2", 468, 360, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button3 = GUICtrlCreateButton("3", 524, 360, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button4 = GUICtrlCreateButton("4", 412, 312, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button5 = GUICtrlCreateButton("5", 468, 312, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button6 = GUICtrlCreateButton("6", 524, 312, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button7 = GUICtrlCreateButton("7", 412, 264, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button8 = GUICtrlCreateButton("8", 468, 264, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button9 = GUICtrlCreateButton("9", 524, 264, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button10 = GUICtrlCreateButton("0", 412, 408, 171, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button11 = GUICtrlCreateButton("+", 580, 264, 55, 121, 0) GUICtrlSetFont(-1, 28, 400, 0, "Lucida Console") $Button12 = GUICtrlCreateButton("-", 580, 384, 55, 73, 0) GUICtrlSetFont(-1, 28, 400, 0, "Lucida Console") $Button13 = GUICtrlCreateButton("LG SODA", 36, 264, 75, 49, 0) $Button14 = GUICtrlCreateButton("BURGER", 36, 312, 75, 49, 0) $Button15 = GUICtrlCreateButton("COCOA", 36, 360, 75, 49, 0) $Button16 = GUICtrlCreateButton("LG CANDY", 36, 408, 75, 49, 0) $Button17 = GUICtrlCreateButton("RG SODA", 108, 264, 75, 49, 0) $Button18 = GUICtrlCreateButton("HOTDOG", 108, 312, 75, 49, 0) $Button19 = GUICtrlCreateButton("CAPPICINO", 108, 360, 75, 49, 0) $Button20 = GUICtrlCreateButton("SM CANDY", 108, 408, 75, 49, 0) $Button21 = GUICtrlCreateButton("WATER", 180, 264, 75, 49, 0) $Button22 = GUICtrlCreateButton("POPCORN", 180, 312, 75, 49, 0) $Button23 = GUICtrlCreateButton("ICE", 180, 360, 75, 49, 0) $Button24 = GUICtrlCreateButton("CHIPS", 180, 408, 75, 49, 0) $Button25 = GUICtrlCreateButton("CHILL", 252, 264, 75, 49, 0) $Button26 = GUICtrlCreateButton("NACHOS", 252, 312, 75, 49, 0) $Button27 = GUICtrlCreateButton("CHIPS", 252, 360, 75, 49, 0) $Button28 = GUICtrlCreateButton("MUFFINS", 252, 408, 75, 49, 0) $Button29 = GUICtrlCreateButton("CANCEL", 164, 504, 91, 41, 0) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") $Button30 = GUICtrlCreateButton("CREDIT CARD", 252, 504, 163, 41, 0) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") $Button31 = GUICtrlCreateButton("TENDER CASH", 412, 504, 223, 41, 0) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") $Button32 = GUICtrlCreateButton("VOID", 36, 504, 131, 41, 0) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") $Button33 = GUICtrlCreateButton("SUBTOTAL", 36, 456, 291, 49, 0) GUICtrlSetFont(-1, 18, 800, 0, "MS Sans Serif") $Button34 = GUICtrlCreateButton("TOTAL", 324, 456, 311, 49, 0) GUICtrlSetFont(-1, 18, 800, 0, "MS Sans Serif") $Button35 = GUICtrlCreateButton("X", 328, 264, 83, 193, 0) GUICtrlSetFont(-1, 36, 400, 0, "Lucida Console") GUICtrlCreateGroup("", -99, -99, 1, 1) $TabSheet2 = GUICtrlCreateTabItem("TRANSACTIONS") $Group2 = GUICtrlCreateGroup("", 20, 40, 633, 521) $Date1 = GUICtrlCreateDate("2007/06/06 17:04:58", 228, 64, 186, 21) $ListView1 = GUICtrlCreateListView("", 36, 104, 602, 438) GUICtrlCreateGroup("", -99, -99, 1, 1) $TabSheet3 = GUICtrlCreateTabItem("BATCH") $Group3 = GUICtrlCreateGroup("", 20, 40, 633, 521) $Date2 = GUICtrlCreateDate("2007/06/06 17:15:22", 228, 64, 186, 21) GUICtrlCreateGroup("", -99, -99, 1, 1) GUICtrlCreateTabItem("") GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### GuiCtrlSetData($Label1, "0.00") While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Button1 GuiCtrlSetData($List1, "1|") Case $Button2 GuiCtrlSetData($List1, "2|") Case $Button3 GuiCtrlSetData($List1, "3|") Case $Button4 GuiCtrlSetData($List1, "4|") Case $Button5 GuiCtrlSetData($List1, "5|") Case $Button6 GuiCtrlSetData($List1, "6|") Case $Button7 GuiCtrlSetData($List1, "7|") Case $Button8 GuiCtrlSetData($List1, "8|") Case $Button9 GuiCtrlSetData($List1, "9|") Case $Button10 GuiCtrlSetData($List1, "0|") Case $Button11 GuiCtrlSetData($List1, "+|") Case $Button12 GuiCtrlSetData($List1, "-|") Case $Button13 GuiCtrlSetData($List1, "LARGE SODA|") GuiCtrlSetData($Label1, "3.00") Case $Button14 GuiCtrlSetData($List1, "HAMBURGER|") GuiCtrlSetData($Label1, "3.00") Case $Button15 GuiCtrlSetData($List1, "HOT COCOA|") GuiCtrlSetData($Label1, "3.00") Case $Button16 GuiCtrlSetData($List1, "LARGE CANDY|") GuiCtrlSetData($Label1, "3.00") Case $Button17 GuiCtrlSetData($List1, "REGULAR SODA|") GuiCtrlSetData($Label1, "2.00") Case $Button18 GuiCtrlSetData($List1, "HOTDOG|") GuiCtrlSetData($Label1, "3.00") Case $Button19 GuiCtrlSetData($List1, "CAPPICINO|") GuiCtrlSetData($Label1, "3.00") Case $Button20 GuiCtrlSetData($List1, "SMALL CANDY|") GuiCtrlSetData($Label1, "2.00") Case $Button21 GuiCtrlSetData($List1, "WATER|") GuiCtrlSetData($Label1, "2.00") Case $Button22 GuiCtrlSetData($List1, "POPCORN|") GuiCtrlSetData($Label1, "3.00") Case $Button23 GuiCtrlSetData($List1, "CUP OF ICE|") GuiCtrlSetData($Label1, "1.00") Case $Button24 GuiCtrlSetData($List1, "CHIPS|") GuiCtrlSetData($Label1, "1.00") Case $Button25 GuiCtrlSetData($List1, "CHILL|") GuiCtrlSetData($Label1, "3.00") Case $Button26 GuiCtrlSetData($List1, "NACHOS|") GuiCtrlSetData($Label1, "3.00") Case $Button27 GuiCtrlSetData($List1, "CHIPS|") GuiCtrlSetData($Label1, "1.00") Case $Button28 GuiCtrlSetData($List1, "MUFFINS|") GuiCtrlSetData($Label1, "3.00") Case $Button29 GuiCtrlSetData($List1, "|") Case $Button30 GuiCtrlSetData($List1, "|") Case $Button31 GuiCtrlSetData($List1, "|") Case $Button32 GuiCtrlSetData($List1, "|") Case $Button33 GuiCtrlSetData($List1, "|") Case $Button34 GuiCtrlSetData($List1, "|") Case $Button35 GuiCtrlSetData($List1, "|") EndSwitch WEnd
  6. Ok here is what I have after taking Zedna's suggestion to use Koda: #include <GUIConstants.au3> #Region ### START Koda GUI section ### Form=c:\security\koda_1.6.0.2\forms\aform1.kxf $Form1 = GUICreate("Simple POS", 674, 586, 414, 172) $Tab1 = GUICtrlCreateTab(8, 8, 657, 569) $TabSheet1 = GUICtrlCreateTabItem("REGISTER") $Group1 = GUICtrlCreateGroup("", 20, 40, 633, 521) GUICtrlSetColor(-1, 0x989898) $Label1 = GUICtrlCreateLabel("", 38, 55, 597, 208, BitOR($SS_RIGHT,$SS_CENTERIMAGE,$SS_SUNKEN,$WS_BORDER)) GUICtrlSetFont(-1, 12, 400, 0, "Lucida Console") GUICtrlSetColor(-1, 0xFFFF00) GUICtrlSetBkColor(-1, 0x008000) $Button1 = GUICtrlCreateButton("1", 412, 360, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button2 = GUICtrlCreateButton("2", 468, 360, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button3 = GUICtrlCreateButton("3", 524, 360, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button4 = GUICtrlCreateButton("4", 412, 312, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button5 = GUICtrlCreateButton("5", 468, 312, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button6 = GUICtrlCreateButton("6", 524, 312, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button7 = GUICtrlCreateButton("7", 412, 264, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button8 = GUICtrlCreateButton("8", 468, 264, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button9 = GUICtrlCreateButton("9", 524, 264, 59, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button10 = GUICtrlCreateButton("0", 412, 408, 171, 49, 0) GUICtrlSetFont(-1, 18, 400, 0, "Lucida Console") $Button11 = GUICtrlCreateButton("+", 580, 264, 55, 121, 0) GUICtrlSetFont(-1, 28, 400, 0, "Lucida Console") $Button12 = GUICtrlCreateButton("-", 580, 384, 55, 73, 0) GUICtrlSetFont(-1, 28, 400, 0, "Lucida Console") $Button13 = GUICtrlCreateButton("LG SODA", 36, 264, 75, 49, 0) $Button14 = GUICtrlCreateButton("BURGER", 36, 312, 75, 49, 0) $Button15 = GUICtrlCreateButton("COCOA", 36, 360, 75, 49, 0) $Button16 = GUICtrlCreateButton("LG CANDY", 36, 408, 75, 49, 0) $Button17 = GUICtrlCreateButton("RG SODA", 108, 264, 75, 49, 0) $Button18 = GUICtrlCreateButton("HOTDOG", 108, 312, 75, 49, 0) $Button19 = GUICtrlCreateButton("CAPPICINO", 108, 360, 75, 49, 0) $Button20 = GUICtrlCreateButton("SM CANDY", 108, 408, 75, 49, 0) $Button21 = GUICtrlCreateButton("WATER", 180, 264, 75, 49, 0) $Button22 = GUICtrlCreateButton("POPCORN", 180, 312, 75, 49, 0) $Button23 = GUICtrlCreateButton("ICE", 180, 360, 75, 49, 0) $Button24 = GUICtrlCreateButton("CHIPS", 180, 408, 75, 49, 0) $Button25 = GUICtrlCreateButton("CHILL", 252, 264, 75, 49, 0) $Button26 = GUICtrlCreateButton("NACHOS", 252, 312, 75, 49, 0) $Button27 = GUICtrlCreateButton("CHIPS", 252, 360, 75, 49, 0) $Button28 = GUICtrlCreateButton("MUFFINS", 252, 408, 75, 49, 0) $Button29 = GUICtrlCreateButton("CANCEL", 164, 504, 91, 41, 0) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") $Button30 = GUICtrlCreateButton("CREDIT CARD", 252, 504, 163, 41, 0) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") $Button31 = GUICtrlCreateButton("TENDER CASH", 412, 504, 223, 41, 0) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") $Button32 = GUICtrlCreateButton("VOID", 36, 504, 131, 41, 0) GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif") $Button33 = GUICtrlCreateButton("SUBTOTAL", 36, 456, 291, 49, 0) GUICtrlSetFont(-1, 18, 800, 0, "MS Sans Serif") $Button34 = GUICtrlCreateButton("TOTAL", 324, 456, 311, 49, 0) GUICtrlSetFont(-1, 18, 800, 0, "MS Sans Serif") $Button35 = GUICtrlCreateButton("X", 328, 264, 83, 193, 0) GUICtrlSetFont(-1, 36, 400, 0, "Lucida Console") GUICtrlCreateGroup("", -99, -99, 1, 1) $TabSheet2 = GUICtrlCreateTabItem("TRANSACTIONS") $Group2 = GUICtrlCreateGroup("", 20, 40, 633, 521) $Date1 = GUICtrlCreateDate("2007/06/06 17:04:58", 228, 64, 186, 21) $ListView1 = GUICtrlCreateListView("", 36, 104, 602, 438) GUICtrlCreateGroup("", -99, -99, 1, 1) $TabSheet3 = GUICtrlCreateTabItem("BATCH") $Group3 = GUICtrlCreateGroup("", 20, 40, 633, 529) $Date2 = GUICtrlCreateDate("2007/06/06 17:15:22", 228, 64, 186, 21) GUICtrlCreateGroup("", -99, -99, 1, 1) GUICtrlCreateTabItem("") GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Label1 Case $Button8 EndSwitch WEnd That is the look and that is our entire inventory for the consessions stand here at Tuacahn Center for the Arts (http://www.tuacahn.org) now I just need to get it to do something. the idea is either manual entry is available using the ten key, or the cashier can use the preconfigured buttons to click an order in. So if patron wanted 2 popcorns and 1 large coke the cashier would click popcorn x 2 + lg soda then subtotal. As the arder is ringing up the display would show the items and their amounts and the subtotal then if the patron wants no other items then the cashier would hit total then hit the appropiate method of payment. My next question is could someone just show me on one button how to get this code to both display the appropiate output and how to do the math. Online and I will be on my way. For now because of time constraints, I am not going to use the sql backend idea, but intend to later when I have more time. I will just keep the days transactions saved in a log file and print it when the batch button is clicked. Thanks for any assistance... Shane Hale
  7. WOW... @ Everyone, Thank you all for your responses, I was waiting to get flamed for knowing there were other opensource alternatives to doing this.... It is funny because I was just going through the Koda threads, and I just realized that what I wanted had something to do with GUICtrlSetData I just was not seeing it. And @ResNullius Thank you for the tip and I totally agree that this is going to become more and more complex and that there is a place for SQL in the projects future.... Regards, Shane Hale
  8. Hello All, I am not sure that I am posting in the correct category since I am mostly describing what I want to do and my situation. But I do in fact need ( and would Greatly appreciate) a little help. What I am trying to do is create a cash register type of applictaion using autoit because it is the only thing besides php and a little vbscript that I have any experience with. If this has been done please direct me to the topic (did not find anything by searching for POS or Cash register) and I will fade away. If it has not then these are the programs requirements: 1. Needs to add up items. Nedd to subtract them as long as "tender" has not been sent. 2. Needs to format to print to a reciept printer. 3. Needs to keep a tally of all transactions for the day and have a password cobntrolled batch out function at the end of the shift 4. Needs to show change from recieved cash( if sale was $18.53 and patron gave a $20 then show the difference of $1.47) 5. For our purposes no need to figure taxes because prices include taxes - but it could be a feature for others who may use it. 6. Would like to have editable symbols or pictures to use for buttons to go along with standard 10 key. For example if patron wanted 3 soda's at 2 dollars the cashier would hit the SODA symbol kea and the 3 key and the display would show $6.00. 7. Icing on the cake would be to intergrate with IC Verify Credit Card software. I have looked out there around the net and there are several free solutions for this already but most of them are too much and too confusing for easy use and quick deployment. We just need a way to take money and keep track of how much we took in in the shift, that is it no need for inventory and time clock, etc. I can visualize how to do most of this in my head, I think with a little thought all of it is doable with Autoit. So anyways my questions at this are: 1. Is there a math or arithmetic function out ther that would help to streamline the code for this project? 2. Could someone help me with my first issue, updateing the text in label control that will eventually be my display. Here is the code I have and my approach does not work. Please dont laugh at me. Well ok it is alright to laugh but please dont say a bunch of discouraging stuff. I know I am not a super intellegent programmer guy like a lot of you, but I am at least trying and I think I can do this with a little help. Thanks in advance, Shane Hale #include <GUIConstants.au3> GUICreate('Simple POS', 450, 450) $stuff ='' Opt("GUICoordMode",2) $display = GuiCtrlCreateLabel($stuff, 0, 0, 450, 50) GuiCtrlSetBkColor(-1, 0x00FF00) $Button_7 = GUICtrlCreateButton ( "7", -150, 0, 50) $Button_8 = GUICtrlCreateButton ( "8", 0, -1) $Button_9= GUICtrlCreateButton ( "9", 0, -1) $Button_4 = GUICtrlCreateButton ( "4", -150, 0) $Button_5 = GUICtrlCreateButton ( "5", 0, -1) $Button_6 = GUICtrlCreateButton ( "6", 0, -1) $Button_1 = GUICtrlCreateButton ( "1", -150, 0) $Button_2 = GUICtrlCreateButton ( "2", 0, -1) $Button_3 = GUICtrlCreateButton ( "3", 0, -1) $Button_0 = GUICtrlCreateButton ( "0", -150, 0, 150) GUISetState () While 1 $msg = GUIGetMsg() Select Case $msg = $GUI_EVENT_CLOSE ExitLoop Case $msg = $Button_1 $stuff='1' Case $msg = $Button_2 $stuff='3' Case $msg = $Button_3 $stuff='3' Case $msg = $Button_4 $stuff='4' Case $msg = $Button_5 $stuff='5' Case $msg = $Button_6 $stuff='6' Case $msg = $Button_7 $stuff='7' Case $msg = $Button_8 $stuff='8' Case $msg = $Button_9 $stuff='9' Case $msg = $Button_0 $stuff='0' EndSelect Wend
  9. Just looking at theis encoder stuff... Has this evolved into something else? Does not seem to work with current versionm 3.2.4.9 - Gets an error about BinaryString. Did a search and replace to reflect it being renamed to Binary. Then I got another error: Would be useful if it worked again.... Thanks, Shane
  10. Hi can I use this to open a local html file? In other words one that is on my computer?
  11. Thats a nice looking script and if I am reading it right it may come in hady to support folks in a different building here on our campus. However what I am toiling with is sending a file from a client to a server. And really it is a non issue at this point since I am using a commercial product now but I would still like to know how to transfer something from one computer to another purely with autoit. I guess at this point I just am wanting to make a point to myself that it can be done.... It seems that I am so close to haveing it work. It is just an aggrivating annoyance now. Regards, Shane
  12. Not seeing how the help file example - at least "as-is" - helps in this situation. It transfers characters typed into input box to a remote machine. It does it well too I have tried it effectively. What it does not do is send a binary like a image file or and executable. I am sure it could be modified but not exactly sure how. I have been trying this for several days. In the end I would just like to see an example of a file transfer that will work. Files like jpg's, exe's, zip's etc. not just charachters into an input box. I have tryed Larry's example and several others for trasnsfering files but none seem to work over the internet. They all (mostly) work on the same machine but hw does that help? Larry's comes the closest. It just changes the file size of the jpeg but it does connect and it does create a file. In fact it does not seem to matter what type of file it consistantly adds to the size of the file in the transfer process. At least for me. It may be the difference int he script (my changes) which other than the ip target are minior. I am changing the .\somefile.exe to c:\somefile.exe - perhaps this is where I am screwing it up ? Please help...
  13. Only recieves one message. Thought because it is looping I should beable to send message 1 then message 2 and so on. Has to be restarted every time. How can I make it recieve multiple messages without restart ove reciever/server ?
×
×
  • Create New...