Here is my newest code: sql="SELECT * FROM NEWS WHERE ID="&jon&";" Set rsSrc = Server.CreateObject("ADODB.Recordset") rsSrc.Open sql, oDBConn,0,3 if(not(rsSrc.EOF))then rsSrc("DATE")= Now() rsSrc("CONTENT")=Request.Form("test1") rsSrc.update end if rsSrc.close set rsSrc=nothing Now, the error message I get is that my database/object is readonly. But I think that's a problem with my host.
RomanD
Posts
-
asp ado problem. -
asp ado problem.Every time I run the code below, it tells me "No update permissions!"
Update Record
<% set conn=Server.CreateObject("ADODB.Connection") conn.Provider="Microsoft.Jet.OLEDB.4.0" conn.Open(Server.mapPath("chem.mdb")) cid=Request.Form("shit") response.write(Request.Form("test1")) jon = 1 response.write(jon) if Request.form("test1")<>"" then sql="UPDATE NEWS SET " sql=sql & "DATE='" & now() & "'," sql=sql & "CONTENT='" & Request.Form("test1") & "'" sql=sql & " WHERE ID='" & jon & "'" on error resume next conn.Execute sql, Recordsaffected if err<>0 then response.write("No update permissions!") else response.write("Record " & cid & " was updated!") end if end if conn.close %>
-
ControlsI have a control that expands when pressed. My question is how do I manange/move the other controls so nothing overlaps. Also, how can I add a checkbox to a label before Text label. When I add it to label.Controls I just see the checkbox. And last thing, in my class, I have label.autosize = false; but when I add that control to the form, the VS 2005 sets the autosize property to true. Thanks
-
word formatting barWhat I meant by textbox is RichTextBox, sorry. But is there a control for that or will I still have to write my own?
-
word formatting barIs there a control I can add to the textbox that is like the "formatting bar" in Word. I need the user to be able to choose font, color, etc... The question is, do I have to make that panel/bar from scratch or can I import it as a control from anywhere?
-
Pasting to anbd from clipboardHow to I paste text to and from clipboard while preserving the formating. Because when I paste from the clipboar, the text that use to be bol is not, etc... Say from 1 textbox into another. Or from a textbox into a word document. Thanks
-
Copying richtext to WordI have a rich textbox with bold text on my form and I want to copy it over into a textbox in a word document. The problem is that when I do it, it looses it's formating and is not bold anymore. How would I go about copying text while preserving the same style that it had. Also, how would I store Rich text in access database and not have it loose the formating. Thanks
-
problemI just tried setting the focus to a button in the DocumentComplete event so the form would be able to pick up the keypress event, but still doesn't work.
-
problemI created a web control to display html files on my form. My idea was to click space bar and to go to next file (html, picture or movie) in the folder, but my form looses focus and doesn't pick up the keypress event. I turned on key preview and made a button which should get the focus after the web control displays what it is suppose to diplay. The problem I am having is that when I am playing a movie or a flash file, it won't transfer the focus to the button or to the form. But, if I make a messagebox right after I give button the focus, then the focus is set to the button. How can I fix this?
-
Form; always on top.For me to write screen buffer, would I have to use DirectX or something of that sorts? Thanks in advance.
-
How to I change form1.TextYou're Welcome. I suggest getting a book, it will helpyou greatly to get started with C#.
-
How to I change form1.Textform1.ActiveForm.Text = "Text goes here";
-
Form; always on top.How can I make sure my form stay on top of everything. I set the TopMostLevel to true, and it works when I work in windows. Then, I load a game and my form is hidden. Does the game take over the priority or what, and how do I change that? Thanks
-
event not picked up by formThanks a lot
-
event not picked up by formmy program is very simple. When you press spacebar it shows next file in directory in webBroser control that fills my whole form. The problem is when I click on the web form or the menu or another window and then comeback and hit spacebar, it doesn't work. I was thinking it lost focus, but after I set focus back to the form it still didn't pick up the event. Also, how would I set my Form Width to that of the webpage or picture being displayed in the webBroswer control? Thanks
-
Ie engineThanks a lot
-
Ie engineHow do I open html files or any other file that opens up in normal ie using a simple form. I want to be able to press spacebar and it would open up the next file in the directore using my form. But files are dcr(director) files and onlu open up in ie. Thanks
-
updating databaseHow do I update the database if I don't know which row to update. The selected datagrid row doesn't match that of dataset row because of how I display things. So how do I match up the dataGrid row to the dataTable row?