473,395 Members | 1,629 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

asp.net help with if and sql thingies :-)

I'm really strugling with something that should be very basic. I've got an SQL db holding user preference information - 0 for no and 1 for yes

In the head i have:

Expand|Select|Wrap|Line Numbers
  1.  <script runat="server" language="VB"> 
  2. Function general() as String
  3. IIf question.FieldValue("question_general_info", Container) = "1",Return("<img src='images/check2.gif'>"),Return("<img src='images/delete2.gif'>")
  4. End If
  5. End Function
  6. </script>
  7.  
in the body I have:

Expand|Select|Wrap|Line Numbers
  1.  <% response.write(general()) %>
And of course it doesn't work.

Please help

Craig
May 26 '06 #1
1 1433
Well, unfortunately my question was too silly to be responded to.

Here is how I overcame it myself. If it's wring it's wrong, but it works.

string TTUserID = DS_uidAndPwd.FieldValue("user_ID",null);
string User_Name = DS_uidAndPwd.FieldValue("user_full_name",null);
int intUserID;
Session["intUserID"] = Convert.ToInt32(TTUserID);
Session["Full_Name"] = User_Name;

I've posted my solution in case someone else needs help or you may want to show me the error of my ways ;-)
Jun 6 '06 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Tobias Pfeiffer | last post by:
Hi! Damnit, am I angry! Please look at the following example: class bla: def __init__(self): self.ho = {'a': , 'c': , 'b': , 'e': , 'd': , 'g': , 'f': , 'h': } # shall be an adjacence list...
137
by: Philippe C. Martin | last post by:
I apologize in advance for launching this post but I might get enlightment somehow (PS: I am _very_ agnostic ;-). - 1) I do not consider my intelligence/education above average - 2) I am very...
0
by: Oleg Nekrasov | last post by:
Please, help me to find freeware PHP5 Guest-bbok script with administration functions: meaasages can be shown JUST after moderator agree. Without any smiles, posts by blocks on page(listings),...
33
by: Martin Jørgensen | last post by:
Hi, In continuation of the thread I made "perhaps a stack problem? Long calculations - strange error?", I think I now got a "stable" error, meaning that the error always seem to come here now...
8
by: merrittr | last post by:
I define 2 variables (that I need to be globally accesible in all files in this program) in the file stack.c (functions push and pop): //stack.c defnition if params int iSp=0; char *iItem; ...
15
by: nagar | last post by:
I need to split a string whenever a separator string is present (lets sey #Key(val) where val is a variable) and rejoin it in the proper order after doing some processing. Is there a way to use...
8
by: Seth | last post by:
Hi, i would like to create a software in C that will apply some effects to pics(photoshop effects like gaussian blur ,auto color....ecc) . My problem is this: i have many pics and on them i...
3
by: sophie_newbie | last post by:
Hi, I want to store python text strings that characters like "é" "Č" in a mysql varchar text field. Now my problem is that mysql does not seem to accept these characters. I'm wondering if there...
1
by: mohammedredha | last post by:
My db2 v7 was working fine with odbc after I installed new vserion DB2 v8 i still can connect to odbc using command mode, but its not working with ms access to get data. please help.
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.