Tic Tac Toe Difficulty Level?

Apr 9, 2010

In my tic tac toe game I'd like there to be three different levels; easy, medium, and impossible. There are 2 forms; the difficulty level form and the main game form. When the game first starts the user will be prompted with the difficulty level form which contains 3 radio buttons; easy, medium, and impossible.

I've coded three different functions based on the difficulty level; easyMove(), medMove(), and impMove(). These have all been coded in the main game form. How could I run the respective function based on the radio button that was selected in the previous difficulty level form?

If it was on the same form it wouldn't be a problem but because it is on a different form I'm unsure of how to do this.

View 15 Replies


ADVERTISEMENT

Application-level KeyUp/KeyDown Events (not Windows Form-level)?

Apr 1, 2012

I am creating an Excel add-in written in VB.NET. I would like to bind KeyDown and KeyUp events to the spreadsheet to record when the user presses and releases the arrow keys while navigating the spreadsheetIdeally, these events would be built into Excel alongside the native SheetActivate and SheetSelectionChange events, for example. Alas, they are not.

View 1 Replies

What's The Difference Between Dim On The Member Level And Static On The Procedure Level

Jan 6, 2010

In Visual Basic 2008, there's two different ways that I know of to accomplish the same thing:The Dim on the member level:

Dim counter1 as integer = 0
Dim counter2 as integer = 180
Public Sub SampleSub1()

[code].....

View 1 Replies

Difficulty Converting From Vb To .net?

Aug 20, 2010

I'm using Visual Studio 2010 and Excel 2007. I'm having difficulty figuring out how to convert an office excel project into a vb.net project. I wanted to take the ugly windows 98 style buttons I currently have in my spreadsheet and replace them with controls on a new tab on the ribbon. I can make it that far, but I didn't anticipate the large gap between languages.

The code below is supposed to take a bunch of information from a windows form and insert it into a new row on sheet12, sort the table of info, and name the range. Right now visual studio show no errors until I actually try to run the code at which point it says "Object reference not set to an instance of an object." regarding the code "oSheet.Rows("1:1").Copy()" I don't think I understand declaring my variables in vb.net.

[Code]...

View 1 Replies

Top Level SQL Table Row - Save The Top Level Automatically?

Mar 18, 2011

I have created a simple program which uses a two tier structure of SQL Tables.At the top level, one record holds the date of the activities and linked to it using its primary key as a foreign key, three subordinate tables hold time stamped records.The issue I have been unable to solve is that before adding any of the lower level records for a given date, a newly added top level record must be saved to the database.Doing this manually is simple - but can I rely on my users to remember to do this before they start plugging in the lower level data?I thought not, so I am looking to save the top level automatically.I've failed miserably but I refuse to believe that it's not possible.

View 14 Replies

Rate The Difficulty Of Making Program?

Mar 3, 2010

I just started with VB.NET using Murach VB.net 2008 book and i want to make this program for my work, please tell me what knowledge needed to make this program beside VB.NET: want to make a program for my supervisor which Lists the name of every employee in our division. the program should be accessed by any computer in our division using LAN. each employee will have user and pass to enter this program they only can view their data with charts showing their attendance, productivity , etc, supervisor will have master account where can edit the info.the supervisor can send private message like e-mail to each employee. all the info should be saved in database so it can be used to compare the employee activity for each year.

View 3 Replies

VS 2010 HTTP GET Request Difficulty?

Apr 10, 2012

Okay, i've tried httpwebrequest, webclient, and a couple of others methods; using the headers parameter of each to set headers and then either opening a response stream or simply setting the system.net.webclient method to download a response into a string. Put simply, how do I make a simple GET request with a few headers and read the data back! I am very, very stuck in a hole right now..

View 4 Replies

.NET One Dimensional String Array Manipulation Difficulty?

May 14, 2010

I am having some problems with manipulating a one dimensional string array in VB.NET and would like My objective is to get 4 variables (if possible) from a file path. These variables are: myCountry, myCity, myStreet, Filename. All declared as string. The file location is also declared as string. so I have:

Dim filePath As String to illustrate my problem, and what I am trying to do, I have the following examples:

1- C:mylocationisUKBirminghamSummer Road his house.txt.

[Code]...

View 1 Replies

DialogResult - Difficulty Using The Response To A Message Box Question

Apr 15, 2009

I am working on an application and have encountered difficulty using the response to a message box question. I am trying to call one form if the user clicks yes another form if the user clicks no, please have a look at my code and see if you can see where i am going wrong because no matter whether i press yes or no the frmTransactionMenu is being shown and never the frmExit

Dim response As DialogResult
MessageBox.Show("Would you like to complete another transaction", "ANOTHER TRANSACTION ?", MessageBoxButtons.YesNo, MessageBoxIcon.Question)

[CODE]...

View 10 Replies

Difficulty Connecting To Remote MS Access Database On LAN?

Jun 6, 2011

I am currently developing in Visual Studio 2008 (Visual Basic) and I have no problem reading, editing, saving, etc. to a 2007 Access database that is stored locally using the following code:

Dim NotifyDS As New DataSet()
Dim NotifyCon As New OleDb.OleDbConnection
NotifyCon.ConnectionString = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=|DataDirectory|DataSettings.accdb"
NotifyCon.Open()

Ultimately I am going to be installing this program in my office on multiple computers, but would only like to have one "server" program where the database is installed. All of the other computers will have access to this one database over the LAN. For some reason I am unable to access this remote database file over my LAN. I have tried all sorts of things (including a username and password for the server computer),

[Code]...

View 7 Replies

IDE :: Difficulty Using Existing Projects Added To A Solution?

Mar 28, 2011

I'm not sure if this is really a VB IDE issue, or a more general VS10 issue, but I couldn't find any other relevant category to post in, so here goes!I have several VB projects which I want to use in the same solution in Visual Studio 10. I created a project (& corresponding solution) which will reference them and added the existing projects by right clicking the solution in solution explorer choosing 'Add->Existing Project'. Then I went to the containing project's Properties window and added references to the existing projects, so they could be used by the project.

[Code]...

View 3 Replies

VS 2010 Difficulty Accessing 'disposed' Form?

Jan 18, 2012

I'm having a strange difficulty. Here is the order of events:User presses button on form1 New Form object is created for from 2 New form object '.show' command is fired Form 2 opens correctly In the Load Event of Form 2, the form attempts to do various things in a try, catch, finally clause On catch, I close form2 down '.close' as it cannot be used as something has gone wrong with the execution However, my problem is this. It is acceptable for things to go wrong on the from 2 load event which is why I have implemented the try - catch functionality. However, when I close the form2 down as a result of the problem, a real error ocurrs 'Cannot access a disposed object' and the VB IDE refers me to Form1's '.show' event for Form2.

It is almost as if the form hasn't fully 'shown' before I am closing it down. Does anyone have any idea what the problem is here? Do I need to close down Form2 ourside of it's Load event handler so that Form1 thinks it has loaded correctly?

View 3 Replies

Multiple Level Of For Each And Linq In Each Level

Feb 12, 2011

I have multiple level of For Each and in each level, i have a Linq that is the 'In' criteria as in:

[Code]....

It will go inside each for (because the value is not nothing), however, it will only loop (next) in the very inner 'For Each t In tFor'. After it is finish inner loops, the outer Fors' or Next will not execute... even thought there are more than one values in that 'In'... like 'sFor' or 'fFor'. i've noticed while debuging, while break at the for (for example 'sFor', before stepping in), i get the error message:

"Enumeration yielded no results" when i expand the result for that variable and it will not step into it. but if i do not expand the result, it will step in. It seem that some how, once an element is accessed for that 'In' collection, it breaks (meaning does not loop for the rest of the elements) the next for that collection is this a bug or am i missing something in Linq? BTW: i believe it has something to do with the SqlDataReader in the Linq. I'm working with IAsyncResult.

View 5 Replies

Difficulty Importing Excel Worksheet When Sheet Name Varies?

Feb 19, 2010

I'm attempting to import an excel spreadsheet into a dataset. The spreadsheet is selected by the user by browsing for a file. I can get it to work properly only if I know the exact sheet name, but it varies from sheet to sheet. I need to tell it to always use the first sheet in the workbook.

I've declared the following at the beginning of my project:

Imports System.Data
Imports System.Data.OleDb
Imports Microsoft.Office.Interop.Excel

[Code]....

View 8 Replies

Finding Difficulty In Assessing Future Warning Date?

Nov 24, 2009

I made a programme through which I get a feed back clicking a button for a future warning date. I am giving the code below so that you can givthe problem is, I have to take 12 DateTimePicker to do that job in a single form which is creating a saving problem means when I click save button it takes long time to save. Now, I thought If I can do it by using TextBoxn a date format would easeup my save problem. Or it can be MaskedTextBox as well. Below is my code if any one can give me the solution.

Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
If DateTime.Now > DateTimePicker1.Value.AddYears(1).AddDays(1) Then

[code].....

View 8 Replies

VS 2010 Difficulty Storing Textbox Input Into Jagged Array?

Jun 14, 2012

Recently I started a project with the goal being to have text that was inputted into a textbox stored within a three dimensional jagged array. The idea is that every time a button is pressed, whatever text that is inputted into the textbox is split into separate elements, where each word occupies its own element in the array. So for example, if a poem were entered into the textbox and the button clicked, each word of the poem would be assigned to a discrete element in the vertical dimension, and each line of the poem assigned an element in the horizontal dimension. After the text is stored into the 3D jagged array, the text should be cleared from the textbox and a counter should then ensure that on the next button press, the new text inputted into the textbox is stored in a discrete element of the array. Below is the code I have written so far, but I know that I am far from having anything might accomplish what I have just described.

[Code]...

View 9 Replies

Sql Server - Crystal Reports Table Source Difficulty With User Defined Functions?

Jan 19, 2012

I have the following Query:

SELECT *
FROM tbl_Muffins
WHERE OvenLoadId IN (
SELECT OvenLoadId

[code]....

The idea of the query is that I want to specify an OrderId, and I want all Oven Loads that have items from that order in them, as well as ALL OTHER ITEMS in those loads, even though they could be from other orders.The query works as expected, but I'm not able to use it for my Crystal Report I've written it for.I have put this query into a User Defined Function, however I'm unable to use a call to that function as a table source in my Crystal Report. I am using Visual Studio 2003 (I know it is old, the client refuses to upgrade).

View 1 Replies

VS 2005 Tremendous Difficulty Getting Word Auto-mation To Insert A Page Break In Document

Oct 23, 2009

I am having tremendous difficulty getting word automation to insert a page break in my document. The app is generating letters in word and saving them....the code below shows where I am writing the first page (str.tostring) then all of the code after that are the various ways that I have tried to insert a page break so that it will go to the second page and I can unload information into the second page of the document. [code]

View 1 Replies

Import A Platinum Level Advisor .jar To Use With This Platinum Level Product Key?

Nov 10, 2009

U0161 import a Platinum level Advisor .jar to use with this Platinum level product key.How I can get this and import it to continue my completion of setup of mysql download?From where I can download that file?To enable this application, please provide a MySQL Enterprise Product Key or your MySQL Enterprise credentials.

View 1 Replies

.net - Difficulty In Using VB Code Dom (having If Expressions In Generated Code)?

Nov 27, 2009

I have difficulty in using the vb code dom. Basically, I want to compile this piece of code dynamically:

Imports System
Imports System.Collections.Generic
Imports Microsoft.VisualBasic
Namespace Formula
Public Class TsCalculator

[Code]...

View 1 Replies

Getting To A Level Below

Jul 8, 2011

Hi Friends,

Hope you all are doing fine.

Brief

I have been into learning VB 2010 Express for around 2 months now; I have been doing it primarily on weekends with a nice book by James Foxall. At the moment I am in Chapter 22 of 24. I have been able to make some sense on what he says but have
been able to follow him well. I plann to read the book in full twice before doing with it at the end of August 2011.

Today's Question

In one of my previous threads 'Becoming a Programmer' @Renee Culver encourages me to try to get to a level deeper. There are many other experienced programmers who have given adivce with equal 'punch' but I like to begin with @Renee Culver's
approach.

James Foxall guides me learning smoothly but I now at the 22nd chapter out of 24 feel a little uneasy. It feels like James tells I do. In Chapter 22 dealing with automation he guides me to work on Excel through VB. The reference to the Server is
set through the VB interface. I like to know how to get to a level deeper on this today. Instead of using the VB interface can't I establish reference purely through VB code? During this weekend I like to try accessing the Google start page
Combo to get search results for 'Novak Djokovic'. Could you help me?

Thank you Friends.
ss

View 5 Replies

C# - What Should Go Into A Top Level Namespace

May 7, 2009

What should go into the top level namespace? For example, if I have MyAPI.WebLogic,MyAPI.Compression, etc. If I put classes into the top level namespace, am I violating the principle of encapsulation?

View 5 Replies

How To Monitor Mic Level

Feb 10, 2008

I want to be able to have the Level of my Mic in my Form. I want a Progressbar that tracks how high my voice is just like in Windows Movie Maker or In Msn Messinger when you are doing a voice Chat there is a Progressbar like object that shows how loud it is...

View 17 Replies

Low Level Disk I/O

Feb 25, 2009

I want to do low level disk I/O using Visual Basic 2008.Particularly, I want to do track/sector read/writes to a disk (or equivalent hardware)Also important is to discover number of tracks/sectors available.

View 1 Replies

Read Xml More Than 2 Level?

Sep 15, 2009

ihave problem when read xml file. some xml file with level more than 2 level.i want put the result in datagrid. i have no problem when read simple xml like this:

[Code]...

View 7 Replies

.exe Files Security Level?

Jun 17, 2011

.exe files security level

View 13 Replies

C# - Why Isn't There A Trace Level In Log4Net

Sep 8, 2009

I was just wondering why there isn't a trace level in log4Net. This level seems to be missing and I sometimes feel the need to use it, for example to output what events are being executed in an application. This feature is a part of log4J. I know I can create a custom level like is talked about here but I don't want to put time and effort in something I feel should be part of the library itself. Do you know about a log4net extension library which implements this or why this wasn't a part of the port to .net ?

View 3 Replies

Get Just The Top-level Text Of An XmlElement?

Sep 11, 2009

Suppose I have some XmlElement; let's call it element. If I want to get all of the child nodes of that element, I can call element.ChildNodes. If I want the text of the element and all its children, then I can go with element.InnerText.

[Code]...

EDIT: Sorry I didn't specify this initially: I'm looking for a solution not involving LINQ (we're in the Dark Ages over here with .NET 2.0).

View 6 Replies

Get Microphone Input Level In VB?

Feb 1, 2010

I am a beginner in VB, and I would like to make an oscilloscope display - showing voltage level of microphone input.

View 3 Replies

Get The Microphone Input Level?

Jan 25, 2010

for an application I need to get the microphone input level and "display" it with a ProgressBar.

View 2 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved