• Content count

  • Joined

  • Last visited


  • check
    Agree 3
  • info_outline
    Informative 2
  • tag_faces
    Funny 0
  • thumb_up
    Thumbs Up 5
  • thumb_up
    Likes (Old) 31


This user doesn't have any awards

About Flanelman

  • Title


  • CPU
    i7 4720HQ
  • RAM
  • GPU
    GTX 970M
  • Storage
    1tb 7200rpm
  • Display(s)
    1920x1080 matte 15'6
  • Keyboard
    Corsair K50
  • Mouse
    Corsair M95
  • Operating System
    WIN 7 X64

Profile Information

  • Gender

Contact Methods

  • Steam

Recent Profile Visitors

603 profile views
  1. Hey Guys, so I want to get every category that is saved in my Database and save it into an ArrayList<String> in my main activity but I'm unsure of how to do so. Here's what I've tried: //in the database manager class public ArrayList<String> get_all_Category() { SQLiteDatabase db = getWritableDatabase(); ArrayList<String> all_categories = new ArrayList<String>(); String dbString = ""; String get_all_cat_query = " SELECT " + COLUMN_CATEGORY + " FROM " + TABLE_ITEMS + " WHERE 1 "; Cursor cursor = db.rawQuery(get_all_cat_query, null); cursor.moveToFirst(); while(!cursor.isAfterLast()) //while there is still data to check { if(cursor.getString(cursor.getColumnIndex("item_index"))!=null); { dbString = cursor.getString(cursor.getColumnIndex("item_category")); all_categories.add(dbString); } } return all_categories; } //in my main class db_manager = new databaseManager(this, null, null, 1); //create the database long index_value = db_manager.Get_Length_of_DB(); int index = (int) index_value; if(index != 0) { category_List.add(db_manager.get_all_Category().toString()); } I'm getting this error on this code which I don't really understand: Failed to read row 0, column -1 from a CursorWindow which has 2 rows, 1 columns. java.lang.RuntimeException: Unable to start activity ComponentInfo{bit.powlz1.zak_mobileassignment/bit.powlz1.zak_mobileassignment.NewItemScreen}: java.lang.IllegalStateException: Couldn't read row 0, col -1 from CursorWindow. Make sure the Cursor is initialized correctly before accessing data from it. Any help would be greatly appreciated!
  2. Okay I'll give that a shot when I get home, thanks!
  3. How do I find my Ethernet adapter? under my network adapters in control panel there is a "TAP-windows adapter v9"? other than that it's just the killer one and loads of different WAN ports and a RealTek PCIe GBE family controller.
  4. GTX 970m i7 4770HQ 16gb ram 1tb 7200RPM Killer 1525 n/a/ac wireless network adapter
  5. Hey guys, so recently I've had some real issues staying connected on my Killer 1525. It can keep a connection when on Wireless but I get really bad ping in game (not sure why), and whenever I try connect to Ethernet the connection completely drops every 5 minutes for a few seconds so I get kicked from games all the time and makes it impossible to game both wireless and wired. I've tried downloading the most recent drivers to no avail, I've also tried looking through all the Killer software but I couldn't really find anything in that? Any suggestions would be greatly appreciated this is getting really frustrating. It's not all the time by the way, I was able to game for 3 or so hours last night, then I get up this morning and it is impossible to stay connected long enough to even find a game online. EDIT: I have gigabit internet, here is my Speed test: http://www.speedtest.net/result/6279387749 Thanks in advance for any help guys!
  6. Tomb Raider, and Rise of the Tomb Raider.. Imo both brilliant games and really controller friendly.
  7. Hey guys so like the title says I've tried to put the text within the EditText into a var called "username" which I want to be able to use within my inner class but I don't know how to make it accessible from within. here's what I do with the EditText: (KeyListener is the name of my inner class) KeyListener KL_Instance = new KeyListener(); EditText input_text = (EditText) findViewById(R.id.inputText); input_text.setOnKeyListener(KL_Instance); String username = input_text.getText().toString(); and here's what I'm trying to do with that within the inner class: public class KeyListener implements View.OnKeyListener { @Override public boolean onKey(View view, int keyCode, KeyEvent keyEvent) { //if the enter key is pressed, then check to see if username is 8 or more chars if (keyCode == keyEvent.KEYCODE_ENTER) { //if it is, display it if(username.length => 8) { Toast.makeText(MainActivity.this, "Hi, " + username, Toast.LENGTH_LONG).show(); }else //else, ask for a username of atleast 8 chars { Toast.makeText(MainActivity.this, "Please enter a username that is 8 or more chars", Toast.LENGTH_LONG).show(); } } return false; } } But it says "cannot resolve symbol 'username'" and I cant access "input_text" within that class either so If someone could help me out here it would be greatly appreciated Thanks in advance
  8. Nah not professionally, I'm still pretty new with them all recently started doing an I.T. course so been mainly picking it up there And yeah that might be a better Idea to actually read into ruby a little more, thank you for your help!
  9. Okay I'll go look into them now, Appreciate the help! edit: One more thing, when I try and run my new code I get the following error: undefined local variable or method 'hangmanWords' for main:Object (nameError) heres the code within the file: def Read_Into_Array(file) file_Name = file.to_s $word_Arr = File.readlines(file_Name) end Read_Into_Array(hangmanWords.txt) And I've checked that the file name is right, and they're in the same dir so I'm a little confused, does it think it's a variable? and if so, how do I solve this? Thanks again
  10. Oh I'm not actually sure I might have to look into that. edit: if that was needed, surley it wouldnt run at all? rather than running through part and then crashing? I'm pretty sure that Ruby is like Javascript in that regard, where you don't have to declare variables. I've only ever coded in c#, java and c++ So in terms of syntax etc It's probably not like how most people would write ruby
  11. Hey guys, So I'm new to coding in Ruby and i'm getting the following error: in 'main': undefined method 'wordArr' for main:Object (NoMethodError) here's my code: def main wordArr = Array.new lettersArray = Array.new def readInText(file) fileName = file.to_s $wordArr = File.readlines(fileName) end readInText("hangmanWords.txt") puts " _ | | | |__ __ _ _ __ __ _ _ __ ___ __ _ _ __ | '_ \ / _` | '_ \ / _` | '_ ` _ \ / _` | '_ \ | | | | (_| | | | | (_| | | | | | | (_| | | | | |_| |_|\__,_|_| |_|\__, |_| |_| |_|\__,_|_| |_| __/ | |___/ " puts "Welcome to hangman! type quit at any point to exit, good luck!" random = rand(wordArr.length) #choose a rand num between 0-array length (number of words) word = wordArr(random) #gets a random word from the array of words puts "The word has been chosen! please enter the letter you wish to guess!" puts "Please enter a letter!" guess = gets.chomp if(guess == "quit") puts "Thank you for playing!" sleep(2.5) exit end end main From researching online as far as I could tell people get this error when calling something before it's declared, but I create the array first, then use it within the method, then call it to get the length(which is where the error is because it's printing the welcome message before then getting the error)? Only thing I can think is there's something going on with maybe having different instances of the same array? Any help would be greatly appreciated
  12. Hey thanks for the response, I don't quite understand how that gets the selected sport from the drop down? As in how does that $_GET know that the passed in sport is from the drop down? (sorry I'm not all that good with PHP)
  13. Hey guys, I'm having a lot of trouble trying to load data after I select something from a dropdown box. I've tried googling in lots of different worded ways but it just keeps coming up with how to fill the drop down box from things from the database, which I've already done: <?php include('CreateTable.php'); $all='SELECT sport FROM eventsTable'; $result = $pdo->query($all); foreach($result as $Sport){ ?> <option value ="<?php echo $Sport['sport']; ?>"><?php echo $Sport['sport']; ?></option> <br> <?php } ?> So this loads all the sports in my database into the drop down box, but now I want to when they select one of the options, load the related data from the database and display it in a table on another page. for example (my data is about the 2016 Olympics): If they select running from the drop down box, I want it to the load a page with all the runners on it it, in a table. my tables and fields: $createQuery ="CREATE TABLE eventsTable ( eventID INT(6) NOT NULL AUTO_INCREMENT, sport VARCHAR(20) NOT NULL, event VARCHAR(30) NOT NULL, PRIMARY KEY (eventID) )"; $pdo->exec($createQuery); $createQuery ="CREATE TABLE AthleteTable ( athleteID INT(6) NOT NULL AUTO_INCREMENT, firstName VARCHAR(20) NOT NULL, lastName VARCHAR(20) NOT NULL, gender VARCHAR(20) NOT NULL, image VARCHAR(20) NOT NULL, eventID INT(20) NOT NULL, medal VARCHAR(6) NOT NULL, CONSTRAINT SportEvents FOREIGN KEY (eventID) REFERENCES eventsTable(eventID), PRIMARY KEY(athleteID) )"; $pdo->exec($createQuery); here was my attempt: <?php $all='SELECT AthleteTable.athleteId,lastName,firstName,gender,image,sport,eventID,medal FROM ((AthleteTable INNER JOIN eventTable ON eventTable.eventID=AthleteTable.eventID) WHERE AthleteTable.sport = //the sport selected through the drop down box? //then foreach thorugh and print them in a table ?> Any help here would be greatly appreciated been stuck on this for ages, thanks.
  14. I use PDO, I'm not really that great with php so the POST thing is all kinda blurry to me. What would I have to do solve this error?