Click here to Skip to main content
15,896,063 members
Home / Discussions / C#
   

C#

 
AnswerRe: reg creation of multi file assembly Pin
PIEBALDconsult9-Dec-09 18:10
mvePIEBALDconsult9-Dec-09 18:10 
QuestionTrying to use HashSet<t></t> Pin
BobInNJ9-Dec-09 13:38
BobInNJ9-Dec-09 13:38 
AnswerRe: Trying to use HashSet Pin
N a v a n e e t h9-Dec-09 14:53
N a v a n e e t h9-Dec-09 14:53 
QuestionDelete a word everytime the program see it. Pin
ahlm9-Dec-09 10:54
ahlm9-Dec-09 10:54 
AnswerRe: Delete a word everytime the program see it. Pin
Migounette9-Dec-09 11:56
Migounette9-Dec-09 11:56 
AnswerRe: Delete a word everytime the program see it. Pin
Abhinav S9-Dec-09 17:13
Abhinav S9-Dec-09 17:13 
GeneralRe: Delete a word everytime the program see it. Pin
ahlm9-Dec-09 18:31
ahlm9-Dec-09 18:31 
QuestionSqlCeResultSet Problem [modified] Pin
Stanciu Vlad9-Dec-09 6:25
Stanciu Vlad9-Dec-09 6:25 
Hello,

I have a SmartDevice project (.NetCF 2.0) configured to be tested on the USA Windows Mobile 5.0 Pocket PC R2 Emulator. My project uses SqlCe 3.0. Understanding that a SmartDevice project is "more carefull" with the device's memory I am using SqlCeResultSets. The result sets are strongly typed, autogenerated by Visual Studio 2008 using the custom tool MSResultSetGenerator.

The problem I am facing is that the result set does not recognize any column names. The autogenerated code for the fields does not work.
In the client code I am using
InfoResultSet rs = new InfoResultSet();
                
rs.Open();
rs.ReadFirst();
                
string myFormattedDate = rs.MyDateColumn.ToString("dd/MM/yyyy");


When the execution on the emulator reaches the rs.MyDateColumn the application throws an System.IndexOutOfRangeException.

Investigating the stack trace
at System.Data.SqlServerCe.FieldNameLookup.GetOrdinal()
at System.Data.SqlServerCe.SqlCeDataReader.GetOrdinal()

I've tested the GetOrdinal method (in my autogenerated class that inherits SqlCeResultSet):

this.GetOrdinal("MyDateColumn"); // throws an exception
this.GetName(1); // returns "MyDateColumn"
this.GetOrdinal(this.GetName(1)); //throws an exception  :) 


Am I doing something wrong or am I missing something?

Thank you.

I have no smart signature yet...

modified on Wednesday, December 9, 2009 12:33 PM

AnswerRe: SqlCeResultSet Problem Pin
Migounette9-Dec-09 12:19
Migounette9-Dec-09 12:19 
QuestionRe: SqlCeResultSet Problem Pin
Stanciu Vlad9-Dec-09 20:09
Stanciu Vlad9-Dec-09 20:09 
QuestionUpdate own written TabPage Pin
Tagamoga9-Dec-09 4:18
Tagamoga9-Dec-09 4:18 
AnswerRe: Update own written TabPage Pin
The Man from U.N.C.L.E.9-Dec-09 7:01
The Man from U.N.C.L.E.9-Dec-09 7:01 
GeneralRe: Update own written TabPage Pin
Tagamoga9-Dec-09 8:28
Tagamoga9-Dec-09 8:28 
GeneralRe: Update own written TabPage Pin
The Man from U.N.C.L.E.9-Dec-09 10:18
The Man from U.N.C.L.E.9-Dec-09 10:18 
GeneralRe: Update own written TabPage Pin
Tagamoga9-Dec-09 12:24
Tagamoga9-Dec-09 12:24 
GeneralRe: Update own written TabPage Pin
The Man from U.N.C.L.E.10-Dec-09 1:27
The Man from U.N.C.L.E.10-Dec-09 1:27 
QuestionPreventing InvalidDeploymentException exceptions Pin
Jim Crafton9-Dec-09 4:16
Jim Crafton9-Dec-09 4:16 
AnswerRe: Preventing InvalidDeploymentException exceptions Pin
Paulo Zemek9-Dec-09 5:24
Paulo Zemek9-Dec-09 5:24 
GeneralRe: Preventing InvalidDeploymentException exceptions Pin
Jim Crafton9-Dec-09 5:30
Jim Crafton9-Dec-09 5:30 
AnswerRe: Preventing InvalidDeploymentException exceptions Pin
N a v a n e e t h9-Dec-09 14:58
N a v a n e e t h9-Dec-09 14:58 
QuestionHow to get first and last date given a year and a weeknr Pin
livez9-Dec-09 3:30
livez9-Dec-09 3:30 
AnswerRe: How to get first and last date given a year and a weeknr Pin
Richard MacCutchan9-Dec-09 3:42
mveRichard MacCutchan9-Dec-09 3:42 
GeneralRe: How to get first and last date given a year and a weeknr Pin
livez9-Dec-09 3:49
livez9-Dec-09 3:49 
GeneralRe: How to get first and last date given a year and a weeknr Pin
Richard MacCutchan9-Dec-09 4:06
mveRichard MacCutchan9-Dec-09 4:06 
GeneralRe: How to get first and last date given a year and a weeknr Pin
livez9-Dec-09 4:43
livez9-Dec-09 4:43 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.