Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
B

bobolov

@bobolov
About
Posts
13
Topics
8
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • NullReferenceException object reference not set to an instance of an object..please help
    B bobolov

    i've highligthed and underlined the line that was giving me a nullreference exception.

    C# database help graphics sysadmin security

  • NullReferenceException object reference not set to an instance of an object..please help
    B bobolov

    line number : 140

    C# database help graphics sysadmin security

  • NullReferenceException object reference not set to an instance of an object..please help
    B bobolov

    using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Text; using System.Windows.Forms; using System.Data.SqlClient; using Microsoft.AnalysisServices; using Microsoft.DataWarehouse.Interfaces; using System.Data.OleDb; using System.Data.Common; namespace DatabaseApplication { public partial class Form1 : Form { string dbname; string connectionstring; string databasename; string datasourceviewname; string datasourcename; string tableName; public Form1() { InitializeComponent(); } private void Form1_Load(object sender, EventArgs e) { string connstring = "Data Source=localhost;Integrated Security=True"; SqlConnection connection = new SqlConnection(connstring); string query = "select * from sys.databases"; SqlDataAdapter data = new SqlDataAdapter(query, connection); DataTable dtable = new DataTable(); try { connection.Open(); int records = data.Fill(dtable); if (records > 0) { foreach (DataRow dr in dtable.Rows) { //Console.WriteLine(dr[0]); comboBox1.Items.Add(dr[0]); } } } catch (SqlException sqlexcp) { MessageBox.Show("connection error"); } } private void comboBox1_SelectedIndexChanged(object sender, EventArgs e) { dbname = comboBox1.Text; } private void button1_Click(object sender, EventArgs e) { /*databasename = dbname; datasourceviewname = "oor"; connectionstring = "Data Source=localhost;Integrated Security=True"; //create a datasource name RelationalDataSource newDS = new RelationalDataSource(datasourceviewname, Utils.GetSyntacticallyValidID(datasourceviewname, typeof(RelationalDataSource))); Database db = new Database("oor"); db.DataSources.Add(newDS); newDS.ConnectionString = connectionstring; newDS.Update();*/ Server server = new Server(); databasename = "cwh_temp"; s

    C# database help graphics sysadmin security

  • is there any way i can update only some fields in the database excluding primary key ? please help
    B bobolov

    Error Type: Microsoft JET Database Engine (0x80040E21) Index or primary key cannot contain a Null value. /Poonam/updated.asp, line 73 ---------------------------------------------------------------------------- this is my update file <% dim month, day, year, gender,OStats,DStats,SStats,arrVals,arrAll,rs,usr,strSql,strdes,strinter,strfavm,strquote,strfavs,status gender = Request.Form("Gender") month = Request.Form("DOBMonth") day = Request.Form("DOBDay") year = Request.Form("DOBYear") 'arrAll = split(Request.Form ("allBoxes"), ",") 'get the array with the id's that were ticked 'arrVals = split(Request.Form ("chkbox"), ",") 'rs("Looking to")= '& arrVals &' Looking = Trim(Request.Form("ckbox")) status = Request.form("lovestatus") OStats = Request.Form("orientationStatus") DStats = Request.Form("drinkerStatus") SStats = Request.Form("smokerStatus") strdes = Request.Form("description") strinter = Request.Form("interests") strfavs = Request.Form("favoriteSongs") strfavm = Request.Form("movies") strquote = Request.Form("quote") 'Build connection usr=Request.QueryString("nm") set conn = server.CreateObject ("ADODB.Connection") conn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & server.MapPath ("users.mdb") set rs = server.CreateObject ("ADODB.Recordset") 'Open record with entered username rs.Open "select * from userlist where username='"& usr &"'", conn, 3, 3 rs.AddNew rs("username") = usr rs("password") = var rs("fullname") = var2 rs("country") = var3 rs("fld_question") = var4 rs("fld_answer") = var5 rs("fld_email") = var6 rs("fld_visitor_ID") = var7 rs("dd") = day rs("mm") = month rs("yy") = year rs("Status") = status rs("Looking_to") = Looking rs("Gender")=gender rs("Favourite_Quote")= strquote rs("Favourite_Movie")= strfavm rs("Favourite_Bands") = strfavs rs("Sexual_Orientation") = OStats rs("Smoker") = SStats rs("Drinker") = DStats rs("Interests") = strinter rs("About_me") =strdes 'Save record rs.Update set rs=nothing set conn=nothing %>

    Web Development database help sysadmin data-structures question

  • I need help to solve a error on my form
    B bobolov

    :rose:thank u paddy for helping me out...:)...

    Web Development help javascript question

  • I need help to solve a error on my form
    B bobolov

    Error Type: Microsoft VBScript compilation (0x800A0401) Expected end of statement /Poonam/login.asp, line 40, column 148 Content = Content & "
    Full name: " <% 'Green colorset 'BackgroundColor="#C9DDB3" 'BorderColor="#006600" 'Blue colorset BackgroundColor="#AFD1F8" BorderColor="#000080" 'Purple colorset 'BackgroundColor="#FDC8F2" 'BorderColor="#800080" Content = "" 'Clear the Content string QStr = Request.QueryString("login") 'Save the login querystring to QStr if ucase(left(QStr,6))="CREATE" then Title = "Register" else Title = "Login" end if 'The code below saves the contents the table must have in the variable Content 'The content depends on what's in the QueryString if QStr="passfailed" then Content = Content & "

    Wrong password

    [Back](Javascript:history.go(-1))" elseif QStr="createpassfailed" then Content = Content & "

    Wrong password

    [Back](Javascript:history.go(-1))

    Cancel registration" elseif QStr="namefailed" then Content = Content & "

    Invalid username

    Click here to create an acount

    [Back](Javascript:history.go(-1))" elseif QStr="createnamefailed" then Content = Content & "

    Invalid username

    [Back](Javascript:history.go(-1))

    Cancel registration" elseif QStr="creatednew" then Content = Content & "

    Your account has been created

    Login" elseif QStr="createnew" then Content = Content & "

    " Content = Content & "
    Username: " Content = Content & "Password: " Content = Content & "

    Web Development help javascript question

  • help! syntax error INSERT INTO..
    B bobolov

    Error Type: Microsoft JET Database Engine (0x80040E14) Syntax error in INSERT INTO statement. /insert.asp, line 26 <% ' Declaring variables Dim name, address, age, income, data_source, con, sql_insert Function ChkString(string) If string = "" Then string = " " ChkString = Replace(string, "'", "''") End Function ' Receiving values from Form name = ChkString(Request.Form("name")) address = ChkString(Request.Form("address")) age = ChkString(Request.Form("age")) income = ChkString(Request.Form("income")) data_source = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & Server.MapPath("db1.mdb") sql_insert = "insert into user (name, address, age, income) values ('" & name & "', '" & address & "', '" & age & "', '" & income & "')" ' Creating Connection Object and opening the database Set con = Server.CreateObject("ADODB.Connection") con.Open data_source con.Execute sql_insert ' Done. Close the connection con.Close Set con = Nothing %> bobolov

    Web Development database help sysadmin

  • please help! when submit button is clicked it should open the link which is in another file
    B bobolov

    it would be a of great help if i could get any help on the Javascript on it thank u

    Web Development sysadmin help

  • please help! when submit button is clicked it should open the link which is in another file
    B bobolov

    #this is my first file where i need the submit button to open the link from the second file returned...2nd file is given below please refer

    <% Set oRs=Server.CreateObject("adodb.recordset") strSQL = "SELECT * FROM projects" oRs.Open strSQL, conn Do while not oRs.EOF if Request.Form("code") = oRs("Code") then Response.Write "" Response.Write "Choose :" Response.Write oRS ("Code") & " " & oRs("Description") & " " oRs.MoveNext else Response.Write "" Response.Write oRS ("Code") & " " & oRs("Description") & " " oRs.MoveNext end if loop %> # the second file displays the link matching the users input..i want this click to be in the submit button... Continue <% code=Request.Form ("exmp")%> <% yr=Request.form ("year") %> <% mnth=Request.form("month") %> <% if Request.form("sub")="Latest" THEN %> <% if Request.form("report")="manage" THEN %> <% var=(code)& "m.pdf" %> CLICK HERE TO OPEN THE FILE <% ELSE %> <% var1=(code)& "c.pdf" %> CLICK HERE TO OPEN THE FILE <% end if %> <% else %> <% if Request.form("type")="manage" THEN %> <% var2=yr & "\" & mnth & "\" & (code)& "m" & (mnth) & (yr) %> [CLICK HERE TO OPEN THE FILE](<%=(var2)%>.pdf) <% ELSE %> <% var3=yr & "\" & mnth & "\" & (code)& "c" & (mnth) & (yr) %> [CLICK HERE TO OPEN THE FILE](<%=(var3)%>.pdf) <%end if %> <% end if %>
    bobo

    Web Development sysadmin help

  • need help : how to convert a text field in Access database to a hyperlink in the browser
    B bobolov

    how to convert a text field in Access database to a hyperlink in the browser because when i read the hyperlink fields from the Acccess database and display to the browser its output is like a comment #http:...# i want the link to displayed as a link itself. Is there a way that a text field in access can be read to the browser like a link???...pleeeeease hellp:confused:

    ASP.NET database help tutorial question

  • how to convert a text field in the Access database to a hyperlink in the brower [modified]
    B bobolov

    how to convert a text field in Access database to a hyperlink in the browser because when i read the hyperlink fields from the Acccess database and display to the browser its output is like a comment #http:...# i want the link to displayed as a link itself. Is there a way that a text field in access can be read to the browser like a link???...pleeeeease hellp..:confused: -- modified at 3:20 Saturday 17th June, 2006

    Web Development database tutorial question

  • how to add to fields from a access database to a list box using asp code
    B bobolov

    is there any other way doing this...i need two feilds in the listbox option...thanks for all the help...im new to this :)... Error Type: Microsoft VBScript compilation (0x800A03EE) Expected ')'

    <% Set oRs=Server.CreateObject("adodb.recordset") strSQL = "SELECT code ,description FROM projects" oRs.Open strSQL, conn Do while not oRs.EOF if Request.Form("code") = oRs("Code") then Response.Write ("" & oRs.Fields("description") & " " oRs.MoveNext else Response.Write ("" & oRs.Fields("description") & " " oRs.MoveNext end if loop %> bobo... -- modified at 2:22 Tuesday 13th June, 2006

    Web Development database sysadmin help tutorial

  • how to add to fields from a access database to a list box using asp code
    B bobolov

    this is my code...and i want the code to display two fields together concatenate them in the list box that is the code and description...when i run it with in the browser displays a Error Type: Microsoft VBScript compilation (0x800A03EE) Expected ')' line 64, column 47 <% Set oRs=Server.CreateObject("adodb.recordset") strSQL = "SELECT code ,description FROM projects" oRs.Open strSQL, conn Do while not oRs.EOF if Request.Form("code") = oRs("Code") then Response.Write ("& ("description") ") oRs.MoveNext else Response.Write ("& ("description") ") oRs.MoveNext end if loop %> bobo

    Web Development database sysadmin help tutorial
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups