3 Replies - 225 Views - Last Post: 25 July 2013 - 08:31 AM Rate Topic: -----

#1 Lethinath  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 2
  • Joined: 25-July 13

Creating a new searching program from scratch

Posted 25 July 2013 - 07:43 AM

Hi all,

I am quite new to programming in general, but I got enough free time to start a little project I had in mind since a long time ago.

I am familiar with part of the c#
syntax (and in general I know where to find what I am looking for). But creating a program from scratch is something totally new for me.

I would like to create a small & simple application were a user can search terms and come up with a series of results (all inside the application itself, no web). Selecting a results will show the corresponding text in another part of the window.

I create a scheme to show what I would like to create.

Let me explain further with an example
Me and my friend, we play quite a lot RPG (D&D, Vampires and so on)
Bringing and browsing the manuals each time is quite an effort. Therefore I would like to create an application that help get an answer in a quicker way.

Using the image I create, let's say that I want to create a tab to search all the spells in D&D. The user would type "help" in the search form, and come up with all the spell containing the word "Help" in the title. Then, he/she will select a result and come up with the desired spell description in the right side of the window.

Moreover, I would like to include a function that allows a user to input a an entry (e.g. a new spell).

What I would like to ask you is:

- since I lack the specific vocabulary to search for a solution on my own, which tutorials are indicated for this task?
- I would not refuse a "ready to go" code, but I am using this opportunity to learn some more about c#. Therefore I would like to do as much as possible on my own. Obviously, if there are part of code that I can already use (templates and so on), I welcome anything of the sort.

So far I am creating the graphic structure and I don't have problem there (probably will, in the future).


Thanks in advance for your help

Attached image(s)

  • Attached Image


Is This A Good Question/Topic? 0
  • +

Replies To: Creating a new searching program from scratch

#2 modi123_1  Icon User is online

  • Suitor #2
  • member icon



Reputation: 9094
  • View blog
  • Posts: 34,147
  • Joined: 12-June 08

Re: Creating a new searching program from scratch

Posted 25 July 2013 - 07:59 AM

Quote

Me and my friend, we play quite a lot RPG (D&D, Vampires and so on)


I'm glad to hear someone still plays! Side question - do you deal with the 'Encounters' setting? I've been toying with popping into my local game store and shuck some dice with the open play.

The main crux here is how are you planning on accessing this data? Are you going to hand enter all of this into a database? Expect the app to scour PDFs, or what exactly?


Quote

Moreover, I would like to include a function that allows a user to input a an entry (e.g. a new spell).

This makes me think of leaning towards a database for this 'DM companion' app.


Quote

What I would like to ask you is:

- since I lack the specific vocabulary to search for a solution on my own, which tutorials are indicated for this task?

The direction you go is more or less predicated on where this data will reside.

Quote

- I would not refuse a "ready to go" code, but I am using this opportunity to learn some more about c#. Therefore I would like to do as much as possible on my own. Obviously, if there are part of code that I can already use (templates and so on), I welcome anything of the sort.

In the grand scheme of things a simple search/data entry form is not overly complex. You can totally roll this on your own.
Was This Post Helpful? 0
  • +
  • -

#3 Lethinath  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 2
  • Joined: 25-July 13

Re: Creating a new searching program from scratch

Posted 25 July 2013 - 08:16 AM

View Postmodi123_1, on 25 July 2013 - 07:59 AM, said:

I'm glad to hear someone still plays! Side question - do you deal with the 'Encounters' setting? I've been toying with popping into my local game store and shuck some dice with the open play.

The main crux here is how are you planning on accessing this data? Are you going to hand enter all of this into a database? Expect the app to scour PDFs, or what exactly?


Hi, first, let me thank you for the prompt answer.

We do not deal with the encounters at all. We play only with friends. To tell you the truth, right now we invested some money on AGOT LCG and we are practically playing only that.


About the DB: I was thinking of creating an internal DB in order to easier format what I want to display in the text windows on the right. My plan was to create a DB of entries with specific fields attached to a "title"
Example:

Title: "help"
School: Enchantment
Level: Cleric 2
Components:
etc etc

The Search form searches only through the "Title" entries. And on the right you get the spell formatted as I wish.


Quote

This makes me think of leaning towards a database for this 'DM companion' app.

In reality I could do without it. But I would like to learn how to create the function in this context


Quote

The direction you go is more or less predicated on where this data will reside.

Since I would like to add the "add" function as well, I thinkthe DB should be included in the program and not on external supports (such as pdf, as you suggested).
Obvioully, I don't know if this is the smartest way to do it. Feel free to correct me :)

Quote

In the grand scheme of things a simple search/data entry form is not overly complex. You can totally roll this on your own.

I believe the same. That is why I was asking for tutorials more that compiled code.
I will search for "search/data entry form" and see what comes up.

In the meantime, thanks.
Was This Post Helpful? 0
  • +
  • -

#4 modi123_1  Icon User is online

  • Suitor #2
  • member icon



Reputation: 9094
  • View blog
  • Posts: 34,147
  • Joined: 12-June 08

Re: Creating a new searching program from scratch

Posted 25 July 2013 - 08:31 AM

Quote

About the DB: I was thinking of creating an internal DB in order to easier format what I want to display in the text windows on the right. My plan was to create a DB of entries with specific fields attached to a "title"

Example:

Title: "help"
School: Enchantment
Level: Cleric 2
Components:
etc etc

The Search form searches only through the "Title" entries. And on the right you get the spell formatted as I wish.


Sure.. that sounds fine.



Quote

Quote

This makes me think of leaning towards a database for this 'DM companion' app.

In reality I could do without it. But I would like to learn how to create the function in this context

Huh?


Quote

Since I would like to add the "add" function as well, I thinkthe DB should be included in the program and not on external supports (such as pdf, as you suggested).
Obvioully, I don't know if this is the smartest way to do it. Feel free to correct me

Sure.. go with the local DB. Just make sure that it goes where the .EXE goes.


Quote

Quote

In the grand scheme of things a simple search/data entry form is not overly complex. You can totally roll this on your own.

I believe the same. That is why I was asking for tutorials more that compiled code.
I will search for "search/data entry form" and see what comes up.


You are looking in the wrong direction. Instead of trying to find some complete "search/data entry form" tutorial you should be looking for tutorials on the more interesting parts. Database interactions would be one. Basic database table design.. etc. The tutorials section (above) have both.


Think about it. You have a search form that holds a textbox, a button to 'search', and a datagrid to hold the returned values. When the button click event triggers all it will do is feed the textbox value to a "load data" function. That "load data" function will create a sql database connection, use the entered text in a sql query, and feed both to a sql adapter which will be used to fill a dataset. The dataset then is the datasource for the grid gui.

The important part is you feed a string to a query, an open db connection, and get the results back.. just because the value comes from a 'search box' that information is not really important, right?

Same with data entry.. take in some values, create a connection, feed it to a sql command object, and 'execute non query'. Where the data comes from is irrelevant to the important portion of the data shuffling off to the DB.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1