Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Recent content by pbb72

  1. pbb72

    How do I transfer tables from remote SQL database to local MDF file?

    Hi all, Currently, my (small) intranet site is storing it's data on a remote SQL server. The danger with this, as has happened several times now, is that the application is twice as vulnerable; if either the webserver or the dataserver malfunctions or is unreachable, the application won't work...
  2. pbb72

    Can I set default field values in a FormView with Cookie?

    Jason, thank you so much!! I have spend so much time on this problem, and clearly don't know all the best ways to track bugs yet. The problem was, that apparently the DataBound event is triggered TWICE! The first time, FindControl won't find any controls, but the second time everything is okay...
  3. pbb72

    Can I set default field values in a FormView with Cookie?

    Hi all, I've got a FormView control with a few empty TextBoxes, among others one for name and email. Is it possible to fill these in with values retrieved from Cookies? All I get is "Object reference not set to an instance of an object". protected void FormView1_DataBound(object sender...
  4. pbb72

    Set FormView mode depending on query results?

    I found it, I needed to use FormView.DataItem["label"] to access the fields...
  5. pbb72

    Set FormView mode depending on query results?

    Hi all, I want to set the mode of my FormView based on the values the SelectCommand of my SqlDataSource returns. If a certain field contains Null, I want to have Edit mode, and when the field has a value, I want to have ReadOnly. Apparently I cannot use databinding to set the DefaultMode, so I...
  6. pbb72

    ControlParameters and NULL value

    What exactly is meant with the table structures? Don't you mean the structure of the database tables? That's right there at the beginning of my reply: (Participants.CourseID is linked to Course.ID)
  7. pbb72

    ControlParameters and NULL value

    Thanks for the help, c8! Following is not the complete code, but since it is all in Norwegian I have to translate it to be understandable. I think this is all the relavant stuff: Courses table: ID, Name, Maximum Participants table: StudentID, CourseID, EnlistDate <asp:SqlDataSource...
  8. pbb72

    ControlParameters and NULL value

    No, it is not mandatory. Sometimes for example the exact location is decided afterwards, based on the number of participants. A default can also be misleading, suggesting that this amount has been determined. Also, having a value for maximum does not solve my second problem, generating the...
  9. pbb72

    ControlParameters and NULL value

    Hi all, I am writing a page to display the people registered for a selected course, and the people that are on the waitinglist. I do this using various GridViews bound to SqlDataSources. The courses table has a "Maximum" field for every course, which says how many people can participate. When...
  10. pbb72

    Merging XML files

    I need to merge a huge amount of XML files into one. The files all have the following structure: <!DOCTYPE ...> <FILE> <REC ...> <FLD ...>...</FLD> ... </REC> ... </FILE> I've written the following code to do this: private void btnOpen_Click(object sender, EventArgs e) { if...
  11. pbb72

    XMLHttpRequest and Charsets

    Hehehe, yeah with the help of your code, I was able to Google the final details together. Thanks again man!
  12. pbb72

    XMLHttpRequest and Charsets

    Thanks, that worked like a charm!! Apparently, you forgot 1 line in the code. After the write command, I needed to add "position = 0;", and then everything worked as required. tsuji, you are da man! :-D
  13. pbb72

    XMLHttpRequest and Charsets

    Well, apart from half of the text being unreadable (the texts are not English but Norwegian, with lots of mangled up å, ø, æ), the main problem is that the mangeling-up also takes the next 2 or 3 characters with it. For example: "<div>få</div>" gets converted to "<div>f?iv>". This makes proper...
  14. pbb72

    XMLHttpRequest and Charsets

    Thanks for the reply, Dan. It didn't help however. All of the special characters get character code 65535 when I read them... :-(
  15. pbb72

    XMLHttpRequest and Charsets

    Hi, I'm using XMLHttpRequest in JavaScript to retreive information from remote websites into Internet Explorer. Everything works great, except for two websites, where the server doesn't return any Charset information in the headers. The result is that XMLHttp interprets the results as UTF-8...

Part and Inventory Search

Back
Top