|
Is the file in the actual location?
Lobster Thermidor aux crevettes with a Mornay sauce, served in a Provençale manner with shallots and aubergines, garnished with truffle pate, brandy and a fried egg on top and Spam - Monty Python Spam Sketch
|
|
|
|
|
No this file doesn't exist in this location. And I know this. The question is how I can get this file? Where is the file?
System.IO.FileNotFoundException: Could not find file 'C:\Users\Lion\AppData\Local\Apps\2.0\J98YQDCL.P3L\3TX9ONZ9.XO3\cali..tion_b66fbc81589c75c7_0001.0000_012e4219e7fd7afb\Database.sdf'.
File name: 'C:\Users\Lion\AppData\Local\Apps\2.0\J98YQDCL.P3L\3TX9ONZ9.XO3\cali..tion_b66fbc81589c75c7_0001.0000_012e4219e7fd7afb\Database.sdf'
Thanks
|
|
|
|
|
saturnuk wrote: No this file doesn't exist in this location. And I know this. The question is how I can get this file? Where is the file?
Using ClickOnce[^]?
Every ClickOnce application installed on a local computer has a data directory, stored in the user's Documents and Settings folder. Any file included in a ClickOnce application and marked as a "data" file is copied to this directory when an application is installed. Data files can be of any file type, the most frequently used being text, XML, and database files such as Microsoft Access .mdb files.
Bastard Programmer from Hell
if you can't read my code, try converting it here[^]
|
|
|
|
|
Try this to find the file:
SqlCeConnection con = new SqlCeConnection(connectionString);
string databaseFilePath = con.Database;
con.Close();
0200 A9 23
0202 8D 01 80
0205 00
|
|
|
|
|
this[^] is what I'm after.
Infragistics so called help is horrible. Can't find anything that gets me what I want. There are scattered topics found in Google, but their not much help.
Anyone know how to do this? A code example would be nice.
Thanks
If it's not broken, fix it until it is
|
|
|
|
|
You've only just posted the message on the Infragistics site. Give them a chance.
|
|
|
|
|
Actually, I posted here first. I find that asking a question either take way too long to get a response, or their responses are not very good.
If it's not broken, fix it until it is
|
|
|
|
|
One of the amazing things about Telerik support is that 90% of the time they supply a sample project. I generally have a 24 hour turn around b/c I'm on the other side of the planet. That and the depth of the Infragistics object model convinced us to change suites...
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Mycroft Holmes wrote: That and the depth of the Infragistics object model convinced us to change
suites...
LOL
I absolutly LOVE Telerik. I agree with your comments 100%
One of the guys here looked at the source code for the Infragistics UltraGrid COLUMN, just the column ...... 60+ lines of code!!!
If it's not broken, fix it until it is
|
|
|
|
|
C# is not allowing me to define a Serial Port speed.
He says the max is 115200
I have seen other apps run 921600 on this very machine right in front of my eyes.
What gives ?
|
|
|
|
|
C-P-User-3 wrote: He says the max is 115200
I don't believe that's right. It sounds like a limit of the hardware - if you take a look at this[^] article, you'll see a link to COMMPROP[^] which contains the BAUD rates.
|
|
|
|
|
Pete O'Hanlon wrote: , you'll see a link to COMMPROP[^] which contains the BAUD rates.
That page is for C++
Duh ? I [can | can't] use that in C#
|
|
|
|
|
More duh.
I see: dwSettableBaud in the list of COMMPROP structure
I can change that value ? In C# ?
The biggy: can I change it to 921600 ?
Super nice would be able to select it from a list
|
|
|
|
|
The reason I linked to the original article is because it's a C# version - so all the hard work has been taken care of for you.
|
|
|
|
|
I'm studying the example you suggested, "Basic serial port listening application". I'm trying to grasp the section titled, "...Updating baud rates supported by the selected device..."
I see that he opens the port, and then does some really really strange things to to something with the BaudRate (still trying to grasp the concepts) with something like eleven different levels of magic words, parentheses (2, 3, or 4 of them, not really sure at this moment) and some "or" lines, I think.
After all that, he closes the port.
Will the port remain at the speed he chose for the next open ?
|
|
|
|
|
The values there are instance values, so as long as the class is held by an instance, and as long as there is no other code changing these values, they will remain the same. Bear in mind that this is purely an example of the code in his library, it doesn't necessarily mean that he's closing the port immediately after he opens it - that's just the way he's presented the methods, with the close quite logically following the open.
|
|
|
|
|
Pete O'Hanlon wrote: as long as there is no other code changing these values, they will remain the same.
Okay, so, if I put that in an "init" sort of section, then I can open and close all day long and still keep the same speed ?
If so, that could help things a lot.
|
|
|
|
|
You should be able to - it really depends on whether you need to free that port up for anything else.
|
|
|
|
|
No, he is totally stuck with the external box the whole time. The customer wants it that way; in fact, it's a part of the entire system design; their people, processes, the whole works.
I'm still trying to figure out how to put different stuff in different files and let everybody see it.
|
|
|
|
|
Reading and studying, what does this sentence mean ?
"...The field dwSettableBaud from the COMMPROP structure is a join of all supported baud rates...."
I think I'm clear on the word "structure" but I don't get what the author means by the word "join".
|
|
|
|
|
Think of it as a flag. This means you can do logic like
if ((dwSettableBaud & BAUD_1200) == BAUD_1200) I'm assuming here that you know how to work with logical ands. If not, have a look at this[^] page.
|
|
|
|
|
Pete O'Hanlon wrote: I'm assuming here that you know how to work with logical ands.
Check.
My super-duper skillset is in low-level embedded systems; ANDing, ORing, XORing, NOTing, NEGing, complementing, and so on; clear on that. I normally do that to the individual byte/bit/word/whatever in the machine, I/O port, control registers, blah blah blah,,, so the elementary boolean stuff is okay with me.
Never really got much further than a few identities with the actual real live boolean algebraic equations; although what little I did was a brain blast all the way. Too bad nobody will pay you to do Boolean Algebra all day long.
I wish C# had some sort of facility to just define the byte you want, where you want it, and then put that byte in that place. Seems there are about a thousand rules involved for anything like that.
But, thanks for your concern. References are welcome always.
I still am trying to figure out how to make the groups of bytes in one file visible to the methods in another one. These source files are going to grow to well over a thousand lines; not good in my book.
|
|
|
|
|
Okay, I'm studying the suggested app from the 2nd message in this thread.
I see this magic word "SerialPortManager" in different files, and C# knows they are there.
When I try to put something in a different file, C# can't see it.
What's going on with this correct app that isn't going on with mine ?
I'll mark the SerialPortManager with bold type in these file clips.
File: SerialPortManager.cs
File: MainForm.cs
namespace SerialPortListener
{
public partial class MainForm : Form
{
SerialPortManager _spManager;
public MainForm()
{
InitializeComponent();
UserInitialization();
}
private void UserInitialization()
{
_spManager = new SerialPortManager();
(more stuff)
(more stuff)
(more stuff)
(more stuff)
(more stuff)
File: SerialPortManager.cs
namespace SerialPortListener.Serial
{
public class SerialPortManager : IDisposable
{
public SerialPortManager()
{
_currentSerialSettings.PortNameCollection = SerialPort.GetPortNames();
_currentSerialSettings.PropertyChanged += new System.ComponentModel.PropertyChangedEventHandler(_currentSerialSettings_PropertyChanged);
if (_currentSerialSettings.PortNameCollection.Length > 0)
_currentSerialSettings.PortName = _currentSerialSettings.PortNameCollection[0];
}
~SerialPortManager()
{
Dispose(false);
}
Sorry, no clue why the formatting goes into all italics in the second code snip
Anyway, which lines in his code are giving him the ability to share the names between files ? Why can't I share the name of this group of bytes between files ?
namespace SerialPortPractice_03
{
public partial class Form1 : Form
{
public byte[] This_Does_Not_Work = new byte[] { 0x01, 0x02, 0x03, 0x04 };
public byte[] A_Test_To_Experiment = new byte[] {
0xFF, 0xFE, 0xFD, 0xFC,
0x11, 0x22, 0x33, 0x44,
0x55, 0x66, 0x77
}
;
}
Really hate this, but until I figure out the secret, I'm going to have to adopt the use of one huge source file with all 17 commands typed out.
|
|
|
|
|
Ahhh. I think I see where you're having a problem. Each class there is in a separate namespace. In order to use a class from one namespace in another namespace, you need to make this visible in the class you are trying to use it in.
That's a quite confusing sentence, so a practical demo is in order here - there are two ways to see the class in a different namespace: the first way is to add a using statement before your class. So, in MainForm to see the SerialPortManager class, do this:
using SerialPortListener.Serial;
namespace SerialPortListener
{
public class MainForm : Form
{
private SerialPortManager portManager = new SerialPortManager();
....
}
} The other method to do this (in place of the using statement) is to fully qualify the classname by including the namespace in it like this:
namespace SerialPortListener
{
public class MainForm : Form
{
private SerialPortListener.Serial.SerialPortManager portManager = new SerialPortListener.Serial.SerialPortManager();
....
}
} If you are using Visual Studio and you have a class that is in a different unreferenced namespace, you should see a little blue square at the start of the class name (under the first letter). Either click this to bring up a menu or press Shift+Alt+F10; in both cases, it should let you choose whether to add the using statement or whether you want to fully qualify the class name.
|
|
|
|
|
Pete O'Hanlon wrote: Each class there is in a separate namespace.
Okay, so, the fact that all the files have the same line in them, near the top, i.e., this one...
namespace SerialPortPractice_03
namespace SerialPortPractice_03
...does not mean that they can see each other.
In other words, there is no "linker" (such as I am accustomed to having) which combines all the labels in different files into the same area in memory (even with the namespace line at the start) to allow one guy to call the other guy whenever he wants.
Am I close ?
|
|
|
|