I have used http://jiwa.net/forums/viewtopic.php?f=14&t=119 as a base, however I did this in c#. Unfortunately I cannot get readrecord to work correctly. Because c# (I'm on 3.5) does not support optional parameters I cannot seem to use readrecord only providing the first three arguments. I normally use reflection's Missing.Value but in this case it does not work.
Beyond an explanation for why this is... What does "filterstring" represent? What is a legit filterstring that I could pass? I pass false for drilldown..
I receive the error:
Error On Fetch : clsRecordSet.FetchRow - No Data Found
If I could get some help with this it would be great. I have tried multiple "solutions":
Empty string as per below
null
Missing.Type
Reflection's MethodInfo (although I could not invoke as I was receiving null back when searching for readrecord..)
Thanks very much.
- Code: Select all
string connstr = @"blahblah";
JiwaODBC.database db = new JiwaODBC.database();
JiwaCommonLib.stdFunctions commlib = new JiwaCommonLib.stdFunctions();
JiwaLib.StdFunctions jiwalib = new JiwaLib.StdFunctions();
JiwaSysProfile.clsSysProfile profile = new JiwaSysProfile.clsSysProfile();
db.ConnectionDetails = connstr;
db.IniFile = @"blahblah";
profile.Load(db.IniFile);
DateTime date = new DateTime();
bool changepass = false;
if (db.MakeConnections(0))
{
db.DoLogOn("blahblah", "blahblah", ref changepass, ref date);
}
clsSalesQuote sq = new clsSalesQuote();
sq.Database = db;
sq.JiwaCommLib = commlib;
sq.JLib = jiwalib;
sq.SystemProfile = profile;
sq.Setup();
sq.ReadDefaultBranch();
sq.ReadRecord(0, 0, "A1C97E5491784DE89F0E", "", false);