Search found 29 matches

by Slyde
Tue Aug 07, 2018 8:03 pm
Forum: C++ Development
Topic: How can I programmatically resize a wxFrame?
Replies: 8
Views: 480

Re: How can I programmatically resize a wxFrame?

I'm on it, Nunki. I really appreciate your help.
by Slyde
Tue Aug 07, 2018 10:25 am
Forum: C++ Development
Topic: How can I programmatically resize a wxFrame?
Replies: 8
Views: 480

Re: How can I programmatically resize a wxFrame?

Found it. I'll see what I can do to make this work. Thanks for your help, doublemax. bool Angela001App::OnInit() { //(*AppInitialize bool wxsOK = true; wxInitAllImageHandlers(); if ( wxsOK ) { Angela001Frame* Frame = new Angela001Frame(0); Frame->Show(); SetTopWindow(Frame); } //*) return wxsOK; }
by Slyde
Tue Aug 07, 2018 10:05 am
Forum: C++ Development
Topic: How can I programmatically resize a wxFrame?
Replies: 8
Views: 480

Re: How can I programmatically resize a wxFrame?

How abt this: class Angela001Frame: public wxFrame { public: Angela001Frame(wxWindow* parent,wxWindowID id = -1); virtual ~Angela001Frame(); And I stand corrected abt Angela001Frame being a class and not an object :D I had no idea that changing the frame size wld be this involved. I'll study my opti...
by Slyde
Tue Aug 07, 2018 9:55 am
Forum: C++ Development
Topic: How can I programmatically resize a wxFrame?
Replies: 8
Views: 480

Re: How can I programmatically resize a wxFrame?

Hi Nunki: Is this what you're talking about: BEGIN_EVENT_TABLE(Angela001Frame,wxFrame) //(*EventTable(Angela001Frame) //*) END_EVENT_TABLE() Angela001Frame::Angela001Frame(wxWindow* parent,wxWindowID id) { //(*Initialize(Angela001Frame) wxMenu* Menu1; wxMenu* Menu2; wxMenuBar* MenuBar1; wxMenuItem* ...
by Slyde
Tue Aug 07, 2018 9:33 am
Forum: C++ Development
Topic: How can I programmatically resize a wxFrame?
Replies: 8
Views: 480

How can I programmatically resize a wxFrame?

i have a form set up that uses wxDEFAULT_DIALOG_STYLE. Given certain conditions, I want its width to grow from 780 to 1200. I've tried Angela001Frame->SetClientSize(1200,900); and Angela001Frame->SetSize(1200,900); and get this error: /home/slyde/Desktop/C::B/Angela001/Angela001Main.cpp|1071|error: ...
by Slyde
Sun Jul 08, 2018 10:16 am
Forum: Database Related
Topic: Is something like this possible?
Replies: 3
Views: 1845

Re: Is something like this possible?

Hello, Ma..Ma...Ma...Max Headroom =) Not many know about that, I bet. Anyway... There are no SQL errors. Since I didn't know how to call up the recipe_id from the Listbox, the first query simply tries to match the selected text to a recipe_name. Inner loop takes the recipe_id (retrieved from first q...
by Slyde
Sun Jul 08, 2018 1:09 am
Forum: Database Related
Topic: Is something like this possible?
Replies: 3
Views: 1845

Is something like this possible?

Hi Forum. I mess around with Lazarus a little. I'm not a good programmer, but Lazarus makes it easy to create database apps. I'm working with Code::Blocks, wxSQLite3 and wxWidgets now, trying to create one of those Laz apps. And I'm having hell with it. On a form, I have a Listbox, multiline textbox...
by Slyde
Tue May 01, 2018 9:58 pm
Forum: C++ Development
Topic: Creating the Grid
Replies: 1
Views: 227

Creating the Grid

I'm using wxTreebook with five panels on it, so far. On the fourth panel (panel_4), I have a wxGrid. In the wxGrid Properties, If I don't initially set "Number of columns" to at least 1, I won't get columns. Right now I have it set to 1 and always get one extra column after the fields are placed in ...
by Slyde
Fri Apr 27, 2018 11:33 am
Forum: Database Related
Topic: [SOLVED] Need help with adding variables to Queries
Replies: 8
Views: 1849

Re: Need help with adding variables to Queries

Yes. You've cleared up a lot for me. And I'll indeed spend time looking at the "minimal" sample. I want to soak this in. I like it and am having fun with it. A lot of fun! Thanks again. I appreciate you sharing your knowledge with me.
by Slyde
Fri Apr 27, 2018 10:53 am
Forum: Database Related
Topic: [SOLVED] Need help with adding variables to Queries
Replies: 8
Views: 1849

Re: Need help with adding variables to Queries

One more question, Ulrich. In setting up the wxGrid, I want to get a count of the number of entries in a Table and then build the number of Grid rows shown accordingly. I'm used to working with PHP and MariaDB and the solution to this with wx* is elusive. I have: wxSQLite3ResultSet res = db->Execute...
by Slyde
Fri Apr 27, 2018 7:56 am
Forum: Database Related
Topic: [SOLVED] Need help with adding variables to Queries
Replies: 8
Views: 1849

Re: Need help with adding variables to Queries

Thank you for the heads up. Your example code is very much appreciated. I left Qt to use wxSQLite3 with Code::Blocks. The learning curve is a little steeper this way, but I favor this to using a hybrid C++. Thanks. I see you used ExecuteUpdate for the INSERT statement and ExecuteQuery for the SELECT...
by Slyde
Fri Apr 27, 2018 6:21 am
Forum: Database Related
Topic: [SOLVED] Need help with adding variables to Queries
Replies: 8
Views: 1849

Re: Need help with adding variables to Queries

The extra closed parenthesis at the end of the second query will be shot at sunrise!

Thanks for the help :D
by Slyde
Fri Apr 27, 2018 4:53 am
Forum: Database Related
Topic: [SOLVED] Need help with adding variables to Queries
Replies: 8
Views: 1849

Re: Need help with adding variables to Queries

I got this partially sorted out. db->Open("zyx.db"); db->ExecuteQuery("INSERT INTO recipe_names(recipe, weight_type) VALUES('" + var1 + "', '" + wt + "');"); wxSQLite3ResultSet Res2 = db->ExecuteQuery("SELECT recipe_id FROM recipe_names WHERE recipe = '" + var1 + "');"); rec_id = Res2.GetAsString(0)...
by Slyde
Fri Apr 27, 2018 3:24 am
Forum: Database Related
Topic: [SOLVED] Need help with adding variables to Queries
Replies: 8
Views: 1849

[SOLVED] Need help with adding variables to Queries

Hi Forum: I'm new to C++ and use Code::Blocks and wxSQLite3. Everything is going good except that I'm having trouble using variables in a query statement. Let me show you: wxString rec_id = ""; wxString wt = ""; if (RadioButton_Grams) wt = "0"; else wt = "1"; wxString var1 = txtProductName->GetValue...