I am working on an mvc site. I understand the concept of the Model, however we are forced to work with the existance of our main frame. The data comes back in the form of a parameter block (fixed structure defining each field and it's length). This transaction to the mainframe would occur outside the controller (obviously). So to move the data from the transaction to something the controller uses can either be done with it's own class (my company calls them entities) or to double purpose the model as the information from the mainframe would basicaly (with same additions) be the fields of the model. Hopefuly all that made sense.
So the question is: do I create entity class and transfer all the data(properties) into the model after every tranasction once the fields are returned to the controller or do I double purpose the model by using it as the entity as well with the understanding that these fields that aren't to be used in the view would show up because the model fields and entity fields are mingled together?
Any advise would be greatly appreciated...
'Never argue with an idiot; they'll drag you down to their level and beat you with experience.' ~ anonymous
I'm developing a multiple-city Visitor's system. I want to create a Login page with following details:
Username, Password, City & Gate_Name.
I need to know how should I proceed with creation of tables and then the code.
The City & Gate_Name should be nested. When a city is selected, then only the appropriate gate-name must be displayed in drop-down box below.
Initially, Username & Password must be checked.
If they do not match, an error message must be generated.
If they match, then the associated city & gate-name must be checked.
If they do not match, an error message must be generated.
If all the details match, then a Session by UserID must be created and the user must be redirected to the Home Page.
A user allotted a particular gate cannot Login from any other city or any other gate.
Although you will have to add fields for City & Gate_Name and custom logic to check it. But the overall philosophy and working will remain the same as it is in this article.
Twenty years from now you will be more disappointed by the things that you didn't do than by the ones you did do. So throw off the bowlines. Sail away from the safe harbor. Catch the trade winds in your sails. Explore, Dream. Discover.
I want to implement url rewriting with intelligencia.urlrewriter.problem is when clean URL Contains special characters such as % : * & and more.in this case I get a bad request,because the cleaned url does not contain ? sign. I work with .net 3.5 .
Is there a solution for this problem?
I am migrating my DB from a C++ Structure system to SQL. As an example, I take the 'Order Table'
The CPP struct for an Order comprises of a header, containing all sorts of usefull info, like who owns it, who donne it,how many items, followed by an array of 32 possible 'Order Items', each containing amongst others: a TimeStamp, A Quantity, a narrative, an amount, and a WhoDunneit, as wel as obscure CPP management information to avoid data clashes.
This goes together with carefully crafted rules about who can edit what. (Each user can only edit own items, but suitably empowered supervisory personell can edit all entries.)
The method that worked best was what we called the 'Pragmatic Upate' The Update that updates from the original datafirst, wins. All others fail, and get a view of the latest version. Does SQL act like this, or do i need tricks to implement this.
The table was stored in a file,as an array of structures of this kind.
I hope to re-write the new version in C# ,ASP.NET.
First Stumbling Block: how do I create my array of items in an SQL Database. (come to think of it, how do I create the 'Item' array element in the first place.)
Yes, SQL can store the data you describe quite well.
Here are a few terms you may want to research:
1) Primary key
2) Foreign key
Basically what you describe is a classic Master-detail relationship where the Order is the master and the Items are the details. You would define a primary key on the Order table which uniquely defines the order, then that primary key is used in the Items table as a foreign key (relating all of the Items back to the single Order).
When you do updates to the Order/Items, you will use a transaction which ensures that all of the updates across all of the records are performed consistently or not at all.
I am saving the following html in a database the trying to display it to show the recent activities for my user. I am doing this because the recent activities might contain HREFs. The problem that my result is not showing properly. it's not aligned normal to left although I tried to add align='left' to the
what can i do?
here is the saved data in the text datatype field:
There are only 10 types of people in the world, those who understand binary and those who don't.
on Applicationdetails.aspx page i have a button control.on this button click event ,i want to change linkbutton's(this linkbutton is on webform1.aspx) text from "verify" to "verified".
Does not make any sense. You are on another page and want some text to be changed on a page which is not currently in view!
What it sounds is, after you click this button, whenever you visit the 'Webform1.aspx', you should see a new text. If so, on button click, set a flag (store it somewhere if needed as per workflow) that is accessible in webform1 page. When loading that page, use this flag and based on it's value set the text.
could u tell me how to set a flag pls
i have written my code...when i visit webform1.aspx 2nd time ,that record is not shown .....ie verfied record...so i have to set linkbutton's text to "verifid"....pls help me...what is d syntax to get linkbutton's text...pls help me